powered by
Creates an image data generator that resizes images if requested and also returns the original images size needed for MegaDetector.
ImageGeneratorSize( files, resize_height = NULL, resize_width = NULL, pad = FALSE, standardize = FALSE, batch = 1 )
A Tensorflow image data generator.
a vector of file names
the height the cropped image will be resized to. If NULL returns original size images.
the width the cropped image will be resized to. If NULL returns original size images..
pad the image instead of stretching it, TRUE or FALSE.
standardize the image to the range 0 to 1, TRUE or FALSE.
the batch size for the image generator.
if (FALSE) { dataset <- ImageGenerator(images, standardize = FALSE, batch = batch) }
Run the code above in your browser using DataLab