-
Notifications
You must be signed in to change notification settings - Fork 88
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
about the decrease of the loss #44
Comments
I have the same problem too, looking forward to the author's answer |
@hhxzzy I'm sorry to bother you.I added the contrast loss function to my model and code, and this problem also occurred.Has your problem been solved? |
Hello. I try to make some change to the code, but the contrastive loss is still not going to drop much. But it seems that adding the contrastive can help improve the mIOU on Cityscapes by about 1%. Maybe it is the nature of contrastive loss that it doesn't drop much. |
已收到
|
@hhxzzy @guwen007 @wingkeihon Thanks for your interests. The contrastive loss is indeed more difficult to optimize than the CE loss. But it will still help to learn a better embedding space, which will benefit segmentation. So I will suggest to see whether the final segmentation performance is improved. |
@tfzhou @hhxzzy @wingkeihon @guwen007 |
If you want to run the author's scripts directly, you can take configs/cityscapes/H_48_D_4.json as an example. You need to change "data" and "loss“/"params"/"ce_weight" according to your dataset. |
Thank you for your prompt attention. |
Hello. Thanks for your excellent work!
I transplant the loss function and memory bank of your code to my own code, and run my code on Cityscapes dataset and my own dataset. But it turns out that the decrease of the contrast loss is very small. For example, the contrast loss drops from 1.27 to 1.11 after 80k epoch on Cityscapes, while the ce loss drops from 1.26 to 0.15. And the same thing happens on my own dataset. It seems that the contrast loss is not being useful during train.
I wonder is it normal for the contrast loss to decrease so little? And what can I do to make full use of the contrast loss, like tuning the hyper-parameters?
The text was updated successfully, but these errors were encountered: