picos.settings

Contains global settings for PICOS.

All settings can be set via environment variables using the PICOS_ prefix, e.g. PICOS_SOLVER_WHITELIST='["cvxopt", "glpk"]' ./application.py would set SOLVER_WHITELIST to ["cvxopt", "glpk"] for this execution of application.py only. Safe evaluation is used to convert the given value to a Python object.

Applications that use PICOS may assign to these settings directly (silently overwriting any environment variable) but libraries that depend on PICOS should not do so as this would affect also applications and other libraries that use both PICOS and the library making the modificaiton.

Data

picos.settings.ABSOLUTE_INTEGRALITY_TOLERANCE

Absolute tolerance used to validate integrality of integral variables.

picos.settings.DEFAULT_CHARSET

Default charset to use for console output.

Can be any of "ascii", "latin1" or "unicode" (default).

Note that applications can change the charset at any time using the respective function in the glyphs module.

picos.settings.INTERNAL_OPTIONS

Solution search options used whenever PICOS solves a problem internally.

By default, this limits the solver used to CVXOPT for reproducibility and to avoid licensing issues when non-free solvers are installed.

This setting is given as a dictionary. For keys and possible values see Options.

picos.settings.LICENSE_WARNINGS

Let solvers ignore verbosity settings to print licensing related warnings.

License warnings are only printed if both LICENSE_WARNINGS and the solution search option license_warnings are set to true, or if the verbosity setting allows solver output in general.

picos.settings.NONFREE_SOLVERS

Whether to add all non-free solvers to SOLVER_BLACKLIST.

picos.settings.RELATIVE_HERMITIANNESS_TOLERANCE

Relative tolerance used when checking whether a matrix is hermitian.

A matrix A \in \mathbb{C}^{n \times n} is considered numerically hermitian if

\max_{1 \leq i, j \leq n} |(A - A^H)_{ij}|
\leq
\varepsilon \max_{1 \leq i, j \leq n} |A_{ij}|

where \varepsilon is this tolerance.

picos.settings.RELATIVE_SEMIDEFINITENESS_TOLERANCE

Relative tolerance used when checking if a matrix is positive semidefinite.

A hermitian matrix A \in \mathbb{C}^{n \times n} is considered numerically positive semidefinite if

\min \operatorname{eigvals}(A)
\geq
-\varepsilon \max \left( \{ 1 \} \cup \operatorname{eigvals}(A) \right)

where \varepsilon is this tolerance.

picos.settings.SOLVER_BLACKLIST

A list of names of solvers that PICOS considers to be not available.

picos.settings.SOLVER_WHITELIST

A list of names of solvers; PICOS considers all others not available.