Hey guys, I need to calculate the contamination rate in grains products (the percentage of thus black grains of the total amount of grains).

the picture is simplified, in real there will be much more black (toxic) grains and much more green (healthy) grains.

my idea was to train a DL algorithm to detect thus black gains and then via area calculation maybe i get the correct percentage.

I appreciate any idea/help ^^

Thanks!