devit
devit copied to clipboard
Thanks authors for the great work! Q: I am new to FSOD and I would like to check how many prototypes (examples?) are needed for my custom classes? I have...
1. Why does `build_prototypes.ipynb` use `model = torch.hub.load('facebookresearch/dinov2', 'dinov2_vitl14')` while inference in `demo.py` uses `model_path="weights/trained/open-vocabulary/lvis/vitl_0069999.pth"`? Should'nt the models be the same ? 2. Why do we have different weights file...
I modified demo\demo.py like ``` config_file="configs/one-shot/split1_vitl.yaml", rpn_config_file="configs/RPN/mask_rcnn_R_50_FPN_1x.yaml", model_path="weights/trained/oneshot/vitl_0074999.split1.pth", ``` But it crashed with following messge: ``` RuntimeError: Error(s) in loading state_dict for OpenSetDetectorWithExamples: Missing key(s) in state_dict: "offline_backbone.fpn_lateral2.weight", ```
Why are the shapes of these two files different? ycb_prototypes.pth :torch.Size([34, 1024]) weights/initial/open-vocabulary/prototypes/lvis/lvis_v1_novel_train.vitl14.pkl :torch.Size([337, 10, 1024]) weights/initial/few-shot/prototypes/fs_coco_trainval_novel_5shot.vitl14.pkl :torch.Size([20, 10, 1024]) I know dim0 is class num, but why the prototype...
Hi, Nice work! I am trying to run the model on custom data, and after building a set of prototypes, I have a large amount of false positives. I am...
I have downloaded the datasets and weights from gdrive, but when I try to train the model, some error happened. When I try to run `vit=l task=ovd dataset=coco bash scripts/train.sh`...
I want to train a few shot object detector to recognize only a single class, which I built prototypes for using this blueprint: https://github.com/mlzxy/devit/blob/main/demo/build_prototypes.ipynb Now when I run `python demo/demo.py`...
https://github.com/mlzxy/devit/blob/cfd0e0e28c8cdc8c0deff9b3f9dba7dcc1a08e61/demo/demo.py#L257 ````bash UserWarning: The given NumPy array is not writable, and PyTorch does not support non-writable tensors. This means writing to this ten sor will result in undefined behavior. You...
If there are no masks in the crop or image, then the current code divides by zero: https://github.com/mlzxy/devit/blob/cfd0e0e28c8cdc8c0deff9b3f9dba7dcc1a08e61/detectron2/modeling/meta_arch/devit.py#L180 The simple solution is: ```python loss = loss.sum() if num_masks != 0:...
In other type of dataset than COCO, having no bbox in a crop is likely. The "-1" dim in a reshape is imposible then. Change this: https://github.com/mlzxy/devit/blob/cfd0e0e28c8cdc8c0deff9b3f9dba7dcc1a08e61/lib/regionprop.py#L79 to this: `pred_roi_mask...