Skip to content

Commit

Permalink
Update docstrings to remove Sphinx warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
jsiirola committed Nov 18, 2024
1 parent 0528cfc commit 825a735
Showing 1 changed file with 18 additions and 3 deletions.
21 changes: 18 additions & 3 deletions pyomo/repn/plugins/parameterized_standard_form.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,28 @@
'bilevel optimization problem).',
)
class ParameterizedLinearStandardFormCompiler(LinearStandardFormCompiler):
r"""Compiler to convert a "Parameterized" LP to the matrix representation
of the standard form:
.. math::
\min\ & c^Tx \\
s.t.\ & Ax \le b
by treating the variables specified in the ``wrt`` list as data
(constants). The resulting compiled representation is returned as
NumPy arrays and SciPy sparse matrices in a
:py:class:`LinearStandardFormInfo` .
"""

CONFIG = LinearStandardFormCompiler.CONFIG()
CONFIG.declare(
'wrt',
ConfigValue(
default=None,
domain=ComponentDataSet(Var),
description="Vars to treat as data for the purposes of compiling"
description="Vars to treat as data for the purposes of compiling "
"the standard form",
doc="""
Optional list of Vars to be treated as data while compiling the
Expand All @@ -54,8 +69,8 @@ class ParameterizedLinearStandardFormCompiler(LinearStandardFormCompiler):

@document_kwargs_from_configdict(CONFIG)
def write(self, model, ostream=None, **options):
"""Convert a model to standard form (`min cTx s.t. Ax <= b`) treating the
Vars specified in 'wrt' as data
r"""Convert a model to standard form treating the Vars specified in
``wrt`` as data.
Returns
-------
Expand Down

0 comments on commit 825a735

Please sign in to comment.