Component Base Class

class tabascal.components.Component[source]

Base class for all tabascal components

build_constants() Dict[str, Any][source]

Return arrays that do not change during the forward pass.

Returns a dict of array_name -> array_value. These will be stored in constants as “_c/<ClassName>/array_name” by Model.__init__.

abstractmethod build_forward() Callable[source]

Build the forward computation function

build_set_params() Callable[source]

Build parameter sampling function (optional)

require_double(config: Any) None[source]

Raise if this requires_double component is run in single precision.

Some components only work in double precision: the SGP4/phase trajectory components (differentiable orbits). Those set requires_double = True and call this at the top of setup so they fail with a clear message under single precision instead of producing silently-wrong fp32 results. Driven by the requires_double flag so it stays in sync with the run-time preflight.

abstractmethod setup(tab_config: Any) None[source]

Initialize component with configuration

validate_state(state: Dict[str, Any]) None[source]

Validate required inputs are present