1

I'm trying to extract visual embeddings from the detectron model with the help of this colab notebook. I want the shape of vector after passing through fc1 to be (1000, 2048), but somehow this model gives me output of (1000, 1024). Is there any way, we can tweak the features in the code which favours our result of (1000, 2048)? I think, we have to use a different config file (cfg, we are passing), but I'm not sure which file should we use to pass into the model. The current file which we are using is : cfg_path = "COCO-InstanceSegmentation/mask_rcnn_R_101_FPN_3x.yaml". If anybody can answer, it would be of great help.

    box_features = model.roi_heads.box_head.fc1(box_features)

    # print(box_features.shape) # torch.Size([1000, 1024])
lazytux
  • 157
  • 5

0 Answers0