Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

cesm_hawc.orbit_files

cesm_hawc.orbit_files

source

Read observation geometry from HAWC orbit files.

Also converts the simulator’s L1b output to an xarray.Dataset. The expected orbit file contents are described in the documentation’s “Orbit files” page.

load_orbit_files

def load_orbit_files(orbit_dir: str, pattern: str = 'orbit_*.nc') -> list[str]

source

List the orbit files in a directory.

Parameters

Returns

Raises

orbit_file_start_time

def orbit_file_start_time(path: str) -> pd.Timestamp

source

Read an orbit file’s start time.

Parameters

Returns

Raises

build_orbit_day_index

def build_orbit_day_index(
    orbit_files: list[str],
    epoch: pd.Timestamp,
    cache_path: str | os.PathLike | None = None,
) -> dict[int, list[str]]

source

Group orbit files by day since the orbit epoch.

Parameters

Returns

extract_observations

def extract_observations(
    orbit_files: list[str],
    sim_date: pd.Timestamp,
    cadence_s: float,
    center_pixel: int,
    epoch: pd.Timestamp,
) -> list[dict]

source

Sample observations from one day’s orbit files onto a model date.

Parameters

Returns

Notes

Each observation keeps its real time of day and satellite geometry; only its date changes. The starting offset of the sampling is rotated from file to file. Each file is about one orbit of a sun-synchronous satellite, so with the same offset every file would sample nearly the same latitudes.

l1b_image_to_dataset

def l1b_image_to_dataset(
    l1b,
    wavelengths_nm,
    true_extinction: dict | None = None,
    alt_grid_m=None,
) -> xr.Dataset

source

Convert simulator L1b output to an xarray.Dataset.

Parameters

Returns