pub struct H3Chain<'a> {Show 14 fields
pub model: &'a Arc<CmfModel>,
pub blocks: &'a [H3ChainBlock<'a>],
pub n: usize,
pub hidden: usize,
pub heads: usize,
pub head_dim: usize,
pub ffn: usize,
pub eps: f32,
pub qk_eps: f32,
pub angles: &'a [f32],
pub rows: &'a [u32],
pub groups: usize,
pub qkv_interleaved: bool,
pub vsa: Option<&'a VsaPlan>,
}Expand description
A stack of MiniMax-H3 blocks over one packed sequence.
Fields§
§model: &'a Arc<CmfModel>§blocks: &'a [H3ChainBlock<'a>]§n: usize§heads: usize§head_dim: usize§ffn: usize§eps: f32§qk_eps: f32§angles: &'a [f32][n][pairs] rotation angles; empty: no rotation.
rows: &'a [u32][n] modulation row of every token (unread without modulation).
groups: usizeIndependent sequences in the batch, n rows each (h is
[groups · n][hidden]): attention stays inside a group, and the
angles are one group’s, shared by all.
qkv_interleaved: boolThe qkv panel’s row layout: [q | k | v] planes (false) or
per-head [q k v] triples (true).
vsa: Option<&'a VsaPlan>Video sparse attention over the tiles of this plan instead of the full attention (a VSA-trained student; one group only). A backend without it refuses the chain.
Auto Trait Implementations§
impl<'a> Forget for H3Chain<'a>
impl<'a> Freeze for H3Chain<'a>
impl<'a> Move for H3Chain<'a>
impl<'a> RefUnwindSafe for H3Chain<'a>
impl<'a> Send for H3Chain<'a>
impl<'a> Sync for H3Chain<'a>
impl<'a> Unpin for H3Chain<'a>
impl<'a> UnsafeUnpin for H3Chain<'a>
impl<'a> UnwindSafe for H3Chain<'a>
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