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

Change docstring style to numpydocs #901

Open
wants to merge 16 commits into
base: master
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
- Fixed too strict getObjVal, getVal check
### Changed
- Changed createSol to now have an option of initialising at the current LP solution
- Unified documentation style of scip.pxi to numpydocs
### Removed

## 5.1.1 - 2024-06-22
Expand Down
83 changes: 45 additions & 38 deletions docs/api.rst
Original file line number Diff line number Diff line change
@@ -1,79 +1,86 @@
#############
API reference
API Reference
#############

This page provides an auto-generated summary of PySCIPOpt's API.

.. automodule:: pyscipopt

SCIP Model
==========

.. autosummary::
:toctree: _autosummary
:recursive:
This is the main class of PySCIPOpt. Most functionality is accessible through functions
of this class. All functions that require the SCIP object belong to this class.

.. toctree::
:maxdepth: 1

pyscipopt.Model
api/model

SCIP Constraint
===============

.. autosummary::
:toctree: _autosummary
:recursive:
This class wraps a SCIP constraint object. It contains functions that can retrieve basic information
that is entirely contained within the constraint object.

.. toctree::
:maxdepth: 1

pyscipopt.Constraint
api/constraint

SCIP Variable
=============

.. autosummary::
:toctree: _autosummary
:recursive:
This class wraps a SCIP variable object. It contains functions that can retrieve basic information
that is entirely contained within the variable object.

pyscipopt.Variable
.. toctree::
:maxdepth: 1

api/variable

SCIP Row
========

.. autosummary::
:toctree: _autosummary
:recursive:
This class wraps a SCIP row object. It contains functions that can retrieve basic information
that is entirely contained within the row object.

.. toctree::
:maxdepth: 1

pyscipopt.scip.Row
api/row

SCIP Column
===========

.. autosummary::
:toctree: _autosummary
:recursive:
This class wraps a SCIP column object. It contains functions that can retrieve basic information
that is entirely contained within the column object.

.. toctree::
:maxdepth: 1

pyscipopt.scip.Column
api/column

SCIP Node
=========

.. autosummary::
:toctree: _autosummary
:recursive:
This class wraps a SCIP node object. It contains functions that can retrieve basic information
that is entirely contained within the node object.

pyscipopt.scip.Node
.. toctree::
:maxdepth: 1

SCIP Solution
=============

.. autosummary::
:toctree: _autosummary
:recursive:

pyscipopt.scip.Solution
api/node

SCIP Event
===========
==========

This class wraps a SCIP event object. It contains functions that can retrieve basic information
that is entirely contained within the event object.

.. autosummary::
:toctree: _autosummary
:recursive:
.. toctree::
:maxdepth: 1

pyscipopt.scip.Event
api/event


6 changes: 6 additions & 0 deletions docs/api/column.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
##########
Column API
##########

.. autoclass:: pyscipopt.scip.Column
:members:
6 changes: 6 additions & 0 deletions docs/api/constraint.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
##############
Constraint API
##############

.. autoclass:: pyscipopt.Constraint
:members:
6 changes: 6 additions & 0 deletions docs/api/event.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
##########
Event API
##########

.. autoclass:: pyscipopt.scip.Event
:members:
6 changes: 6 additions & 0 deletions docs/api/model.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#########
Model API
#########

.. autoclass:: pyscipopt.Model
:members:
6 changes: 6 additions & 0 deletions docs/api/node.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
########
Node API
########

.. autoclass:: pyscipopt.scip.Node
:members:
6 changes: 6 additions & 0 deletions docs/api/row.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#######
Row API
#######

.. autoclass:: pyscipopt.scip.Row
:members:
6 changes: 6 additions & 0 deletions docs/api/variable.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
############
Variable API
############

.. autoclass:: pyscipopt.Variable
:members:
5 changes: 3 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,9 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ["_static"]

autosummary_generate = True
autoclass_content = "class"
autosummary_generate = False
napoleon_numpy_docstring = True
napoleon_google_docstring = False

pygments_style = "sphinx"

Expand Down
Loading
Loading