Metadata-Version: 2.4
Name: altimetry-io
Version: 0.2.1
Summary: Provide a unified way to read a data collection, independent of the underlying data representation.
Author-email: Anne-Sophie Tonneau <atonneau@groupcls.com>, Thomas Zilio <tzilio@groupcls.com>, Robin Chevrier <rchevrier@groupcls.com>
Maintainer-email: Anne-Sophie Tonneau <atonneau@groupcls.com>, Thomas Zilio <tzilio@groupcls.com>, Robin Chevrier <rchevrier@groupcls.com>
Project-URL: Homepage, https://github.com/CNES/altimetry-io
Project-URL: Repository, https://github.com/CNES/altimetry-io
Project-URL: Changelog, https://github.com/CNES/altimetry-io/blob/main/CHANGELOG.md
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Oceanography
Classifier: Development Status :: 4 - Beta
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: fsspec
Requires-Dist: numpy
Requires-Dist: pandas
Requires-Dist: xarray
Requires-Dist: files-collections
Provides-Extra: polygon
Requires-Dist: geopandas; extra == "polygon"
Requires-Dist: pyinterp; extra == "polygon"
Requires-Dist: shapely; extra == "polygon"
Provides-Extra: sources
Requires-Dist: cls_tables; extra == "sources"
Requires-Dist: swot_calval; extra == "sources"
Provides-Extra: testing
Requires-Dist: pytest; extra == "testing"
Requires-Dist: geopandas; extra == "testing"
Requires-Dist: pyinterp; extra == "testing"
Requires-Dist: shapely; extra == "testing"
Requires-Dist: h5py; extra == "testing"
Requires-Dist: dask; extra == "testing"
Requires-Dist: numba; extra == "testing"
Provides-Extra: coverage
Requires-Dist: pytest-cov; extra == "coverage"
Provides-Extra: documentation
Provides-Extra: dev-tools
Requires-Dist: ruff; extra == "dev-tools"
Requires-Dist: pre-commit; extra == "dev-tools"
Dynamic: license-file

# Altimetry-io

A library providing a unified way to read an altimetry data collection, independent of the underlying data representation.

- Relies on [Files Collections](https://cnes.github.io/fcollections/) for NetCDF files collections reading
- Can also read ZCollections format

## Installation

```bash
conda install altimetry-io -c conda-forge
```

## Use

```python
from altimetry.io import AltimetryData, FileCollectionSource

alti_data = AltimetryData(
    source=FileCollectionSource(
        # Path to a local directory containing NetCDF data
        path="data_dir",
        # Available ftype: SWOT_L2_LR_SSH, SWOT_L3_LR_SSH, SWOT_L3_LR_WIND_WAVE, NADIR_L2, NADIR_L3
        ftype="SWOT_L3_LR_SSH",
        # Available ftype for SWOT_L3_LR_SSH: Basic, Expert, Unsmoothed, Technical
        subset="Unsmoothed"
    ),
)

ds = alti_data.query_orbit(
    cycle_number=13,
    pass_number= [153, 155],
    variables=["time", "latitude", "longitude", "quality_flag", "ssha_unedited"],
    polygon=(-151, -109, 71, 78)
)
print(ds.sizes)
```

Output:

```text
Frozen({'num_lines': 15893, 'num_pixels': 519})
```

```python
print(list(ds.data_vars))
```

Output:

```text
['quality_flag', 'ssha_unedited', 'cycle_number', 'pass_number']
```

## Project status

⚠️ This project is still subject to breaking changes. Versioning will reflects
the breaking changes using SemVer convention

## License

Apache 2.0 — see [LICENSE](LICENSE)
