|
| 1 | +# Configuration file for the Sphinx documentation builder. |
| 2 | +# |
| 3 | +# For the full list of built-in configuration values, see the documentation: |
| 4 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html |
| 5 | + |
| 6 | +import sys |
| 7 | +from pathlib import Path |
| 8 | + |
| 9 | +sys.path.insert(0, str(Path("../../src").resolve())) |
| 10 | + |
| 11 | +# -- Project information ----------------------------------------------------- |
| 12 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information |
| 13 | + |
| 14 | +project = "PyTorch-Project-Template" |
| 15 | +copyright = "2025, Junya Morioka" |
| 16 | +author = "Junya Morioka" |
| 17 | + |
| 18 | +# -- General configuration --------------------------------------------------- |
| 19 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration |
| 20 | + |
| 21 | +extensions = [ |
| 22 | + "myst_parser", |
| 23 | + "sphinx.ext.autodoc", |
| 24 | + "sphinx.ext.viewcode", |
| 25 | + "sphinx.ext.napoleon", |
| 26 | + "autoapi.extension", |
| 27 | +] |
| 28 | + |
| 29 | +templates_path = ["_templates"] |
| 30 | +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] |
| 31 | + |
| 32 | +language = "en" |
| 33 | + |
| 34 | +# -- Options for HTML output ----------------------------------------------- |
| 35 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output |
| 36 | + |
| 37 | +html_theme = "furo" |
| 38 | + |
| 39 | +# -- Options for autodoc -------------------------------------------------- |
| 40 | +autodoc_typehints = "signature" |
| 41 | + |
| 42 | +# -- Options for viewcode -------------------------------------------------- |
| 43 | +viewcode_follow_imported_members = True |
| 44 | + |
| 45 | +# -- Options for autoapi --------------------------------------------------- |
| 46 | +autoapi_type = "python" |
| 47 | +autoapi_dirs = ["../../src"] |
| 48 | +autoapi_root = "api" |
| 49 | +autoapi_keep_files = True |
| 50 | +autoapi_python_class_content = "init" |
| 51 | +autoapi_options = [ |
| 52 | + "members", |
| 53 | + "undoc-members", |
| 54 | + "private-members", |
| 55 | + "show-inheritance", |
| 56 | + "show-module-summary", |
| 57 | + "imported-members", |
| 58 | +] |
0 commit comments