Skip to content

Commit

Permalink
Merged in use_numpydoc (pull request #169)
Browse files Browse the repository at this point in the history
Use napoleon for auto-docs. [skip ci]
  • Loading branch information
prabhuramachandran committed May 22, 2015
2 parents bc628be + 7825987 commit 29280fc
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 15 deletions.
8 changes: 7 additions & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,13 @@

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.pngmath', 'sphinx.ext.mathjax', 'sphinx.ext.viewcode']
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.pngmath', 'sphinx.ext.mathjax',
'sphinx.ext.viewcode', 'sphinx.ext.napoleon']

napoleon_google_docstring = True
napoleon_numpy_docstring = True
napoleon_include_private_with_doc = False
napoleon_include_special_with_doc = True

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
Expand Down
3 changes: 2 additions & 1 deletion docs/source/reference/equations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,5 @@ Group of equations
-------------------

.. autoclass:: pysph.sph.equation.Group
:members:
:special-members:

34 changes: 21 additions & 13 deletions pysph/sph/equation.py
Original file line number Diff line number Diff line change
Expand Up @@ -354,25 +354,33 @@ def __init__(self, equations, real=True, update_nnps=False, iterate=False,
Parameters
-----------
- equations: list: a list of equation objects.
equations: list
a list of equation objects.
- real: bool: specifies if only non-remote/non-ghost particles should
be operated on.
real: bool
specifies if only non-remote/non-ghost particles should be
operated on.
- update_nnps: bool: specifies if the neighbors should be re-computed
locally after this group
update_nnps: bool
specifies if the neighbors should be re-computed locally after
this group
- iterate: bool: specifies if the group should continue iterating
until each equation's "converged()" methods returns
with a positive value.
iterate: bool
specifies if the group should continue iterating until each
equation's "converged()" methods returns with a positive value.
- max_iterations: int: specifies the maximum number of times this
group should be iterated.
max_iterations: int
specifies the maximum number of times this group should be
iterated.
- min_iterations: int: specifies the minimum number of times this
group should be iterated.
min_iterations: int
specifies the minimum number of times this group should be
iterated.
Note that when running simulations in parallel, one should typically
Notes
-----
When running simulations in parallel, one should typically
run the summation density over all particles (both local and remote)
in each processor. This is because we must update the
pressure/density of the remote neighbors in the current processor.
Expand Down

0 comments on commit 29280fc

Please sign in to comment.