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

Trained model weights only for backbone ? #16

Open
LedaguenelArthur opened this issue Aug 3, 2023 · 0 comments
Open

Trained model weights only for backbone ? #16

LedaguenelArthur opened this issue Aug 3, 2023 · 0 comments

Comments

@LedaguenelArthur
Copy link

Hi,

I am doing some experiments using 3D-RetinaNet and wanted to use the trained weights on Road that you share with the link : https://drive.google.com/drive/folders/1tOwQtQD3HWiTTp_ZgPCEWd4W-UKiglbt?usp=sharing

However these weights do not load properly on the whole network (missing keys and unexpected keys) using:
net.load_state_dict(torch.load(path))
I get for instance "anchors.cell_anchors.0" in missing keys and "module.anchors.cell_anchors.0" in unexpected keys.

The only way I could manage to make them work is by doing:
net.backbone.load_my_state_dict(torch.load(path))

But this means that regression and classification heads are not initialized with trained weights and the model is not directly usable at test time.

Anything I am missing or doing wrong ?

Best regards,
Arthur

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

1 participant