R/Lib_ImageProcess.R
get_random_subset_from_image.Rd
extract random subset of pixels from an image
get_random_subset_from_image(
ImPath,
MaskPath,
nb_partitions,
Pix_Per_Partition,
kernel = NULL,
MaxRAM = 0.5
)
list, see Details
The returned list contains: - DataSubset: matrix of NxP of N samples and P bands - nbPix2Sample: integer giving the number of pixels sampled (only central pixel of kernel) - coordPix: a data.table with columns 'row', 'col' of pixel in the image corresponding to each row of DataSubset, and if kernel is not NULL Kind (Kernel index) and 'id' the sample ID to be used with the kernel