Using pretrained ResNet with MedicalNET weights #516
-
Hi, Could you help me find out where the mismatch come from? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
Hi @yiheng-wang-nv , Could you please help take a look at this ticket? Thanks in advance. |
Beta Was this translation helpful? Give feedback.
-
HI @Meddebma , the default number of input channels of monai's resnet is 3 (https://github.com/Project-MONAI/MONAI/blob/dev/monai/networks/nets/resnet.py#L163), but in the pretrained weights it was 1. If you need to use that pretrained weights, you may need to load the weights except the conv1 layer. |
Beta Was this translation helpful? Give feedback.
-
Hey @Meddebma, |
Beta Was this translation helpful? Give feedback.
HI @Meddebma , the default number of input channels of monai's resnet is 3 (https://github.com/Project-MONAI/MONAI/blob/dev/monai/networks/nets/resnet.py#L163), but in the pretrained weights it was 1. If you need to use that pretrained weights, you may need to load the weights except the conv1 layer.
You can check here for reference