VarifocalNet
VarifocalNet copied to clipboard
KeyError: 'ATSSVGFLHead is not in the head registry'
Hello, I run the vfnet_r50_fpn_1x_coco.py and it works fine. However, when I run the vfl_atss_r50_fpn_1x_coco.py, I come across such problem, just as the title says. I have checked the init.py, and find ATSSVGFLHead is already there.
from .atss_vgfl_head import ATSSVGFLHead
__all__ = [ 'AnchorFreeHead', 'AnchorHead', 'GuidedAnchorHead', 'FeatureAdaption', 'RPNHead', 'GARPNHead', 'RetinaHead', 'RetinaSepBNHead', 'GARetinaHead', 'SSDHead', 'FCOSHead', 'RepPointsHead', 'FoveaHead', 'FreeAnchorRetinaHead', 'ATSSHead', 'FSAFHead', 'NASFCOSHead', 'PISARetinaHead', 'PISASSDHead', 'GFLHead', 'CornerHead', 'YOLACTHead', 'YOLACTSegmHead', 'YOLACTProtonet', 'YOLOV3Head', 'PAAHead', 'SABLRetinaHead', 'CentripetalHead', 'VFNetHead', 'TransformerHead', 'StageCascadeRPNHead', 'CascadeRPNHead', 'EmbeddingRPNHead', 'ATSSRawHead', 'ATSSVGFLHead', 'VFNetRawHead' ]
Also, the atss_vgfl_head.py has already registered such module by @HEADS.register_module()
. So I am confused about where the problem is, and I would like you to give me some advice. Thanks aaaaa lot~~
the train command is the same:
python tools/train.py xxxx
This is a bit weird. You may first check if you are using the correct version of mmdet. And then if there is atss_vgfl_head.py in the mmdet/models/dense_heads/ folder.
This is a bit weird. You may first check if you are using the correct version of mmdet. And then if there is atss_vgfl_head.py in the mmdet/models/dense_heads/ folder.
actually there is atss_vgfl_head.py in such folder. My mmdet version is 2.10.0, mmcv 1.2.4, torch 1.7.0
You may refer to this issue to see if you can get any help.
You may refer to this issue to see if you can get any help.
Really Strange... I tried custom_imports = dict( imports=['mmdet.models.dense_heads.atss_vgfl_head'],
and got such error:
ModuleNotFoundError: No module named 'mmdet.models.dense_heads.atss_vgfl_head'
However, when I tried [mmdet.models.dense_heads.vfnet_head]
, it worked.
As you can see, the atss_vgfl_head.py is already under dense_heads folder.
I think you may try running "pip install mmdet" in your environment to see if it works. According to your description, although you're using mmdet 2.10.0, it seems not the one tailored for VarifocalNet.
I think you may try running "pip install mmdet" in your environment to see if it works. According to your description, although you're using mmdet 2.10.0, it seems not the one tailored for VarifocalNet.
Thanks a lot~ I will try it later
I think you may try running "pip install mmdet" in your environment to see if it works. According to your description, although you're using mmdet 2.10.0, it seems not the one tailored for VarifocalNet.
Thanks a loooot~ I finally know that it is due to my installation of mmdet(2.10.0) is not exactly the same as your mmdet folder.
Cool!