From fd016f438c47b9fd3320824e5fa6bb00772e9ff4 Mon Sep 17 00:00:00 2001 From: Peng Lu Date: Thu, 6 Apr 2023 15:30:14 +0800 Subject: [PATCH] [Fix] Fix link in config checker (#2163) --- README.md | 2 +- README_CN.md | 2 +- mmpose/apis/inference.py | 2 ++ mmpose/models/utils/check_and_update_config.py | 2 +- 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index ba653d997a..0a0d640cbd 100644 --- a/README.md +++ b/README.md @@ -108,7 +108,7 @@ https://user-images.githubusercontent.com/15977946/124654387-0fd3c500-ded1-11eb- - Build individual projects with full power of MMPose but not bound up with heavy frameworks - Checkout new projects: - [RTMPose](/projects/rtmpose/) - - [YOLOX-Pose](/projects/yolox_pose/) + - [YOLOX-Pose](/projects/yolox-pose/) - [MMPose4AIGC](/projects/mmpose4aigc/) - Become a contributors and make MMPose greater. Start your journey from the [example project](/projects/example_project/) diff --git a/README_CN.md b/README_CN.md index 53a6126890..c1c4898ca2 100644 --- a/README_CN.md +++ b/README_CN.md @@ -106,7 +106,7 @@ https://user-images.githubusercontent.com/15977946/124654387-0fd3c500-ded1-11eb- - 通过独立项目的形式,利用 MMPose 的强大功能,同时不被代码框架所束缚 - 最新添加的项目包括: - [RTMPose](/projects/rtmpose/) - - [YOLOX-Pose](/projects/yolox_pose/) + - [YOLOX-Pose](/projects/yolox-pose/) - [MMPose4AIGC](/projects/mmpose4aigc/) - 从简单的 [示例项目](/projects/example_project/) 开启您的 MMPose 代码贡献者之旅吧,让我们共同打造更好用的 MMPose! diff --git a/mmpose/apis/inference.py b/mmpose/apis/inference.py index f884d415ca..6763d318d5 100644 --- a/mmpose/apis/inference.py +++ b/mmpose/apis/inference.py @@ -8,6 +8,7 @@ import torch.nn as nn from mmengine.config import Config from mmengine.dataset import Compose, pseudo_collate +from mmengine.model.utils import revert_sync_batchnorm from mmengine.registry import init_default_scope from mmengine.runner import load_checkpoint from PIL import Image @@ -98,6 +99,7 @@ def init_model(config: Union[str, Path, Config], init_default_scope(config.get('default_scope', 'mmpose')) model = build_pose_estimator(config.model) + model = revert_sync_batchnorm(model) # get dataset_meta in this priority: checkpoint > config > default (COCO) dataset_meta = None diff --git a/mmpose/models/utils/check_and_update_config.py b/mmpose/models/utils/check_and_update_config.py index 7b856248bf..4cd1efa39b 100644 --- a/mmpose/models/utils/check_and_update_config.py +++ b/mmpose/models/utils/check_and_update_config.py @@ -166,7 +166,7 @@ def display_modifications(head_deleted_dict: Dict, head_append_dict: Dict, total_info += '```\nshould be updated to\n```\n' total_info += new_model_info total_info += '```\nFor more information, please refer to '\ - 'https://mmpose.readthedocs.io/en/dev-1.x/' \ + 'https://mmpose.readthedocs.io/en/latest/' \ 'guide_to_framework.html#step3-model' logger: MMLogger = MMLogger.get_current_instance()