MMDetection3D与OpenPCDet中模型调用的步骤

MMDetection3D

mmdetection3d/tools/train.py train_model()
mmdetection3d/mmdet3d/api/train.py train_detector() => runner.run()

mmcv/runner/epoch_based_runner.py EpochBasedRunner.run()
=> self.train() => self.run_iter() => self.model.train_step()

mmdetection/mmdet/models/detectors/base.py train_step() => 当前detector.forward() => 得到loss

loss会保存在runner.output[‘loss’]

mmcv/runner/hooks/optimizer.py after_train_iter() 调用 loss.backward()

OpenPCDet

openpcdet/tools/train.py train_model()
openpcdet/tools/train_utils.py train_one_epoch() => model_func [ 常见为model_fn_decorator() ]
openpcdet/pcdet/models/__init__.py 当前detector.forward() => 得到loss

回到 train_one_epoch() 中调用 loss.backward()

你可能感兴趣的:(3D目标检测,python,深度学习,人工智能)