lets say I have a big image with about 90% greenish pixels, 9% bluish pixels and 1% brownish pixels. I want to get a sample of only 100 pixels from the whole image having around maybe 2000,000 pixels.
I don't want the sample to contain pixels relative to their frequency in the original image, rather it should have equal number of greenish, bluish and brownish pixels.
I use -ish after every color because the pixels have different values and also this would be easy to do if I knew the colors of each image, Each image has different color groups so I need to come up with a general way of doing this which does not depend on me specifying the colors of the image.