|
| 1 | +# -*- coding: utf-8 -*- |
| 2 | +# |
| 3 | +# Configuration file for the Sphinx documentation builder. |
| 4 | +# |
| 5 | +# This file does only contain a selection of the most common options. For a |
| 6 | +# full list see the documentation: |
| 7 | +# http://www.sphinx-doc.org/en/master/config |
| 8 | + |
| 9 | +# -- Path setup -------------------------------------------------------------- |
| 10 | + |
| 11 | +# If extensions (or modules to document with autodoc) are in another directory, |
| 12 | +# add these directories to sys.path here. If the directory is relative to the |
| 13 | +# documentation root, use os.path.abspath to make it absolute, like shown here. |
| 14 | +# |
| 15 | +import os |
| 16 | +import sys |
| 17 | + |
| 18 | +sys.path.insert(0, os.path.abspath("..")) |
| 19 | + |
| 20 | + |
| 21 | +# -- Project information ----------------------------------------------------- |
| 22 | + |
| 23 | +project = "numpy-ml" |
| 24 | +copyright = "2019, David Bourgin" |
| 25 | +author = "David Bourgin" |
| 26 | + |
| 27 | +# The short X.Y version |
| 28 | +version = "" |
| 29 | +# The full version, including alpha/beta/rc tags |
| 30 | +release = "" |
| 31 | + |
| 32 | + |
| 33 | +# -- General configuration --------------------------------------------------- |
| 34 | + |
| 35 | +# If your documentation needs a minimal Sphinx version, state it here. |
| 36 | +# |
| 37 | +# needs_sphinx = '1.0' |
| 38 | + |
| 39 | +# Add any Sphinx extension module names here, as strings. They can be |
| 40 | +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom |
| 41 | +# ones. |
| 42 | +extensions = [ |
| 43 | + "sphinx.ext.autodoc", |
| 44 | + "sphinx.ext.doctest", |
| 45 | + "sphinx.ext.intersphinx", |
| 46 | + "sphinx.ext.todo", |
| 47 | + "sphinx.ext.coverage", |
| 48 | + "sphinx.ext.mathjax", |
| 49 | + "sphinx.ext.ifconfig", |
| 50 | + "sphinx.ext.viewcode", |
| 51 | + "sphinx.ext.githubpages", |
| 52 | + "sphinx.ext.napoleon", |
| 53 | + # "numpydoc", |
| 54 | +] |
| 55 | + |
| 56 | +# Napoleon settings |
| 57 | +# https://sphinxcontrib-napoleon.readthedocs.io/en/latest/sphinxcontrib.napoleon.html#sphinxcontrib.napoleon.Config |
| 58 | +napoleon_google_docstring = False |
| 59 | +napoleon_numpy_docstring = True |
| 60 | +napoleon_include_init_with_doc = False |
| 61 | +napoleon_include_private_with_doc = False |
| 62 | +napoleon_include_special_with_doc = False |
| 63 | +napoleon_use_admonition_for_examples = False |
| 64 | +napoleon_use_admonition_for_notes = False |
| 65 | +napoleon_use_admonition_for_references = False |
| 66 | +napoleon_use_ivar = True |
| 67 | +napoleon_use_param = True |
| 68 | +napoleon_use_rtype = False |
| 69 | +napoleon_use_keyword = True |
| 70 | + |
| 71 | + |
| 72 | +# Add any paths that contain templates here, relative to this directory. |
| 73 | +templates_path = ["_templates"] |
| 74 | + |
| 75 | +# The suffix(es) of source filenames. |
| 76 | +# You can specify multiple suffix as a list of string: |
| 77 | +# |
| 78 | +# source_suffix = ['.rst', '.md'] |
| 79 | +source_suffix = ".rst" |
| 80 | + |
| 81 | +# The master toctree document. |
| 82 | +master_doc = "index" |
| 83 | + |
| 84 | +# The language for content autogenerated by Sphinx. Refer to documentation |
| 85 | +# for a list of supported languages. |
| 86 | +# |
| 87 | +# This is also used if you do content translation via gettext catalogs. |
| 88 | +# Usually you set "language" from the command line for these cases. |
| 89 | +language = None |
| 90 | + |
| 91 | +# List of patterns, relative to source directory, that match files and |
| 92 | +# directories to ignore when looking for source files. |
| 93 | +# This pattern also affects html_static_path and html_extra_path. |
| 94 | +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] |
| 95 | + |
| 96 | +# The name of the Pygments (syntax highlighting) style to use. |
| 97 | +pygments_style = "friendly" |
| 98 | + |
| 99 | +autoclass_content = "both" |
| 100 | + |
| 101 | + |
| 102 | +# -- Options for HTML output ------------------------------------------------- |
| 103 | + |
| 104 | +# The theme to use for HTML and HTML Help pages. See the documentation for |
| 105 | +# a list of builtin themes. |
| 106 | +# |
| 107 | +html_theme = "alabaster" |
| 108 | + |
| 109 | +# Theme options are theme-specific and customize the look and feel of a theme |
| 110 | +# further. For a list of options available for each theme, see the |
| 111 | +# documentation. |
| 112 | +# |
| 113 | +# html_theme_options = {} |
| 114 | + |
| 115 | +# Add any paths that contain custom static files (such as style sheets) here, |
| 116 | +# relative to this directory. They are copied after the builtin static files, |
| 117 | +# so a file named "default.css" will overwrite the builtin "default.css". |
| 118 | +html_static_path = ["_static"] |
| 119 | + |
| 120 | +# Custom sidebar templates, must be a dictionary that maps document names |
| 121 | +# to template names. |
| 122 | +# |
| 123 | +# The default sidebars (for documents that don't match any pattern) are |
| 124 | +# defined by theme itself. Builtin themes are using these templates by |
| 125 | +# default: ``['localtoc.html', 'relations.html', 'sourcelink.html', |
| 126 | +# 'searchbox.html']``. |
| 127 | +# |
| 128 | +html_sidebars = { |
| 129 | + "**": [ |
| 130 | + "about.html", |
| 131 | + "navigation.html", |
| 132 | + "relations.html", |
| 133 | + "searchbox.html", |
| 134 | + "donate.html", |
| 135 | + ] |
| 136 | +} |
| 137 | + |
| 138 | +html_theme_options = { |
| 139 | + # 'logo': 'logo.png', |
| 140 | + "github_user": "ddbourgin", |
| 141 | + "github_repo": "numpy-ml", |
| 142 | + "description": "Machine learning, in NumPy", |
| 143 | + # 'analytics_id': "", XXX: TODO |
| 144 | + "github_button": True, |
| 145 | + "show_powered_by": False, |
| 146 | +} |
| 147 | + |
| 148 | + |
| 149 | +# -- Options for HTMLHelp output --------------------------------------------- |
| 150 | + |
| 151 | +# Output file base name for HTML help builder. |
| 152 | +htmlhelp_basename = "numpy-mldoc" |
| 153 | + |
| 154 | + |
| 155 | +# -- Options for LaTeX output ------------------------------------------------ |
| 156 | + |
| 157 | +latex_elements = { |
| 158 | + # The paper size ('letterpaper' or 'a4paper'). |
| 159 | + # |
| 160 | + # 'papersize': 'letterpaper', |
| 161 | + # The font size ('10pt', '11pt' or '12pt'). |
| 162 | + # |
| 163 | + # 'pointsize': '10pt', |
| 164 | + # Additional stuff for the LaTeX preamble. |
| 165 | + # |
| 166 | + # 'preamble': '', |
| 167 | + # Latex figure (float) alignment |
| 168 | + # |
| 169 | + # 'figure_align': 'htbp', |
| 170 | +} |
| 171 | + |
| 172 | +# Grouping the document tree into LaTeX files. List of tuples |
| 173 | +# (source start file, target name, title, |
| 174 | +# author, documentclass [howto, manual, or own class]). |
| 175 | +latex_documents = [ |
| 176 | + (master_doc, "numpy-ml.tex", "numpy-ml Documentation", "David Bourgin", "manual") |
| 177 | +] |
| 178 | + |
| 179 | + |
| 180 | +# -- Options for manual page output ------------------------------------------ |
| 181 | + |
| 182 | +# One entry per manual page. List of tuples |
| 183 | +# (source start file, name, description, authors, manual section). |
| 184 | +man_pages = [(master_doc, "numpy-ml", "numpy-ml Documentation", [author], 1)] |
| 185 | + |
| 186 | + |
| 187 | +# -- Options for Texinfo output ---------------------------------------------- |
| 188 | + |
| 189 | +# Grouping the document tree into Texinfo files. List of tuples |
| 190 | +# (source start file, target name, title, author, |
| 191 | +# dir menu entry, description, category) |
| 192 | +texinfo_documents = [ |
| 193 | + ( |
| 194 | + master_doc, |
| 195 | + "numpy-ml", |
| 196 | + "numpy-ml Documentation", |
| 197 | + author, |
| 198 | + "numpy-ml", |
| 199 | + "Machine learning, in NumPy.", |
| 200 | + "Miscellaneous", |
| 201 | + ) |
| 202 | +] |
| 203 | + |
| 204 | + |
| 205 | +# -- Options for Epub output ------------------------------------------------- |
| 206 | + |
| 207 | +# Bibliographic Dublin Core info. |
| 208 | +epub_title = project |
| 209 | + |
| 210 | +# The unique identifier of the text. This can be a ISBN number |
| 211 | +# or the project homepage. |
| 212 | +# |
| 213 | +# epub_identifier = '' |
| 214 | + |
| 215 | +# A unique identification for the text. |
| 216 | +# |
| 217 | +# epub_uid = '' |
| 218 | + |
| 219 | +# A list of files that should not be packed into the epub file. |
| 220 | +epub_exclude_files = ["search.html"] |
| 221 | + |
| 222 | +autodoc_member_order = "bysource" |
| 223 | + |
| 224 | + |
| 225 | +# -- Extension configuration ------------------------------------------------- |
| 226 | + |
| 227 | +# -- Options for intersphinx extension --------------------------------------- |
| 228 | + |
| 229 | +# Example configuration for intersphinx: refer to the Python standard library. |
| 230 | +intersphinx_mapping = { |
| 231 | + "python": ("https://docs.python.org/", None), |
| 232 | + "numpy": ("http://docs.scipy.org/doc/numpy/", None), |
| 233 | +} |
| 234 | + |
| 235 | +# -- Options for todo extension ---------------------------------------------- |
| 236 | + |
| 237 | +# If true, `todo` and `todoList` produce output, else they produce nothing. |
| 238 | +todo_include_todos = True |
| 239 | + |
| 240 | +# -- Options for numpydocs extension ----------------------------------------- |
| 241 | +# https://numpydoc.readthedocs.io/en/latest/install.html |
| 242 | + |
| 243 | +# Whether to produce plot:: directives for Examples sections that contain |
| 244 | +# import matplotlib or from matplotlib import. |
| 245 | +numpydoc_use_plots = True |
| 246 | + |
| 247 | +# Whether to show all members of a class in the Methods and Attributes sections |
| 248 | +# automatically. True by default. |
| 249 | +numpydoc_show_class_members = True |
| 250 | + |
| 251 | +# Whether to show all inherited members of a class in the Methods and |
| 252 | +# Attributes sections automatically. If it’s false, inherited members won’t |
| 253 | +# shown. True by default. |
| 254 | +numpydoc_show_inherited_class_members = True |
| 255 | + |
| 256 | +# Whether to create a Sphinx table of contents for the lists of class methods |
| 257 | +# and attributes. If a table of contents is made, Sphinx expects each entry to |
| 258 | +# have a separate page. True by default. |
| 259 | +numpydoc_class_members_toctree = False |
| 260 | + |
| 261 | +# A regular expression matching citations which should be mangled to avoid |
| 262 | +# conflicts due to duplication across the documentation. Defaults to [\w-]+. |
| 263 | +numpydoc_citation_re = r"[\w-]+" |
| 264 | + |
| 265 | +# Until version 0.8, parameter definitions were shown as blockquotes, rather |
| 266 | +# than in a definition list. If your styling requires blockquotes, switch this |
| 267 | +# config option to True. This option will be removed in version 0.10. |
| 268 | +numpydoc_use_blockquotes = False |
| 269 | + |
| 270 | +# Whether to format the Attributes section of a class page in the same way as |
| 271 | +# the Parameter section. If it's False, the Attributes section will be |
| 272 | +# formatted as the Methods section using an autosummary table. True by default. |
| 273 | +numpydoc_attributes_as_param_list = False |
| 274 | + |
| 275 | +# Whether to create cross-references for the parameter types in the Parameters, |
| 276 | +# Other Parameters, Returns and Yields sections of the docstring. False by |
| 277 | +# default. |
| 278 | +numpydoc_xref_param_type = False |
| 279 | + |
| 280 | +# Mappings to fully qualified paths (or correct ReST references) for the |
| 281 | +# aliases/shortcuts used when specifying the types of parameters. The keys |
| 282 | +# should not have any spaces. Together with the intersphinx extension, you can |
| 283 | +# map to links in any documentation. The default is an empty dict. This |
| 284 | +# option depends on the numpydoc_xref_param_type option being True. |
| 285 | +numpydoc_xref_aliases = {} |
| 286 | + |
| 287 | +# Words not to cross-reference. Most likely, these are common words used in |
| 288 | +# parameter type descriptions that may be confused for classes of the same |
| 289 | +# name. For example: {'type', 'optional', 'default'}. The default is an empty |
| 290 | +# set. |
| 291 | +numpydoc_xref_ignore = set([]) |
| 292 | + |
| 293 | +# Deprecated since version edit: your HTML template instead Whether to insert |
| 294 | +# an edit link after docstrings. |
| 295 | +numpydoc_edit_link: bool |
0 commit comments