pub enum MaskOp {
Threshold {
method: MaskThresholdMethod,
value: Option<f64>,
},
Bet {
fractional_intensity: f64,
},
Erode {
iterations: usize,
},
Dilate {
iterations: usize,
},
Close {
radius: usize,
},
FillHoles {
max_size: usize,
},
GaussianSmooth {
sigma_mm: f64,
},
SignalErode(SignalErosionParams),
HdBet(HdBetParams),
}Expand description
A single mask operation (generator or refinement)
Variants§
Threshold
Bet
Erode
Dilate
Close
FillHoles
GaussianSmooth
SignalErode(SignalErosionParams)
Signal-gated erosion: peel only low-signal boundary voxels (skull-base / sinus dropout)
down to a depth cap. See [crate::utils::signal_gated_erosion].
Gates on the magnitude image, never on the section’s input: it divides out a receive-coil bias estimate and compares against the in-mask median, which only means anything for magnitude. Errors if no magnitude is supplied, so a phase-quality mask input can still be refined with it as long as the magnitude is available.
HdBet(HdBetParams)
HD-BET deep-learning brain extraction from the magnitude (a generator, like Bet),
whatever the section’s input is. Requires the onnx feature and the hd-bet model
weights; see crate::models.
Implementations§
Trait Implementations§
impl StructuralPartialEq for MaskOp
Auto Trait Implementations§
impl Freeze for MaskOp
impl RefUnwindSafe for MaskOp
impl Send for MaskOp
impl Sync for MaskOp
impl Unpin for MaskOp
impl UnsafeUnpin for MaskOp
impl UnwindSafe for MaskOp
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<T> CloneAny for T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Converts
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Converts
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Converts
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Converts
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSend for T
impl<T> DowncastSend for T
§impl<T> DowncastSync for T
impl<T> DowncastSync for T
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>
Converts
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>
Converts
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 more