Skip to content

BenchmarkProblem

BenchmarkProblem

Bases: ABC

name abstractmethod classmethod

name() -> str

Return name of this benchmark problem.

description abstractmethod classmethod

description() -> str

Return single-line description of this benchmark problem.

supported_params abstractmethod classmethod

supported_params() -> dict[str, str]

Return a dictionary of supported parameters for this benchmark problem, as (param_name, param_description) key-value pairs in a dict.

get_example_parameters abstractmethod classmethod

get_example_parameters() -> dict[str, Any]

Return a dictionary of example acceptable parameter values for this benchmark problem, as (param_name, example_value) key-value pairs in a dict.

get_problem_dimensions abstractmethod classmethod

get_problem_dimensions(**kwargs) -> tuple[int, int, int, int, int]

Returns problem dimensions as (d, n, k, m, n_con_indices)-tuple for this benchmark problem, given the provided parameters. These dimensions can be indicative (especially n_con_indices), if they are stochastic. Main goal of this method is to get an idea of dimensions without needing to create the full problem instance.

Parameters:

Name Type Description Default
kwargs

parameters passed to create_problem_instance() for which we want to know resulting dimensions.

{}

create_problem_instance classmethod

create_problem_instance(**kwargs) -> MaxDivProblem

Create and return an instance of MaxDivProblem for this benchmark problem, using the provided parameters as needed.