Skip to main content

Module construction

Module construction 

Source

Structs§

CanonicalPenalty
A canonicalized penalty with block-local root, ready for the solver.
EngineDims
Minimal engine layout descriptor that avoids domain-specific layout coupling.
KroneckerReparamResult
Result of Kronecker-factored reparameterization.
PenaltyMatrix
ReparamInvariant
Lambda-independent reparameterization invariants derived from penalty structure.
ReparamResult
Result of the stable reparameterization algorithm from Wood (2011) Appendix B

Enums§

PenaltyRepresentation

Functions§

calculate_condition_number
Calculate the 2-norm condition number of a matrix.
canonicalize_penalty_spec
Canonicalize a single PenaltySpec into a CanonicalPenalty by computing the block-local eigendecomposition and extracting the root.
canonicalize_penalty_specs
Canonicalize a batch of penalty specs, dropping zero-rank penalties. Returns (active_penalties, active_nullspace_dims).
create_balanced_penalty_root_from_canonical
Creates a balanced penalty root from canonical penalties.
kronecker_logdet_and_derivatives
Compute log|S|₊ and its first/second derivatives w.r.t. ρ_k = log(λ_k) from factored marginal eigenvalues.
kronecker_product
Computes the Kronecker product A ⊗ B for penalty matrix construction. This is used to create tensor product penalties that enforce smoothness in multiple dimensions for interaction terms.
kronecker_reparameterization_engine
Kronecker-factored reparameterization for tensor-product penalties.
precompute_reparam_invariant_from_canonical
Precompute the lambda-invariant reparameterization structure from canonical penalties.
report_penalty_pair_redundancy
Detect and report structurally identical (or near-identical) penalty pairs in the canonical bundle.
stable_reparameterization_engine_canonical
Engine-facing stable reparameterization API using only (p, k).
stable_reparameterizationwith_invariant
Apply stable reparameterization using precomputed lambda-invariant structures.