Algorithms
Methods to configure, enable, disable and reset algorithms, and to run the solver.
Setup
setupAlgorithms
Configures algorithms from pathwyse.set, or default settings if not found.
setAlgorithms
Sets the algorithms to be used by the solver.
- names (list[str]) — list of algorithm names.
- active (list[bool], optional) — enable flags, one per algorithm. All enabled by default if omitted.
setAlgorithmsParallel
Sets whether algorithms should run in parallel.
- parallel (bool) —
Trueto enable parallel execution.
Enable / disable
enableAlgorithm
Enables the algorithm with the given id.
- id (int) — algorithm id.
disableAlgorithm
Disables the algorithm with the given id.
- id (int) — algorithm id.
enableAllAlgorithms
Enables all algorithms.
disableAllAlgorithms
Disables all algorithms.
Reset
resetAlgorithm
Resets the algorithm with the given id to an unoptimized state.
- id (int) — algorithm id.
- reset_level (int) — should be
0; not used in PathWyse 1.0.
resetAllAlgorithms
Resets all algorithms to an unoptimized state.
- reset_level (int) — should be
0; not used in PathWyse 1.0.
Query
isAlgorithmEnabled
Returns True if the algorithm with the given id is currently enabled, False otherwise.
- id (int) — algorithm id.
getEnabledAlgorithms
Returns the ids of all currently enabled algorithms.
areAlgorithmsParallel
Returns True if algorithms are configured to run in parallel, False otherwise.
Solve
solve
Solves the problem using the enabled algorithms.