optiprofiler.problem_libs.pycutest.pycutest_select

optiprofiler.problem_libs.pycutest.pycutest_select#

optiprofiler.problem_libs.pycutest.pycutest_select(options)[source]#

Select problems from PyCUTEst that satisfy given criteria.

More details about PyCUTEst can be found at the PyCUTEst documentation.

Note

PyCUTEst is only available on Linux and macOS.

Parameters:
optionsdict

A dictionary containing selection criteria. Supported keys:

  • ptype (str) – Type of problems to select. A string consisting of any combination of 'u' (unconstrained), 'b' (bound constrained), 'l' (linearly constrained), and 'n' (nonlinearly constrained), such as 'b', 'ul', 'ubn'. Default is 'ubln'.

  • mindim (int) – Minimum dimension. Default is 1.

  • maxdim (int) – Maximum dimension. Default is inf.

  • minb (int) – Minimum number of bound constraints. Default is 0.

  • maxb (int) – Maximum number of bound constraints. Default is inf.

  • minlcon (int) – Minimum number of linear constraints. Default is 0.

  • maxlcon (int) – Maximum number of linear constraints. Default is inf.

  • minnlcon (int) – Minimum number of nonlinear constraints. Default is 0.

  • maxnlcon (int) – Maximum number of nonlinear constraints. Default is inf.

  • mincon (int) – Minimum total number of linear and nonlinear constraints. Default is 0.

  • maxcon (int) – Maximum total number of linear and nonlinear constraints. Default is inf.

  • excludelist (list of str) – List of problem names to exclude. Default is [].

Returns:
list of str

Problem names that satisfy the given criteria.

See also

pycutest_load

Load a problem from PyCUTEst.

optiprofiler.get_plib_config

Read the current configuration.

optiprofiler.set_plib_config

Override configuration at runtime.

Notes

  1. PyCUTEst is only available on Linux and macOS.

  2. There is a file config.txt in the same directory as this module. It can be used to set the options variable_size and test_feasibility_problems. See the comments in config.txt for details. You can also override these options at runtime using set_plib_config or by setting environment variables PYCUTEST_VARIABLE_SIZE and PYCUTEST_TEST_FEASIBILITY_PROBLEMS. Environment variables take precedence over config.txt.

Examples

from optiprofiler.problem_libs.pycutest import pycutest_select

names = pycutest_select({'ptype': 'u', 'maxdim': 5})