diff --git a/mmpose/engine/__init__.py b/mmpose/engine/__init__.py index 31785364b2..ac85928986 100644 --- a/mmpose/engine/__init__.py +++ b/mmpose/engine/__init__.py @@ -1,2 +1,3 @@ # Copyright (c) OpenMMLab. All rights reserved. from .hooks import * # noqa: F401, F403 +from .optim_wrappers import * # noqa: F401, F403 diff --git a/mmpose/registry.py b/mmpose/registry.py index f1c080565f..e3b8d17c4c 100644 --- a/mmpose/registry.py +++ b/mmpose/registry.py @@ -76,24 +76,22 @@ # Registries For Optimizer and the related # manage all kinds of optimizers like `SGD` and `Adam` OPTIMIZERS = Registry( - 'optimizer', - parent=MMENGINE_OPTIMIZERS, - locations=['mmpose.engine.optimizers']) + 'optimizer', parent=MMENGINE_OPTIMIZERS, locations=['mmpose.engine']) # manage optimizer wrapper OPTIM_WRAPPERS = Registry( 'optimizer_wrapper', parent=MMENGINE_OPTIM_WRAPPERS, - locations=['mmpose.engine.optimizers']) + locations=['mmpose.engine']) # manage constructors that customize the optimization hyperparameters. OPTIM_WRAPPER_CONSTRUCTORS = Registry( 'optimizer wrapper constructor', parent=MMENGINE_OPTIM_WRAPPER_CONSTRUCTORS, - locations=['mmpose.engine.optimizers']) + locations=['mmpose.engine.optim_wrappers']) # manage all kinds of parameter schedulers like `MultiStepLR` PARAM_SCHEDULERS = Registry( 'parameter scheduler', parent=MMENGINE_PARAM_SCHEDULERS, - locations=['mmpose.engine.schedulers']) + locations=['mmpose.engine']) # manage all kinds of metrics METRICS = Registry(