Skip to content

Sensors

Sensor and platform configurations representing satellite and ground-based observing systems together with their associated instrument types.

s2gos_simulator.config.sensors.BaseSensor pydantic-model

Bases: BaseModel

Base sensor configuration.

Fields:

Validators:

  • resolve_srf_presetsrf

Attributes

id pydantic-field

id: Optional[str] = None

Unique sensor identifier (auto-generated if not provided)

noise_model pydantic-field

noise_model: Optional[Dict[str, Any]] = None

Noise model configuration

platform_type pydantic-field

platform_type: PlatformType

Platform type identifier

produces pydantic-field

produces: List[
    Literal["radiance", "irradiance", "hdrf", "brf", "bhr"]
] = ["radiance"]

List of radiative quantities to be produced by this sensor configuration

samples_per_pixel pydantic-field

samples_per_pixel: int = 64

Number of Monte Carlo samples per pixel

srf pydantic-field

srf: Optional[SRFType] = None

Spectral response function

viewing pydantic-field

viewing: ViewingType

Viewing geometry configuration

s2gos_simulator.config.sensors.SatelliteSensor pydantic-model

Bases: BaseSensor

Satellite sensor configuration.

Fields:

Validators:

Attributes

band pydantic-field

band: str

Band identifier (validated against instrument-specific enum)

film_resolution pydantic-field

film_resolution: Tuple[int, int]

Pixel grid dimensions (width, height) for 2D imaging

for_reference_only pydantic-field

for_reference_only: bool = False

If True, this sensor is used for geometry specification only (e.g., for PixelHDRF/PixelBRF coordinate mapping) and will NOT be simulated. Use this when you already have satellite data and only need the sensor's geometry (lat/lon, resolution, viewing angles) for pixel index mapping. The sensor remains accessible for coordinate queries but is excluded from Eradiate measure translation.

instrument pydantic-field

instrument: SatelliteInstrument

Satellite instrument identifier

pixel_size_m property

pixel_size_m: Tuple[float, float]

Calculate ground pixel size in meters.

Returns:

Type Description
Tuple[float, float]

Tuple of (pixel_size_x_m, pixel_size_y_m) in meters per pixel

platform pydantic-field

platform: SatellitePlatform

Satellite platform identifier

platform_type pydantic-field

platform_type: Literal[SATELLITE] = SATELLITE

Platform type (always 'satellite')

target_center_lat pydantic-field

target_center_lat: float

Target center latitude in WGS84 decimal degrees

target_center_lon pydantic-field

target_center_lon: float

Target center longitude in WGS84 decimal degrees

target_size_km pydantic-field

target_size_km: Union[float, Tuple[float, float]]

Target area size: float for square (km), tuple for rectangular (width_km, height_km)

viewing pydantic-field

viewing: AngularViewing

Viewing geometry (zenith/azimuth angles)

Functions

validate_and_set_defaults pydantic-validator

validate_and_set_defaults()

Validate platform/instrument/band combination and set defaults.

s2gos_simulator.config.sensors.GroundSensor pydantic-model

Bases: BaseSensor

Ground sensor configuration.

Fields:

Validators:

  • resolve_srf_presetsrf
  • set_instrument_defaults
  • validate_compatibility_and_id

Attributes

fov pydantic-field

fov: Optional[float] = None

Field of view in degrees (for camera-like instruments: HYPSTAR, perspective_camera, dhp_camera)

instrument pydantic-field

instrument: GroundInstrumentType

Ground instrument type

platform_type pydantic-field

platform_type: Literal[GROUND] = GROUND

Platform type (always 'ground')

post_processing pydantic-field

post_processing: Optional[PostProcessingOptions] = None

Post-processing pipeline options (spatial averaging, SRF, circular mask, etc.)

resolution pydantic-field

resolution: Optional[List[int]] = None

Film resolution [width, height] (for camera-like instruments: HYPSTAR, perspective_camera, dhp_camera)

viewing pydantic-field

viewing: Union[
    LookAtViewing,
    AngularFromOriginViewing,
    HemisphericalViewing,
    DistantViewing,
]

Viewing geometry

s2gos_simulator.config.sensors.SatellitePlatform

Bases: str, Enum

Supported satellite platforms.

s2gos_simulator.config.sensors.SatelliteInstrument

Bases: str, Enum

Supported satellite instruments.

s2gos_simulator.config.sensors.GroundInstrumentType

Bases: str, Enum

Enum for ground instrument types for robustness.

s2gos_simulator.config.sensors.PostProcessingOptions pydantic-model

Bases: BaseModel

Post-processing pipeline options for ground sensors.

Controls spatial averaging, SRF convolution, circular FOV mask, and RGB output.

Fields:

Attributes

apply_circular_mask pydantic-field

apply_circular_mask: bool = False

Apply circular FOV mask before spatial averaging. Pixels outside the circular FOV are set to NaN and excluded. Enable for HYPSTAR-style circular aperture sensors.

apply_srf pydantic-field

apply_srf: bool = True

Apply Gaussian SRF convolution

generate_rgb_image pydantic-field

generate_rgb_image: bool = False

Generate RGB visualization before spatial averaging. Requires at least 3 wavelengths covering RGB range (440-660nm). Image saved as {sensor_id}_rgb.png in output directory.

rgb_brightness_factor pydantic-field

rgb_brightness_factor: float = 1.8

Brightness multiplier for RGB visualization

rgb_wavelengths pydantic-field

rgb_wavelengths: Tuple[float, float, float] = (
    660.0,
    550.0,
    440.0,
)

Target wavelengths (nm) for RGB channels (red, green, blue)

spatial_averaging pydantic-field

spatial_averaging: bool = False

Average over spatial dimensions (x_index, y_index)

spatial_statistic pydantic-field

spatial_statistic: Literal['mean', 'median'] = 'mean'

Statistic for spatial averaging

s2gos_simulator.config.sensors.create_chime_sensor

create_chime_sensor(
    target_center_lat: float,
    target_center_lon: float,
    target_size_km: Union[float, Tuple[float, float]] = 1.0,
    zenith: float = 0.0,
    azimuth: float = 0.0,
    samples_per_pixel: int = 64,
    ssi_nm: float = 8.4,
    fwhm_nm: Optional[float] = None,
    spectral_regions: Optional[List[SpectralRegion]] = None,
    wmin_nm: float = 400.0,
    wmax_nm: float = 2500.0,
    sensor_id: Optional[str] = None,
    **kwargs,
) -> SatelliteSensor

Create a CHIME hyperspectral satellite sensor with sensible defaults.

CHIME (Copernicus Hyperspectral Imaging Mission) specifications: - Spectral range: 400-2500 nm - Spectral resolution: < 11 nm (FWHM) - Spectral Sampling Interval (SSI): 8.4 nm - Spatial resolution: 30 m - Swath: ~130 km

The sensor uses Gaussian SRF post-processing with wavelength-dependent FWHM to simulate the instrument's spectral response characteristics.

Parameters:

Name Type Description Default
target_center_lat float

Target center latitude (WGS84 decimal degrees)

required
target_center_lon float

Target center longitude (WGS84 decimal degrees)

required
target_size_km Union[float, Tuple[float, float]]

Target area size (km). Float for square, tuple for (width, height)

1.0
zenith float

Viewing zenith angle (0=nadir). Default 0.0

0.0
azimuth float

Viewing azimuth angle. Default 0.0

0.0
samples_per_pixel int

Monte Carlo samples per pixel. Default 64

64
ssi_nm float

Spectral Sampling Interval (nm). Default 8.4 per CHIME spec

8.4
fwhm_nm Optional[float]

Single FWHM for all wavelengths (overrides spectral_regions)

None
spectral_regions Optional[List[SpectralRegion]]

Wavelength-dependent FWHM regions. If None, uses CHIME defaults

None
wmin_nm float

Minimum wavelength (nm). Default 400.0

400.0
wmax_nm float

Maximum wavelength (nm). Default 2500.0

2500.0
sensor_id Optional[str]

Optional sensor ID. Auto-generated if not provided

None
**kwargs

Additional sensor parameters

{}

Returns:

Type Description
SatelliteSensor

SatelliteSensor configured for CHIME hyperspectral simulation

s2gos_simulator.config.sensors.create_hypstar_sensor

create_hypstar_sensor(
    viewing: Union[LookAtViewing, AngularFromOriginViewing],
    fov: float = 5.0,
    resolution: tuple[int, int] = (32, 32),
    reference_file: Optional[str] = None,
    wavelength_variable: str = "wavelength",
    sensor_id: Optional[str] = None,
    **kwargs,
) -> GroundSensor

Create a HYPSTAR ground sensor.

HYPSTAR (HYPERNETS Land Network) specifications: - VNIR detector (Si): 380–1000 nm, FWHM ≈ 3 nm - SWIR detector (InGaAs): 1000–1680 nm, FWHM ≈ 10 nm

When reference_file is provided, SRF post-processing outputs wavelengths from that file (for direct comparison against real HYPSTAR observations). Without it, simulation wavelengths are used.

Parameters:

Name Type Description Default
viewing Union[LookAtViewing, AngularFromOriginViewing]

Pointing configuration (LookAtViewing or AngularFromOriginViewing)

required
fov float

Field of view in degrees. Default 5.0 (HYPSTAR default)

5.0
resolution tuple[int, int]

Film resolution [width, height]. Default (32, 32)

(32, 32)
reference_file Optional[str]

Path to HYPERNETS L2A NetCDF file. If provided, SRF post-processing will output at the file's wavelength grid.

None
wavelength_variable str

Variable name for wavelengths in reference file

'wavelength'
sensor_id Optional[str]

Optional sensor ID. Auto-generated if not provided

None
**kwargs

Additional GroundSensor parameters

{}

Returns:

Type Description
GroundSensor

GroundSensor configured for HYPSTAR simulation