Overwrite the weights in load_from with new backbone weights #9097
-
Prerequisite
💬 Describe the reimplementation questionsHello all, I am currently trying to replace the backbone with a ResNeSt on one of the TOOD models. tood_r101_fpn_dconv_c3-c5_mstrain_2x_custom.py:
However, it seems that it is not the weights from the backbone that are initialized, but the ones from load_from. The output of the training with
Thx a lot :) EnvironmentUsing Pytorch 1.13 and conda Expected resultsNo response Additional informationConfig see above |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You can set init_cfg in bbox_head. For example: bbox_head=dict(
num_dcn=2,
init_cfg=dict(
type='Pretrained',
checkpoint='https://download.openmmlab.com/mmdetection/v2.0/tood/tood_r101_fpn_dconv_c3-c5_mstrain_2x_coco/tood_r101_fpn_dconv_c3-c5_mstrain_2x_coco_20211210_213728-4a824142.pth')) |
Beta Was this translation helpful? Give feedback.
-
Got it.Thx! |
Beta Was this translation helpful? Give feedback.
You can set init_cfg in bbox_head. For example: