pub struct MarkerSpec {
pub r_inner_expected: f32,
pub inner_search_halfwidth: f32,
pub inner_grad_polarity: GradPolarity,
pub radial_samples: usize,
pub theta_samples: usize,
pub aggregator: AngularAggregator,
pub min_theta_coverage: f32,
pub min_theta_consistency: f32,
}Expand description
Marker spec in outer-normalized radius units.
NOTE: Defaults are derived from the synthetic renderer in tools/gen_synth.py
and the current edge sampler semantics in ring::edge_sample::sample_edges.
In gen_synth.py the marker uses:
- outer_radius = pitch_mm * 0.6
- inner_radius = pitch_mm * 0.4
- ring_width = outer_radius * 0.12 (non-stress default)
The edge sampler finds the boundary of the merged dark band under blur, so the expected (inner_edge / outer_edge) ratio in outer-normalized units is: r_inner_expected = (inner_radius - ring_width) / (outer_radius + ring_width)
Fields§
§r_inner_expected: f32Expected inner radius as fraction of outer radius.
inner_search_halfwidth: f32Allowed deviation in normalized radius around r_inner_expected.
inner_grad_polarity: GradPolarityExpected sign of dI/dr at the inner edge.
radial_samples: usizeNumber of radii samples per theta.
theta_samples: usizeNumber of theta samples.
aggregator: AngularAggregatorAggregator across theta.
min_theta_coverage: f32Minimum fraction of theta samples required for a valid estimate.
min_theta_consistency: f32Minimum fraction of theta samples that must agree on the inner edge location (used as a quality gate).
Kept separate from min_theta_coverage: “coverage” is about in-bounds
sampling, while “consistency” is about peak agreement.
Implementations§
Source§impl MarkerSpec
impl MarkerSpec
Sourcepub fn search_window(&self) -> [f32; 2]
pub fn search_window(&self) -> [f32; 2]
Return normalized radial search window around r_inner_expected.
Trait Implementations§
Source§impl Clone for MarkerSpec
impl Clone for MarkerSpec
Source§fn clone(&self) -> MarkerSpec
fn clone(&self) -> MarkerSpec
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MarkerSpec
impl Debug for MarkerSpec
Source§impl Default for MarkerSpec
impl Default for MarkerSpec
Source§impl<'de> Deserialize<'de> for MarkerSpec
impl<'de> Deserialize<'de> for MarkerSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for MarkerSpec
impl RefUnwindSafe for MarkerSpec
impl Send for MarkerSpec
impl Sync for MarkerSpec
impl Unpin for MarkerSpec
impl UnsafeUnpin for MarkerSpec
impl UnwindSafe for MarkerSpec
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
ReadEndian::read_from_little_endian().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>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
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
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.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>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
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
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.