pub enum AnySolution {
Eml(Solution),
Affine(AffineSolution),
}Expand description
A discovered law from either engine, exposing a common accuracy/complexity interface.
Variants§
Eml(Solution)
A law from the EML-tree core (enumerate / Gumbel / gated / oxieml-symreg). Carries the
full downstream capability surface (analyze / certified-root / proofs / codegen) via the
inner Solution.
Affine(AffineSolution)
A law from the rich-leaf affine engine (Linear / LogLinear leaves over guarded eml).
Implementations§
Source§impl AnySolution
impl AnySolution
Sourcepub fn complexity(&self) -> usize
pub fn complexity(&self) -> usize
Structural complexity (lower is simpler): EML node count for Self::Eml, active-parameter
count for Self::Affine. Both measure “number of structural pieces” — commensurable enough
to share one Pareto axis.
Sourcepub fn source(&self) -> &'static str
pub fn source(&self) -> &'static str
A short identifier of the producing engine ("eml" / "affine"), for display.
Sourcepub fn is_symbolic(&self) -> bool
pub fn is_symbolic(&self) -> bool
Whether this is a clean symbolic recovery. An EML law is exact in its own algebra, so it
reports true; an affine law reports true only when its exponents/slopes snapped to small
rationals / named constants while retaining R² ≥ 0.999 (see AffineSolution::symbolic).
Sourcepub fn predict(&self, x: &Array2<f64>) -> Result<Array1<f64>>
pub fn predict(&self, x: &Array2<f64>) -> Result<Array1<f64>>
Evaluate the law on new data x ([n_rows, n_vars]).
§Errors
Returns crate::PhopError if the EML forward fails (the affine forward is total).
Trait Implementations§
Source§impl Clone for AnySolution
impl Clone for AnySolution
Source§fn clone(&self) -> AnySolution
fn clone(&self) -> AnySolution
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for AnySolution
impl RefUnwindSafe for AnySolution
impl Send for AnySolution
impl Sync for AnySolution
impl Unpin for AnySolution
impl UnsafeUnpin for AnySolution
impl UnwindSafe for AnySolution
Blanket Implementations§
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> 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.