|
1 | 1 | import datetime |
2 | 2 | import doctest |
| 3 | +import os |
| 4 | +import sys |
| 5 | + |
3 | 6 | import sphinx_rtd_theme |
4 | 7 |
|
| 8 | +sys.path.insert(0, os.path.abspath('../../')) |
| 9 | + |
5 | 10 | extensions = [ |
6 | | - 'autoapi.extension', |
| 11 | + 'sphinx.ext.autodoc', |
| 12 | + 'sphinx.ext.autosummary', |
7 | 13 | 'sphinx.ext.doctest', |
8 | 14 | 'sphinx.ext.intersphinx', |
9 | 15 | 'sphinx.ext.mathjax', |
|
14 | 20 |
|
15 | 21 | source_suffix = '.rst' |
16 | 22 | master_doc = 'index' |
17 | | -author = 'Yixuan He' |
| 23 | + |
18 | 24 | project = 'PyTorch Geometric Signed Directed' |
| 25 | +author = 'Yixuan He' |
19 | 26 | copyright = '{}, {}'.format(datetime.datetime.now().year, author) |
20 | 27 |
|
21 | 28 | html_theme = 'sphinx_rtd_theme' |
| 29 | +html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] |
22 | 30 | html_theme_options = { |
23 | 31 | 'collapse_navigation': False, |
24 | 32 | 'display_version': True, |
25 | 33 | 'logo_only': True, |
| 34 | + 'navigation_depth': 2, |
26 | 35 | } |
27 | 36 |
|
28 | | -doctest_default_flags = doctest.NORMALIZE_WHITESPACE |
29 | | -intersphinx_mapping = {'python': ('https://docs.python.org/', None)} |
30 | | - |
31 | 37 | html_logo = '_static/img/text_logo.jpg' |
32 | 38 | html_static_path = ['_static'] |
33 | 39 | html_context = {'css_files': ['_static/css/custom.css']} |
34 | | -add_module_names = False |
35 | 40 |
|
36 | | -autoapi_type = 'python' |
37 | | -autoapi_dirs = ['../../torch_geometric_signed_directed/'] |
38 | | -autoapi_keep_files = True |
39 | | -autoapi_generate_api_docs = True |
| 41 | +doctest_default_flags = doctest.NORMALIZE_WHITESPACE |
| 42 | +intersphinx_mapping = {'python': ('https://docs.python.org/', None)} |
| 43 | +add_module_names = False |
| 44 | +autosummary_generate = True |
40 | 45 |
|
41 | 46 | autodoc_mock_imports = [ |
42 | 47 | 'torch', |
|
45 | 50 | 'torch_scatter', |
46 | 51 | ] |
47 | 52 |
|
| 53 | +exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] |
| 54 | + |
| 55 | + |
48 | 56 | def setup(app): |
49 | 57 | def skip(app, what, name, obj, skip, options): |
50 | 58 | members = ['__init__', '__repr__', '__weakref__', '__dict__', '__module__'] |
|
0 commit comments