image-segmentation-keras
image-segmentation-keras copied to clipboard
Weighted class training
Hi, First thank you for your fine work, it helped me a lot !
I'm currently working on my own dataset. It features images of animal's skin. This experiment's purpose is to evaluate if the skin is dirty and how much ( using relative surface indicator but it doesn't matter here). So this dataset features three classes ['background',dirt','skin'].
My problem here is that dirt class is less present in my data than background and skin. After training, IU is pretty good for those two classes but IU of dirt class is really low. Here is what I get when I'm running model evaluation:
{'class_wise_IU': array([0.93618142, 0.39157847, 0.88989816]),
'frequency_weighted_IU': 0.8766922757062017,
'mean_IU': 0.7392193502068617}
Is there a way that I can assign weights to classes during training so that algorithm will learn dirt's features more thorougly than other classes?