Skip to main content

Module coefficient_group_resolver

Module coefficient_group_resolver 

Source
Expand description

Carrier-agnostic coefficient-group resolver.

User-declared coefficient groups are realized into penalty components and rho-prior entries in two places: standard term collections (carrier = columns of the realized design matrix, crate::smooth) and custom families (carrier = (block, column) coordinates of parameter blocks, crate::families::custom_family). The carrier differs but the policy is identical: validate labels, build the parent/child hierarchy, reject cycles, require each child to be a subset of its parent, require an interior node’s coefficients to be exactly the union of its children, and expand interior nodes into the concatenation of their recursively resolved child components.

This module hosts that shared policy once, generic over the coordinate type C (the carrier). Each caller resolves its own selectors into C sets and lays out its own penalty matrices and rho coordinates from the resolved components — only the carrier-specific layout stays on the caller side.

Structs§

ResolvedGroup
A coefficient group after its selectors have been resolved by the carrier into a concrete set of carrier coordinates C.
ResolvedGroupHierarchy
Validated coefficient-group hierarchy over carrier coordinates C.