Skip to content
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

CIou #22

Open
alicera opened this issue Jun 4, 2021 · 4 comments
Open

CIou #22

alicera opened this issue Jun 4, 2021 · 4 comments

Comments

@alicera
Copy link

alicera commented Jun 4, 2021

Hi, tju
Thanks for your project.
I try to use the ciou loss and add it to the project
https://github.com/biubug6/Pytorch_Retinaface
But it seem to get the same precision AP.
Do you have any idea?

@Zzh-tju
Copy link
Owner

Zzh-tju commented Jun 4, 2021

Which loss is your baseline? BBox reg loss just facilitates the model training. Label assignment is also an important indicator. Better label assignment will ease the training difficulty, making the CIoU loss obtain less improvement.

@alicera
Copy link
Author

alicera commented Jun 5, 2021

I directly use the ciou function, because the project also use the multibox of ssd. So it can easy to add it. And I get the same good result when change the SmoothL1 loss to ciou loss on location(x,y,w,h).
Do you have any idea?
https://github.com/Zzh-tju/CIoU/blob/master/layers/modules/multibox_loss.py#L11

@Zzh-tju
Copy link
Owner

Zzh-tju commented Jun 5, 2021

what is your reg loss weight when switching to CIoU?

@alicera
Copy link
Author

alicera commented Jun 5, 2021

I test the two reg loss weight. One is 2. The other is 16.
https://github.com/biubug6/Pytorch_Retinaface/blob/master/data/config.py#L29

Loc

'''
Epoch:97/100 || Epochiter: 716/1010 || Iter: 97676/101000 || Loc: 0.1373 Cla: 0.5106 Landm: 0.3921 prop: 0.4671|| LR: 0.00005000 || Batchtime: 1.0305 s || ETA: 0:57:06
torch.Size([21, 3, 640, 640])
Epoch:97/100 || Epochiter: 717/1010 || Iter: 97677/101000 || Loc: 0.1677 Cla: 0.9701 Landm: 1.3356 prop: 0.4434|| LR: 0.00005000 || Batchtime: 1.0676 s || ETA: 0:59:08
torch.Size([21, 3, 640, 640])
Epoch:97/100 || Epochiter: 718/1010 || Iter: 97678/101000 || Loc: 0.1707 Cla: 0.8567 Landm: 0.6479 prop: 0.3464|| LR: 0.00005000 || Batchtime: 1.0307 s || ETA: 0:57:05
torch.Size([21, 3, 640, 640])
Epoch:97/100 || Epochiter: 719/1010 || Iter: 97679/101000 || Loc: 0.1552 Cla: 0.5850 Landm: 0.5912 prop: 0.3076|| LR: 0.00005000 || Batchtime: 1.0605 s || ETA: 0:58:42
torch.Size([21, 3, 640, 640])
Epoch:97/100 || Epochiter: 720/1010 || Iter: 97680/101000 || Loc: 0.1616 Cla: 0.8731 Landm: 0.7896 prop: 0.4784|| LR: 0.00005000 || Batchtime: 1.0446 s || ETA: 0:57:49
torch.Size([21, 3, 640, 640])
Epoch:97/100 || Epochiter: 721/1010 || Iter: 97681/101000 || Loc: 0.1620 Cla: 0.7691 Landm: 0.7850 prop: 0.6087|| LR: 0.00005000 || Batchtime: 1.0502 s || ETA: 0:58:06
torch.Size([21, 3, 640, 640])
'''

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants