Glm5NextDsaWeights

Struct Glm5NextDsaWeights 

Source
pub struct Glm5NextDsaWeights {
Show 13 fields pub q_a_proj: DevicePtr, pub q_a_layernorm: DevicePtr, pub q_absorb: DevicePtr, pub kv_a_proj: DevicePtr, pub kv_a_layernorm: DevicePtr, pub o_absorb: DevicePtr, pub wk: DevicePtr, pub k_norm_weight: DevicePtr, pub k_norm_bias: DevicePtr, pub compress_gate: DevicePtr, pub wq_b: DevicePtr, pub weights_proj: DevicePtr, pub ape: DevicePtr,
}
Expand description

One DSA block’s weights, already sharded for this rank.

Fields§

§q_a_proj: DevicePtr§q_a_layernorm: DevicePtr§q_absorb: DevicePtr

[local_heads * kv_lora_rank, q_lora_rank] BF16 — q_b_proj absorbed through kv_b_proj’s K half, so Q arrives in latent space. See the module header.

§kv_a_proj: DevicePtr§kv_a_layernorm: DevicePtr§o_absorb: DevicePtr

[hidden, local_heads * kv_lora_rank] BF16, row-parallel — all-reduced by the caller.

🪤 Absorbed, not the raw checkpoint o_proj: the decode kernel leaves its output in the 512-dim LATENT space, so the projection carries kv_b_proj’s V half folded in. The raw weight is local_heads * v_head_dim wide — half of this — and feeding the latent to it reads 2x past every row rather than merely computing the wrong thing.

§wk: DevicePtr§k_norm_weight: DevicePtr§k_norm_bias: DevicePtr

🪤 REQUIRED. k_norm is a LayerNorm; a .weight-only bind silently drops the mean subtraction and the bias.

§compress_gate: DevicePtr§wq_b: DevicePtr§weights_proj: DevicePtr

🪤 Pre-multiplied by index_heads^-0.5 at load — dsa_index_scores does not scale.

§ape: DevicePtr

[index_kpool, index_head_dim] FP32. 🪤 BF16 on disk; upconverted at load.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more