pub struct ExactConfig {
pub time_limit_ms: u64,
pub gap_tolerance: f64,
pub max_items: usize,
pub grid_step: f64,
pub rotation_steps: usize,
pub verbosity: u32,
pub seed: Option<u64>,
}Expand description
Configuration for exact (MILP-based) solvers.
Fields§
§time_limit_ms: u64Maximum computation time in milliseconds.
gap_tolerance: f64Relative MIP gap tolerance (0.0 = optimal, 0.01 = 1% gap allowed).
max_items: usizeMaximum number of items for exact solving (fallback to heuristic if exceeded).
grid_step: f64Grid discretization step for position variables.
rotation_steps: usizeNumber of discrete rotation angles to consider.
verbosity: u32Verbosity level (0 = silent, 1 = summary, 2+ = detailed).
seed: Option<u64>Random seed for reproducibility.
Implementations§
Source§impl ExactConfig
impl ExactConfig
Sourcepub fn with_time_limit_ms(self, ms: u64) -> Self
pub fn with_time_limit_ms(self, ms: u64) -> Self
Set time limit in milliseconds.
Sourcepub fn with_gap_tolerance(self, gap: f64) -> Self
pub fn with_gap_tolerance(self, gap: f64) -> Self
Set MIP gap tolerance.
Sourcepub fn with_max_items(self, max: usize) -> Self
pub fn with_max_items(self, max: usize) -> Self
Set maximum number of items for exact solving.
Sourcepub fn with_grid_step(self, step: f64) -> Self
pub fn with_grid_step(self, step: f64) -> Self
Set grid discretization step.
Sourcepub fn with_rotation_steps(self, steps: usize) -> Self
pub fn with_rotation_steps(self, steps: usize) -> Self
Set number of discrete rotation angles.
Sourcepub fn with_verbosity(self, level: u32) -> Self
pub fn with_verbosity(self, level: u32) -> Self
Set verbosity level.
Sourcepub fn is_within_limit(&self, num_items: usize) -> bool
pub fn is_within_limit(&self, num_items: usize) -> bool
Check if the number of items is within the exact solving limit.
Sourcepub fn rotation_angles(&self) -> Vec<f64>
pub fn rotation_angles(&self) -> Vec<f64>
Get discrete rotation angles in radians.
Trait Implementations§
Source§impl Clone for ExactConfig
impl Clone for ExactConfig
Source§fn clone(&self) -> ExactConfig
fn clone(&self) -> ExactConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ExactConfig
impl Debug for ExactConfig
Auto Trait Implementations§
impl Freeze for ExactConfig
impl RefUnwindSafe for ExactConfig
impl Send for ExactConfig
impl Sync for ExactConfig
impl Unpin for ExactConfig
impl UnsafeUnpin for ExactConfig
impl UnwindSafe for ExactConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.