pub struct LogitTrustRegion {
pub radius: f64,
}Expand description
Per-iteration trust-region cap on the assignment logits.
The wiring agent calls LogitTrustRegion::cap_step on each candidate
Newton step in assignment-logit space before it is applied, so a single
step can never fling the relaxed assignment across the argmax cliff (the
discontinuity the τ anneal exists to avoid). The cap is an ∞-norm radius on
the logit increment, tied to the current τ: hotter τ (diffuse) tolerates a
larger logit move; colder τ (sharp) clamps tighter, because near the cliff a
small logit change is a large assignment change.
Fields§
§radius: f64∞-norm radius on the logit increment at the current waypoint.
Implementations§
Source§impl LogitTrustRegion
impl LogitTrustRegion
Sourcepub fn for_tau(tau: f64) -> Self
pub fn for_tau(tau: f64) -> Self
Build the per-waypoint logit trust region from the current τ. Hotter τ
⇒ larger radius (the assignment map is gentle); colder τ ⇒ tighter
radius (near the argmax cliff). The radius is τ · LOGIT_TR_TAU_GAIN
clamped to [LOGIT_TR_MIN, LOGIT_TR_MAX].
Sourcepub fn cap_step(&self, step_inf_norm: f64) -> LogitStepCap
pub fn cap_step(&self, step_inf_norm: f64) -> LogitStepCap
Decide how to cap a proposed logit increment given its ∞-norm. The wiring agent passes the step’s ∞-norm; this returns whether to apply it unchanged or scaled to the radius. Never rejects.
Trait Implementations§
Source§impl Clone for LogitTrustRegion
impl Clone for LogitTrustRegion
Source§fn clone(&self) -> LogitTrustRegion
fn clone(&self) -> LogitTrustRegion
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for LogitTrustRegion
Auto Trait Implementations§
impl Freeze for LogitTrustRegion
impl RefUnwindSafe for LogitTrustRegion
impl Send for LogitTrustRegion
impl Sync for LogitTrustRegion
impl Unpin for LogitTrustRegion
impl UnsafeUnpin for LogitTrustRegion
impl UnwindSafe for LogitTrustRegion
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
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>
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>
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>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
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
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.