24 std::vector<std::string> methods;
32 .setDefaultValueString(
"auto")
51 .setDefaultValueDouble(1e-06)
59 .setDefaultValueUnsignedInteger(0)
65 "The number of MIP solvers Gurobi spawns in parallel. Shall not be larger then the number of threads.")
68 .setDefaultValueUnsignedInteger(1)
92 if (method.has_value()) {
93 return method.value();
95 STORM_LOG_ASSERT(
false,
"Unknown method name should not get through validator");
114 "Gurobi is not selected as the preferred LP solver, so setting options for Gurobi might have no effect.");
117 "Requested more concurrent MILP solvers then the available threads for Gurobi.");
virtual uint_fast64_t getValueAsUnsignedInteger() const =0
Retrieves the value of this argument as an unsigned integer.
virtual double getValueAsDouble() const =0
Retrieves the value of this argument as a double.
static ArgumentBuilder createUnsignedIntegerArgument(std::string const &name, std::string const &description)
Creates an unsigned integer argument with the given parameters.
static ArgumentBuilder createDoubleArgument(std::string const &name, std::string const &description)
Creates a double argument with the given parameters.
static ArgumentBuilder createStringArgument(std::string const &name, std::string const &description)
Creates a string argument with the given parameters.
static std::shared_ptr< ArgumentValidator< uint64_t > > createUnsignedRangeValidatorIncluding(uint64_t lowerBound, uint64_t upperBound)
static std::shared_ptr< ArgumentValidator< double > > createDoubleRangeValidatorExcluding(double lowerBound, double upperBound)
static std::shared_ptr< ArgumentValidator< uint64_t > > createUnsignedGreaterEqualValidator(uint64_t lowerBound)
static std::shared_ptr< ArgumentValidator< std::string > > createMultipleChoiceValidator(std::vector< std::string > const &choices)
This class provides the interface to create an option...
ArgumentBase const & getArgumentByName(std::string const &argumentName) const
Returns a reference to the argument with the specified long name.
bool getHasOptionBeenSet() const
Retrieves whether the option has been set.
solver::GurobiSolverMethod getMethod() const
Retrieves the solver method.
bool isOutputSet() const
Retrieves whether the output option was set.
uint64_t getNumberOfThreads() const
Retrieves the maximal number of threads Gurobi is allowed to use.
bool check() const override
Checks whether the settings are consistent.
static const std::string moduleName
GurobiSettings()
Creates a new set of Gurobi settings.
bool isNumberOfThreadsSet() const
Retrieves whether the number of threads has been set.
uint64_t getNumberOfConcurrentMipThreads() const
Retrieves the number of MIP solvers, Gurobi spawns in parallel.
uint64_t getMIPFocus() const
Retrieves the selected high-level solution strategy for MILPs.
double getIntegerTolerance() const
Retrieves the integer tolerance to be used.
bool isIntegerToleranceSet() const
Retrieves whether the integer tolerance has been set.
ModuleSettings(std::string const &moduleName)
Constructs a new settings object.
void addOption(std::shared_ptr< Option > const &option)
Adds and registers the given option.
Option & getOption(std::string const &longName)
Retrieves the option with the given long name.
#define STORM_LOG_ASSERT(cond, message)
#define STORM_LOG_WARN_COND(cond, message)
static const std::string outputOption
static const std::string mipFocusOption
static const std::string threadsOption
static const std::string methodOption
static const std::string integerToleranceOption
static const std::string concurrentMipThreadsOption
SettingsType const & getModule()
Get module.
std::string toString(GurobiSolverMethod const &method)
Yields a string representation of the GurobiSolverMethod.
std::optional< GurobiSolverMethod > gurobiSolverMethodFromString(std::string const &method)
std::vector< GurobiSolverMethod > getGurobiSolverMethods()