pyradtran.interface.PyRadtranAccessor.run

pyradtran.interface.PyRadtranAccessor.run#

PyRadtranAccessor.run(config_path: str | Path | None = None, config: SimulationConfig | None = None, parameter_overrides: Dict[str, Any] = None, time_var: str = 'time', lat_var: str = 'latitude', lon_var: str = 'longitude', albedo_var: str | None = None, surface_temperature_var: str | None = None, surface_type_var: str | None = None, era5_atmosphere: Dataset | None = None, return_dataset: bool = True, save_to_file: bool = True, output_path: str | Path | None = None, progress_callback: callable | None = None, cloud_wc_var: str | None = None, cloud_ic_var: str | None = None, cloud_reff_var: str | None = None, cloud_ic_reff_var: str | None = None, cloud_top_var: str | None = None, cloud_bottom_var: str | None = None, show_progress: bool = True) Dataset | Path[source]#

Run uvspec for every point in the dataset.

Parameters:
  • config_path (str or pathlib.Path, optional) – YAML configuration file.

  • config (SimulationConfig, optional) – Pre-built config (overrides config_path).

  • parameter_overrides (dict, optional) – Extra key: value pairs for uvspec.

  • time_var (str) – Coordinate variable names.

  • lat_var (str) – Coordinate variable names.

  • lon_var (str) – Coordinate variable names.

  • albedo_var (str, optional) – Per-point albedo variable.

  • surface_temperature_var (str, optional) – Per-point surface-temperature variable.

  • surface_type_var (str, optional) – Per-point IGBP surface-type variable.

  • era5_atmosphere (xarray.Dataset, optional) – ERA5 dataset for custom atmosphere profiles.

  • return_dataset (bool, default True) – Return results as an xarray Dataset.

  • save_to_file (bool, default True) – Write results to NetCDF.

  • output_path (str or pathlib.Path, optional) – Destination file (auto-generated when None).

  • progress_callback (callable, optional) – callback(current, total).

  • show_progress (bool, default True) – Show a tqdm progress bar. Pass False to suppress it (useful when the output will be rendered as HTML).

  • cloud_wc_var (str, optional) – LWC / IWC dataset variables.

  • cloud_ic_var (str, optional) – LWC / IWC dataset variables.

  • cloud_reff_var (str, optional) – Effective-radius variables.

  • cloud_ic_reff_var (str, optional) – Effective-radius variables.

  • cloud_top_var (str, optional) – Cloud geometry variables (km).

  • cloud_bottom_var (str, optional) – Cloud geometry variables (km).

Returns:

Results dataset when return_dataset is True, otherwise the output file path.

Return type:

xarray.Dataset or pathlib.Path

Raises:

PyRadtranError – If no valid results are produced.