pub struct OuterCriterionCertificate {
pub stationarity: OuterStationarityCertificate,
pub curvature: CurvatureEvidence,
pub lambdas_railed: Vec<usize>,
pub railed_facts: Vec<RailedCoordinateFact>,
pub curvature_floor: Option<CurvatureFloorClearance>,
}Fields§
§stationarity: OuterStationarityCertificate§curvature: CurvatureEvidenceWhat curvature evidence this certificate has, and why it has no more
than that (#2561). Serializes as the legacy hessian_psd optional
bool; read the raw verdict through Self::hessian_psd.
lambdas_railed: Vec<usize>Leading smoothing coordinates (ρ block) pinned within
CERTIFICATE_RAIL_MARGIN of either box bound at the optimum.
railed_facts: Vec<RailedCoordinateFact>The interval and margin each railed coordinate was judged against
(#2530). Empty when nothing is railed. #[serde(default)] so a
certificate stored before this field existed still deserializes — those
carry no facts, which is honest: none were recorded.
curvature_floor: Option<CurvatureFloorClearance>The gradient-residue floor’s verdict on that same curvature, when it was
computed. hessian_psd above stays the raw measurement; this records
whether the most negative interior direction is below the instrument’s
own resolution, and by how much.
Implementations§
Source§impl OuterCriterionCertificate
impl OuterCriterionCertificate
Sourcepub fn is_stationary(&self) -> bool
pub fn is_stationary(&self) -> bool
First-order (KKT) stationarity: the projected analytic gradient or root-equivalent fixed-point residual clears its declared bound.
Sourcepub fn hessian_psd(&self) -> Option<bool>
pub fn hessian_psd(&self) -> Option<bool>
The raw PSD verdict, None when no curvature question was answered
— the legacy hessian_psd projection every existing consumer wants.
Ask Self::curvature directly to learn WHY there is no verdict.
Sourcepub fn curvature_verdict(&self) -> CurvatureAdmissibility
pub fn curvature_verdict(&self) -> CurvatureAdmissibility
Second-order admissibility: a certified optimum must not sit on genuinely indefinite analytic curvature. A nearby box rail is only a diagnostic; it cannot waive negative curvature in unrelated free directions. If a future certificate projects onto the exact critical cone, that projected result can be recorded here instead.
Three-valued, because the question has three answers (#2578). The
predicate this replaced returned bool, and its true was produced by
two structurally different facts: a Hessian that was measured and found
admissible, and a route that never measured one. A gate whose passing
condition is satisfied by the ABSENCE of an observation cannot fail on
the case it exists to catch — on the support-sparse grouped-LAML lane,
which reports hessian=Unavailable, every consultation answered true
without inspecting anything.
Acceptance is unchanged. CurvatureAdmissibility::Unevaluated does
not refuse, exactly as != Some(false) did not. The difference is that
a caller wanting a genuine second-order guarantee can now ask for
CurvatureAdmissibility::Admissible and get one, instead of being
handed a true that means “nobody looked”.
Sourcepub fn curvature_not_refused(&self) -> bool
pub fn curvature_not_refused(&self) -> bool
Whether the second-order conjunct REFUSES this certificate — the shape
Self::refusal needs. This is deliberately not named
curvature_admissible: “did not refuse” and “was found admissible” are
different claims, and conflating them is what #2578 was.
Sourcepub fn certifies(&self) -> bool
pub fn certifies(&self) -> bool
Whether the certificate accepts the returned point as a constrained
minimum. This is the load-bearing verdict: a false here rejects the
fit with typed non-convergence.
Defined as “no conjunct refused” so that this and Self::refusal
cannot disagree. Two renderings of one predicate is exactly what #2550
was: the verdict string named a cause the predicate had not tested.
Sourcepub fn refusal(&self) -> Option<CertificationRefusal>
pub fn refusal(&self) -> Option<CertificationRefusal>
WHICH conjunct refused, or None when the certificate accepts.
certifies() is a conjunction of six independent things and its verdict
string used to be a three-way branch, so the middle branch had to GUESS
among four surviving culprits — and guessed curvature every time. It
printed INDEFINITE CURVATURE AT INTERIOR OPTIMUM four words after
printing hessian_psd=yes, on a fit whose actual refusal was a rail
with a zero pencil constant (#2550, observed at #2348’s increment 2).
A misdirecting refusal is worse than a vague one: it spends the reader’s
attention on the one component the same line proves is not at fault.
The order is the conjunction’s own. It is reported first-failure-wins because that is what a conjunction means; a certificate failing several conjuncts is not better described by listing them than by naming the first thing that was wrong with it.
Trait Implementations§
Source§impl Certificate for OuterCriterionCertificate
impl Certificate for OuterCriterionCertificate
Source§fn evidence(&self) -> BTreeMap<&'static str, EvidenceValue>
fn evidence(&self) -> BTreeMap<&'static str, EvidenceValue>
Source§fn verdict(&self) -> Verdict
fn verdict(&self) -> Verdict
Verdict::Unavailable /
Verdict::Insufficient rather than a silent pass when the evidence is
missing or below margin.Source§fn ledger_entry(&self) -> LedgerEntry
fn ledger_entry(&self) -> LedgerEntry
Source§impl Clone for OuterCriterionCertificate
impl Clone for OuterCriterionCertificate
Source§fn clone(&self) -> OuterCriterionCertificate
fn clone(&self) -> OuterCriterionCertificate
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for OuterCriterionCertificate
impl Debug for OuterCriterionCertificate
Source§impl<'de> Deserialize<'de> for OuterCriterionCertificate
impl<'de> Deserialize<'de> for OuterCriterionCertificate
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<OuterCriterionCertificate, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<OuterCriterionCertificate, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl Serialize for OuterCriterionCertificate
impl Serialize for OuterCriterionCertificate
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for OuterCriterionCertificate
impl RefUnwindSafe for OuterCriterionCertificate
impl Send for OuterCriterionCertificate
impl Sync for OuterCriterionCertificate
impl Unpin for OuterCriterionCertificate
impl UnsafeUnpin for OuterCriterionCertificate
impl UnwindSafe for OuterCriterionCertificate
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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.