From bfa2f20a355a7eb2431ca2c4a29e081103da6c7d Mon Sep 17 00:00:00 2001 From: liukuikun <24622904+Harold-lkk@users.noreply.github.com> Date: Wed, 31 Aug 2022 15:50:48 +0800 Subject: [PATCH] [Enchance] inter sphinx mapping (#1346) * inter sphinx mapping * fix comment --- docs/en/conf.py | 9 +++++++++ docs/zh_cn/conf.py | 10 ++++++++++ 2 files changed, 19 insertions(+) diff --git a/docs/en/conf.py b/docs/en/conf.py index b8f8894f..4481cb6f 100644 --- a/docs/en/conf.py +++ b/docs/en/conf.py @@ -124,6 +124,15 @@ html_css_files = ['css/readthedocs.css'] myst_heading_anchors = 3 +intersphinx_mapping = { + 'python': ('https://docs.python.org/3', None), + 'numpy': ('https://numpy.org/doc/stable', None), + 'torch': ('https://pytorch.org/docs/stable/', None), + 'mmcv': ('https://mmcv.readthedocs.io/en/dev-2.x/', None), + 'mmengine': ('https://mmengine.readthedocs.io/en/main/', None), + 'mmdetection': ('https://mmdetection.readthedocs.io/en/dev-3.x/', None), +} + def builder_inited_handler(app): subprocess.run(['./merge_docs.sh']) diff --git a/docs/zh_cn/conf.py b/docs/zh_cn/conf.py index b44774aa..d925d35e 100644 --- a/docs/zh_cn/conf.py +++ b/docs/zh_cn/conf.py @@ -124,6 +124,16 @@ html_css_files = ['css/readthedocs.css'] myst_heading_anchors = 3 +# Configuration for intersphinx +intersphinx_mapping = { + 'python': ('https://docs.python.org/3', None), + 'numpy': ('https://numpy.org/doc/stable', None), + 'torch': ('https://pytorch.org/docs/stable/', None), + 'mmcv': ('https://mmcv.readthedocs.io/zh_CN/dev-2.x/', None), + 'mmengine': ('https://mmengine.readthedocs.io/zh_CN/main/', None), + 'mmdetection': ('https://mmdetection.readthedocs.io/zh_CN/dev-3.x/', None), +} + def builder_inited_handler(app): subprocess.run(['./cp_origin_docs.sh'])