pub struct SqueezeExciteBlock {
pub fc_reduce_w: Tensor,
pub fc_reduce_b: Tensor,
pub fc_expand_w: Tensor,
pub fc_expand_b: Tensor,
pub channels: usize,
pub reduced: usize,
}Expand description
Squeeze-and-Excitation block (inference-mode).
Channel attention: GlobalAvgPool -> FC(reduce) -> ReLU -> FC(expand) -> Sigmoid -> scale.
reduction_ratio controls bottleneck (typically 4 or 16).
Fields§
§fc_reduce_w: Tensor§fc_reduce_b: Tensor§fc_expand_w: Tensor§fc_expand_b: Tensor§channels: usize§reduced: usizeImplementations§
Auto Trait Implementations§
impl Freeze for SqueezeExciteBlock
impl RefUnwindSafe for SqueezeExciteBlock
impl Send for SqueezeExciteBlock
impl Sync for SqueezeExciteBlock
impl Unpin for SqueezeExciteBlock
impl UnsafeUnpin for SqueezeExciteBlock
impl UnwindSafe for SqueezeExciteBlock
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
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