I currently have a keras-model that classifies each pixel as either belonging to object or background using a fully convolutional network. As I have only 2 classes (object or background) I am using a sigmoid activation in the output layer and binary_crossentropy loss.
However, for several images I am unsure of what class some of the pixels belong to, therefore I would like to label these pixels as void such that the networks weights are not updated based on the prediction for these pixels. Is there a method for dealing with void labels in Keras?
One way of doing this in general would be to specify loss weights for each pixel, and set the weight for void pixels to 0. (E.g. like this for tensorflow). I investigated using sample_weights in Keras, but I could not get that to work as it does not seem to be made for weighting pixels.