Skip to content

How to modify pretrained weighted file : mask_rcnn_r50_fpn_mstrain-poly_3x_coco_20210524_201154-21b550bb.pth #4

@farzinnikkhah

Description

@farzinnikkhah

Hi,

I am currently working on a project using the MMDetection framework, I try to train a Mask R-CNN model with the TBBRV2 dataset, which has 5-channel images. I encountered an issue when trying to adapt the standard 3-channel pretrained model for this purpose.

During training, I ran into the following error:
RuntimeError: Expected 3D (unbatched) or 4D (batched) input to conv2d, but got input of size: [1, 2, 5, 2688, 3392]

I noticed that in your projects, you have used a modified pretrained file (e.g., "mask_rcnn_r50_fpn_mstrain-poly_3x_coco_20210524_201154-21b550bb_truncated.pth") which might have been adapted for similar scenarios. Could you provide guidance on how to modify the pretrained model file to be compatible with 5-channel input? Any advice or pointers towards resources or documentation would be greatly appreciated.

Thank you for your assistance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions