load_image | R Documentation |
load_image
is a vectorized method for reading bitmaps (jpegs, pngs and
bmps) into memory as arrays of pixel values. It optionally supports parallel
processing (via future
and future.apply
) and progress
reporting.
load_image(file, quiet = FALSE)
file |
A vector of file paths or URLs which identify bitmapped images in
the JPEG, PNG, TIFF, or BMP file formats. If |
quiet |
A logical scalar. Should the function execute quietly, or should it return status updates throughout the function (default)? |
load_image
only supports 3-channel (RGB) or 1-channel (greyscale)
images; 4-channel (RGBA) images will have their alpha channel silently
dropped and 2-channel (greyscale with alpha) images will have only their
alpha channel preserved, while images with 5 or more channels will return as
NA.
Because the memory requirements of storing image representations in memory
so large, it is usually not feasible to read in more than several hundred
images at a time with load_image
. For these cases, use
create_signature
directly on the input file paths. By default
this will read images with load_image
100 at a time before
generating the unique colour signatures used for image matching.
A matchr_image
vector of the same length as the input vector.
## Not run:
load_image(test_urls)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.