Skip to main content

BuildInspection

Struct BuildInspection 

Source
pub struct BuildInspection {
    pub setup_arrays: HashMap<String, ArrayD<f64>>,
    pub observed_exprs: HashMap<String, Expr>,
    pub params: HashMap<String, f64>,
    pub recurrences: Vec<RecurrenceInfo>,
}
Expand description

Build/run observability record — the Rust mirror of the Julia binding’s BuildInspection (build_evaluator(…; inspect=BuildInspection())). Pass one to a EsmProblem built with crate::problem::ProblemOptions::inspect (or ArrayCompiled::solve_inspect) and the run fills it with named build-time products that are otherwise internal to the runtime:

  • setup_arrays — the STATE-FREE observed arrays, materialized once at the initial state through the official observed machinery (the observed-materialization pass): the per-pair regrid geometry (A_ij, its row-sums A_j, the normalized weights W_ij — RFC §8.1 / esm-spec §8.6.1), const-op mesh factors and their bare-name aliases, and every other build-once array observed whose transitive references reach no state, no t, and no external forcing channel. This is the official inspection surface for conformance runners that gate per-pair regridding values (CONFORMANCE_SPEC §5.8) and for §6.6.5 assertions that target a state-free array observed directly (the MPAS div_flux max/min). A state- or time-dependent observed is deliberately ABSENT (its build-time snapshot would be wrong at any later time), so a reader errors rather than consuming a stale field.
  • observed_exprs — every observed rule’s resolved body expression (post subsystem mounting, range resolution, and keyed-factor scoping), exactly as the runtime evaluates it.

Filling the record never changes the run: the returned crate::simulate::Solution is identical with or without a sink (the capture is one extra read-only observed-materialization pass at t0).

Fields§

§setup_arrays: HashMap<String, ArrayD<f64>>

State-free observed arrays materialized at the initial state, keyed by (possibly flattening-namespaced) observed name.

§observed_exprs: HashMap<String, Expr>

Resolved observed body expressions, keyed like setup_arrays.

§params: HashMap<String, f64>

Resolved SCALAR parameter values (model defaults with any overrides applied), keyed by (flattened) parameter name. Load-time constants, so a build-time cellwise evaluation (a §6.6.5 analytic reference, coordinate-expression ic seeding) may bind them into scope — STATE stays out. The observed-assertion form already binds them (a state-free observed is materialized into setup_arrays with these values); params exposes the same map for the reference / ic positions.

§recurrences: Vec<RecurrenceInfo>

One entry per recognized CAUSAL SELF-REFERENCE (esm-spec §4.3.1.1), so the interpretation a document’s self-read was given is auditable without being authored twice. This is what stands in for a declared recur annotation (RFC §2.1): the recurrence, its axis and its derived maximum lag are reported, not required.

Trait Implementations§

Source§

impl Clone for BuildInspection

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for BuildInspection

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for BuildInspection

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

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> ByRef<T> for T

Source§

fn by_ref(&self) -> &T

Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> Context for T
where T: Clone + Default,

Source§

fn vector_from_element<V>(&self, len: usize, value: <V as VectorCommon>::T) -> V
where V: Vector<C = Self>,

Source§

fn vector_from_vec<V>(&self, vec: Vec<<V as VectorCommon>::T>) -> V
where V: Vector<C = Self>,

Source§

fn vector_zeros<V>(&self, len: usize) -> V
where V: Vector<C = Self>,

Source§

fn dense_mat_zeros<V>( &self, rows: usize, cols: usize, ) -> <V as DefaultDenseMatrix>::M
where V: Vector<C = Self> + DefaultDenseMatrix,

Source§

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

Source§

fn rand<T>(&self, rng: &mut (impl Rng + ?Sized)) -> T
where Self: Distribution<T>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Imply<T> for U
where T: ?Sized, U: ?Sized,

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> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
where F: FnOnce(&Self) -> bool,

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 more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<SS, SP> SupersetOf<SS> for SP
where SS: SubsetOf<SP>,

Source§

fn to_subset(&self) -> Option<SS>

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more
Source§

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

Use with care! Same as self.to_subset but without any property checks. Always succeeds.
Source§

fn from_subset(element: &SS) -> SP

The inclusion map: converts self to the equivalent element of its superset.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

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

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

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.
Source§

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

Source§

fn vzip(self) -> V