pub struct MaskDecoderWeights {Show 13 fields
pub iou_token: Vec<f32>,
pub mask_tokens: Vec<f32>,
pub transformer: TwoWayTransformerWeights,
pub upscale_conv1_w: Vec<f32>,
pub upscale_conv1_b: Vec<f32>,
pub upscale_ln_g: Vec<f32>,
pub upscale_ln_b: Vec<f32>,
pub upscale_conv2_w: Vec<f32>,
pub upscale_conv2_b: Vec<f32>,
pub hyper_mlps: Vec<HypernetMlp>,
pub iou_head: HypernetMlp,
pub transformer_dim: usize,
pub num_mask_tokens: usize,
}Fields§
§iou_token: Vec<f32>§mask_tokens: Vec<f32>§transformer: TwoWayTransformerWeights§upscale_conv1_w: Vec<f32>ConvTranspose2d: in=transformer_dim, out=transformer_dim/4,
kernel=2, stride=2. Weight shape [in, out, 2, 2].
upscale_conv1_b: Vec<f32>§upscale_ln_g: Vec<f32>LayerNorm2d on the upscaled feature.
upscale_ln_b: Vec<f32>§upscale_conv2_w: Vec<f32>ConvTranspose2d: in=transformer_dim/4, out=transformer_dim/8.
upscale_conv2_b: Vec<f32>§hyper_mlps: Vec<HypernetMlp>num_mask_tokens × 3-layer ReLU MLPs (transformer_dim → transformer_dim → transformer_dim → transformer_dim/8). Each MLP’s flat
weights+biases stored sequentially in hyper_mlps_*.
iou_head: HypernetMlpIoU prediction head: 3-layer ReLU MLP transformer_dim → iou_head_hidden_dim → iou_head_hidden_dim → num_mask_tokens.
transformer_dim: usize§num_mask_tokens: usizeAuto Trait Implementations§
impl Freeze for MaskDecoderWeights
impl RefUnwindSafe for MaskDecoderWeights
impl Send for MaskDecoderWeights
impl Sync for MaskDecoderWeights
impl Unpin for MaskDecoderWeights
impl UnsafeUnpin for MaskDecoderWeights
impl UnwindSafe for MaskDecoderWeights
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> 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