megvii-research / LGD

Official Implementation of the detection self-distillation framework LGD.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

KeyError: "No object named 'None' found in 'CUSTOMIZED_DETECTORS' registry!"

YePG opened this issue · comments

commented

-- Process 1 terminated with the following error:
Traceback (most recent call last):
File "/home3/pgye/anaconda3/envs/LGD/lib/python3.7/site-packages/torch/multiprocessing/spawn.py", line 19, in _wrap
fn(i, *args)
File "/home3/pgye/anaconda3/envs/LGD/lib/python3.7/site-packages/detectron2/engine/launch.py", line 94, in _distributed_worker
main_func(*args)
File "/home3/pgye/LGD/train.py", line 262, in main
model = build_model(cfg)
File "/home3/pgye/anaconda3/envs/LGD/lib/python3.7/site-packages/detectron2/modeling/meta_arch/build.py", line 21, in build_model
model = META_ARCH_REGISTRY.get(meta_arch)(cfg)
File "/home3/pgye/LGD/models/distillator.py", line 129, in init
super().init(cfg)
File "/home3/pgye/LGD/models/base_distillator.py", line 19, in init
self.student, self.teacher = build_customized_detector(cfg)
File "/home3/pgye/LGD/models/customized_detectors/build.py", line 41, in build_customized_detector
student = get_model(cfg, cfg.MODEL.DISTILLATOR.STUDENT.META_ARCH)
File "/home3/pgye/LGD/models/customized_detectors/build.py", line 15, in get_model
model = CUSTOMIZED_DETECTORS_REGISTRY.get(meta_arch)(cfg)
File "/home3/pgye/anaconda3/envs/LGD/lib/python3.7/site-packages/fvcore/common/registry.py", line 72, in get
"No object named '{}' found in '{}' registry!".format(name, self._name)
KeyError: "No object named 'None' found in 'CUSTOMIZED_DETECTORS' registry!"

detectron2里没有这个CUSTOMIZED_DETECTORS 这是什么问题,是我版本没装对吗?我是按照你们的教程安装的

看报错的log来看, 你的meta_arch是None,请问您是跑什么backbone呢。可能需要在你的config文件里指定好这个变量名。