[Doc] Use intersphinx and update entrypoints docs (#5125)

This commit is contained in:
Cyrus Leung
2024-05-31 00:59:23 +08:00
committed by GitHub
parent d79d9eaaff
commit a9bcc7afb2
4 changed files with 32 additions and 13 deletions

View File

@@ -80,7 +80,7 @@ def setup(app):
generate_examples()
# Mock out external dependencies here.
# Mock out external dependencies here, otherwise the autodoc pages may be blank.
autodoc_mock_imports = [
"cpuinfo",
"torch",
@@ -115,4 +115,15 @@ class MockedClassDocumenter(autodoc.ClassDocumenter):
autodoc.ClassDocumenter = MockedClassDocumenter
intersphinx_mapping = {
'python': ('https://docs.python.org/3', None),
'typing_extensions':
('https://typing-extensions.readthedocs.io/en/latest', None),
'numpy': ('https://numpy.org/doc/stable', None),
'torch': ('https://pytorch.org/docs/stable', None),
'psutil': ('https://psutil.readthedocs.io/en/stable', None),
}
autodoc_preserve_defaults = True
navigation_with_keys = False