#[non_exhaustive]pub struct SolveOptions {
pub time_limit: Option<Duration>,
pub node_limit: Option<u64>,
pub mip_gap: f64,
pub int_tol: f64,
pub warm_start: Option<Vec<(Variable, f64)>>,
pub tolerances: Tolerances,
}Expand description
Options controlling a solve. Construct with SolveOptions::default and
mutate the fields you need.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.time_limit: Option<Duration>Wall-clock budget for this call (None = unlimited). On expiry the search
and can be resumed.
node_limit: Option<u64>Maximum number of branch & bound nodes to solve in this call
(None = unlimited). Deterministic alternative to time_limit; the
budget applies per call, so crate::SolveOutcome::resume reapplies it
as a fresh budget. The root relaxation does not count as a node.
mip_gap: f64Relative MIP gap at which the search may stop with a feasible incumbent.
Such a stop reports SolutionStatus::Feasible and
TerminationReason::MipGap. Must be finite and non-negative. Default
0.0 (prove exact optimality).
int_tol: f64Integrality tolerance: a value within this distance of an integer counts
as integral. Default 1e-6. A very loose int_tol mainly causes extra
exact-fixing branching rather than admitting an infeasible point.
Must be finite and in the half-open range [0, 0.5).
warm_start: Option<Vec<(Variable, f64)>>Optional (partial) starting assignment used to seed the incumbent.
An infeasible or incomplete hint is ignored. Default None.
tolerances: TolerancesEdit the tolerances used by the solver, most callers
should leave this at Tolerances::default; override an individual
field only once you understand the correctness/permissiveness
trade-off documented on it.
Trait Implementations§
Source§impl Clone for SolveOptions
impl Clone for SolveOptions
Source§fn clone(&self) -> SolveOptions
fn clone(&self) -> SolveOptions
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more