meng-tang / rloss

Regularized Losses (rloss) for Weakly-supervised CNN Segmentation
MIT License
207 stars 46 forks source link

Hi,thank you for sharing your code. Could you tell me why did you set croppings = (target!=254).float() in train_withdensecrfloss.py? I really don't understand what you mean by 254 here. #12

Closed yajunbaby closed 4 years ago

meng-tang commented 4 years ago

254 is for padding, see the function RandomScaleCrop in /dataloaders/custom_transforms.py and dataloaders/datasets/pascal.py. The convention is to pad 255 and ignore the padded region. However, in scribble-annotated images, we need to distinguish ignore region and padded region for our loss function. Sorry for the confusion.