Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📝 Document "♻️ Split ResourcePool into three classes" #325

Open
wants to merge 7 commits into
base: source
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion docs/_sources/_templates/layout.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
{% extends "!layout.html" %}

{%- block scripts %}
{{ super() }}
<script src="{{ pathto('assets/js/jquery.min.js', 1) }}"></script>
<script src="{{ pathto('_static/underscore.js', 1) }}"></script>
{%- endblock %}
{% block footer %}
{{ super() }}
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-19224662-10"></script>
Expand Down
2 changes: 1 addition & 1 deletion docs/_sources/autodoc_nodeblock.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from typing import TYPE_CHECKING, Any
from CPAC.pipeline.nodeblock import NodeBlockFunction
from CPAC.pipeline.engine.nodeblock import NodeBlockFunction
from docutils.statemachine import StringList
from sphinx.ext.autodoc import Documenter, FunctionDocumenter, bool_option

Expand Down
13 changes: 12 additions & 1 deletion docs/_sources/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

from dateutil import parser as dparser
from CPAC import __version__
from CPAC.pipeline.nodeblock import NodeBlockFunction
from CPAC.pipeline.engine.nodeblock import NodeBlockFunction
from CPAC.utils.monitoring import custom_logging
from github import Github
from github.GithubException import RateLimitExceededException, \
Expand Down Expand Up @@ -169,6 +169,13 @@ def yaml_to_rst(path):
'exec',
'nbsphinx']

add_module_names = False
maximum_signature_line_length = 90

autoclass_content = "both"
autodoc_typehints = "both"
autodoc_typehints_format = "short"

bibtex_bibfiles = [f'references/{bib}' for bib in os.listdir('references') if
bib.endswith('.bib')]
bibtex_default_style = 'cpac_docs_style'
Expand All @@ -179,7 +186,11 @@ def yaml_to_rst(path):

issues_github_path = 'FCP-INDI/C-PAC'

napoleon_attr_annotations = True
napoleon_include_private_with_doc = True
napoleon_preprocess_types = True
napoleon_use_admonition_for_notes = True


# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
Expand Down
1 change: 0 additions & 1 deletion docs/_sources/developer/logging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ A ``CPAC.utils.monitoring.custom_logging.MockLogger`` can be used in place of a
.. autofunction:: CPAC.utils.monitoring.custom_logging.getLogger

.. autoclass:: CPAC.utils.monitoring.custom_logging.MockLogger
:special-members: __init__
:members:
:inherited-members:

Expand Down
5 changes: 0 additions & 5 deletions docs/_sources/developer/nodes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,14 @@ For nodes that will use a varying amount of memory depending on the node's input


.. autoclass:: CPAC.pipeline.nipype_pipeline_engine.Node
:special-members: __init__
:members:
:inherited-members:

.. autoclass:: CPAC.pipeline.nipype_pipeline_engine.MapNode
:special-members: __init__
:members:
:inherited-members:

.. autoclass:: nipype.interfaces.base.core.Interface
:special-members: __init__
:members:
:inherited-members:

Expand All @@ -50,12 +47,10 @@ For nodes that will use a varying amount of memory depending on the node's input


.. autoclass:: CPAC.utils.interfaces.function.Function
:special-members: __init__
:members:
:inherited-members:

.. autoclass:: CPAC.pipeline.nipype_pipeline_engine.Workflow
:special-members: __init__
:members:
:inherited-members:

Expand Down
31 changes: 31 additions & 0 deletions docs/_sources/developer/pipeline.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,40 @@ Pipeline Development

.. include:: /developer/schema.rst

Engine
^^^^^^

NodeBlock
---------

.. automodule:: CPAC.pipeline.engine.nodeblock
:members:
:inherited-members:
:private-members:
:undoc-members:

Resource
--------

.. automodule:: CPAC.pipeline.engine.resource
:members:
:inherited-members:
:private-members:
:undoc-members:

Tests
-----

.. automodule:: CPAC.pipeline.test.test_engine
:members:
:inherited-members:
:private-members:
:undoc-members:

Pipeline Utilities
^^^^^^^^^^^^^^^^^^

.. automodule:: CPAC.pipeline.utils
:members:
:inherited-members:
:undoc-members:
3 changes: 1 addition & 2 deletions docs/_sources/developer/schema.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
.. _validation_schema:

*****************
Validation Schema
*****************
^^^^^^^^^^^^^^^^^

C-PAC uses `voluptuous <alecthomas.github.io/voluptuous/docs/_build/html>`_ to validate pipeline configurations against defined types and value restrictions. Default values should be set in :doc:`the default pipeline </user/pipelines/default>` along with comments explaining each option.

Expand Down
3 changes: 0 additions & 3 deletions docs/_sources/developer/workflows/network_centrality.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,16 @@ Network Centrality
==================

.. automodule:: CPAC.network_centrality.network_centrality
:special-members: __init__
:members:
:private-members:
:undoc-members:

.. automodule:: CPAC.network_centrality.pipeline
:special-members: __init__
:members:
:private-members:
:undoc-members:

.. automodule:: CPAC.network_centrality.utils
:special-members: __init__
:members:
:private-members:
:undoc-members:
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ m2r
mistune==0.8.4
nbsphinx
PyGithub
pytest
sphinx==7.3.2
sphinx-basic-ng>=1.0.0.beta2
sphinxcontrib-bibtex==2.5.0
Expand Down