am.model

Classes

Model

An am atmospheric model loaded from an .amc configuration file.

Module Contents

class am.model.Model(path, args)

An am atmospheric model loaded from an .amc configuration file.

Thin wrapper around the Rust _Model that returns xarray Datasets for outputs and jacobian().

Parameters

path:

Path to the .amc file.

args:

Positional substitution values for %1, %2, … placeholders in the config (frequency grid, zenith angle, PWV scale, etc.).

compute()

Run the radiative transfer computation.

property frequency: numpy.ndarray

Frequency grid in GHz.

property outputs: xarray.Dataset

Computed output spectra as an xarray Dataset.

Dimension is frequency (GHz). Only outputs listed in the output directive of the .amc file are present. Empty before compute() is called.

property variables: list[str]

Names of fit/differentiation variables defined in the config.

property n_variables: int

Number of fit/differentiation variables.

jacobian() xarray.Dataset

Compute Jacobians of all outputs w.r.t. fit variables.

Returns an xarray Dataset with dimensions (variable, frequency). The .amc config must define fit variables (parameters with scales).

Raises

ConfigError

If no fit variables are defined in the .amc config.

summary() str

Full resolved model configuration summary.