mmsegmentation
mmsegmentation copied to clipboard
Binary segmentation may only output zeros
Describe the bug The EncoderDecoder Segmentor seems not to take into account the binary segmentation case. The argmax linked below may only return 0 when num_classes=1 and using sigmoid as loss fuction.
https://github.com/open-mmlab/mmsegmentation/blob/0e37281884193838417a43802bb7a4c854d2067e/mmseg/models/segmentors/encoder_decoder.py#L263
https://github.com/open-mmlab/mmsegmentation/blob/0e37281884193838417a43802bb7a4c854d2067e/mmseg/models/segmentors/encoder_decoder.py#L286
Thanks for your bug reporting. We will fix it asap.
@xiexinch please have a look.
Hi @wptoux, We are working on fixing this bug, but it takes some time.
Me too, we alter code to make a multi-label binary segmentation, but the per pixel in binary preds has the same values.
Hi @wptoux, @GuardSkill, We create PR #2016 to fix the bug, could you try it and feedback to us?