sidescanpy.core.survey#
Core utilities for SideScan sonar surveys.
Two class levels: - SideScanFrequencyChannel: single-frequency wrapper around an xr.Dataset - SideScanSurvey: container for multiple frequency channels and aux streams
Aux streams (navigation, attitude, dvl, sensors) live at the survey level because they come from the same platform regardless of which sonar frequency was pinging. They are stored as separate xr.Datasets and can be re-interpolated onto ping times by downstream processing steps.
2026 rshomberg@uri.edu
Contents
Wrapper for a single-frequency xr.Dataset. |
|
Container for a sidescan sonar survey. |
- class sidescanpy.core.survey.SideScanFrequencyChannel(dataset, freq_key=None)#
Bases:
objectWrapper for a single-frequency xr.Dataset.
Validates the dataset against the SideScan schema on construction.
- property frequency#
Base frequency in Hz (freq_hz_start).
- class sidescanpy.core.survey.SideScanSurvey(source_files, source_format, survey_name)#
Bases:
objectContainer for a sidescan sonar survey.
Holds:
One or more SideScanFrequencyChannel datasets (different freqs cannot share a single xr.Dataset because n_samples may differ).
Optional navigation, attitude, and DVL auxiliary streams (one each).
Optional sensor auxiliary streams keyed by sensor_type.
Aux streams are stored as separate xr.Datasets that pass their respective accessor’s validate() method (navigation_record, attitude_record, dvl_record, sensor_record).
- copy()#
Shallow copy: same channel/aux dataset objects, new containers, so channels can be replaced without touching this survey.
- add_frequency(freq_key, dataset)#
Add (or replace) a frequency channel. Warns on overwrite.
True if navigation is set AND has at least one observation.
- add_sensor(sensor_type, dataset)#
Add (or replace) a sensor record. Warns on overwrite.
- property sensors#
Read-only copy of the sensors dict.
- property time_range#
(min, max) timestamp across all frequency channels and aux streams. Returns None if the survey is completely empty.
- property bounding_box#
(lat_min, lat_max, lon_min, lon_max).
Prefers navigation aux stream when present and non-empty; otherwise falls back to per-ping latitude/longitude across all frequency channels. Returns None if no positional data is available.