pub enum AssignmentMode {
Softmax {
temperature: f64,
sparsity: f64,
},
IBPMap {
temperature: f64,
alpha: f64,
learnable_alpha: bool,
},
JumpReLU {
temperature: f64,
threshold: f64,
},
}Expand description
Assignment prior/relaxation used by SaeAssignment.
Variants§
Softmax
Row-wise simplex assignment with entropy sparsity.
IBPMap
Deterministic concrete relaxation of a truncated IBP active set.
JumpReLU
Hard-thresholded bounded gate: each atom is off (gate = 0) when its logit
is at or below threshold, and on with a threshold-centered shifted
sigmoid σ((logit − threshold) / temperature) ∈ [0.5, 1) above it. This
is NOT literal JumpReLU z·1[z>θ] — the gate carries no magnitude; it is
a member of the gate family (softmax simplex / IBP sigmoid / this hard
gate) and stays bounded in [0, 1]. Reconstruction magnitude lives entirely
in the decoder curve g_k(t) = φ(t)ᵀ B_k. The discontinuity at threshold
(0 → 0.5) is the intended “jump”.
Implementations§
Trait Implementations§
Source§impl Clone for AssignmentMode
impl Clone for AssignmentMode
Source§fn clone(&self) -> AssignmentMode
fn clone(&self) -> AssignmentMode
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for AssignmentMode
Auto Trait Implementations§
impl Freeze for AssignmentMode
impl RefUnwindSafe for AssignmentMode
impl Send for AssignmentMode
impl Sync for AssignmentMode
impl Unpin for AssignmentMode
impl UnsafeUnpin for AssignmentMode
impl UnwindSafe for AssignmentMode
Blanket Implementations§
impl<T> Allocation for T
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> DistributionExt for Twhere
T: ?Sized,
impl<T> DistributionExt for Twhere
T: ?Sized,
impl<T, U> Imply<T> for U
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.