jesterTOV.inference.flows.train_flow.load_posterior

Contents

jesterTOV.inference.flows.train_flow.load_posterior#

load_posterior(filepath, parameter_names, max_samples=20000)[source]#

Load posterior samples from npz file with flexible parameter selection.

Parameters:
  • filepath (str) – Path to .npz file

  • parameter_names (list[str]) – List of parameter names to extract from file

  • max_samples (int) – Maximum number of samples to use (downsampling if needed)

Return type:

Tuple[ndarray, Dict[str, Any]]

Returns:

data – Array of shape (n_samples, n_params) with selected parameters metadata: Dictionary with loading information

Raises: