pub struct RotationSpec {
pub kind: RotationKind,
pub rope_dim: usize,
pub range: f64,
}Expand description
Everything the rotation needs from the block: which algebra, how much of
state_rank it turns, and how far one step may turn it.
Carried by Mamba3 and handed to
rotate_bc_forward / rotate_bc_step (and to the constant-input
shortcut) so that every site derives the per-step rotation from one
definition — the three used to spell the formula out separately, which is
exactly the kind of duplication that lets forward, step and
step_infinite drift apart.
Fields§
§kind: RotationKindWhich rotational-state algebra (RotationKind).
rope_dim: usizeHow many leading state_rank entries are rotated (see
Mamba3Config::rope_fraction).
For RotationKind::Quaternion4D this is a multiple of 4; for
RotationKind::Real1D it is 0 and nothing reads it.
range: f64The per-step rotation bound in half-turns per unit Δ
(Mamba3Config::rotation_range):
one step turns by at most range · π · Δ.
Trait Implementations§
Source§impl Clone for RotationSpec
impl Clone for RotationSpec
Source§fn clone(&self) -> RotationSpec
fn clone(&self) -> RotationSpec
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more