Skip to main content

Data access for EODAG

Project description

https://badge.fury.io/py/eodag-cube.svg https://img.shields.io/pypi/l/eodag-cube.svg https://img.shields.io/pypi/pyversions/eodag-cube.svg https://mybinder.org/badge_logo.svg

EODAG-cube

This project is the data-access part of EODAG

https://eodag.readthedocs.io/en/latest/_static/eodag_bycs.png

Installation

EODAG-cube is on PyPI:

python -m pip install eodag-cube

Usage - Python API

Example usage for interacting with the api in your Python code:

from eodag import EODataAccessGateway
from rasterio.crs import CRS

dag = EODataAccessGateway()
product_type = 'S2_MSI_L2A_COG'
footprint = {'lonmin': 1, 'latmin': 43.5, 'lonmax': 2, 'latmax': 44}
start, end = '2020-06-04', '2020-06-05'
search_results = dag.search(productType=product_type, geom=footprint, start=start, end=end)
data = search_results[0].get_data(
    crs=CRS.from_epsg(4326),
    resolution=0.0006,
    band="B01",
    extent=footprint
)
print(data)

<xarray.DataArray (band: 1, y: 833, x: 1666)>
array([[[  432,   407,   430, ...,     0,     0,     0],
        [  587,   573,   589, ...,     0,     0,     0],
        [  742,   690,   622, ...,     0,     0,     0],
        ...,
        [15264, 15247, 15214, ...,     0,     0,     0],
        [15069, 15084, 15073, ...,     0,     0,     0],
        [14686, 14701, 14722, ...,     0,     0,     0]]], dtype=uint16)
Coordinates:
* x            (x) float64 0.9999 1.0 1.001 1.002 ... 1.887 1.887 1.888 1.888
* y            (y) float64 44.0 44.0 44.0 44.0 44.0 ... 43.5 43.5 43.5 43.5
* band         (band) int64 1
    spatial_ref  int64 0
Attributes:
    scale_factor:  1.0
    add_offset:    0.0
    _FillValue:    0

Contribute

If you intend to contribute to eodag-cube source code:

git clone https://github.com/CS-SI/eodag-cube.git
cd eodag-cube
python -m pip install -e .[dev]
pre-commit install
tox

LICENSE

EODAG is licensed under Apache License v2.0. See LICENSE file for details.

AUTHORS

EODAG is developed by CS GROUP - France.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

eodag-cube-0.5.0.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

eodag_cube-0.5.0-py3-none-any.whl (21.5 kB view details)

Uploaded Python 3

File details

Details for the file eodag-cube-0.5.0.tar.gz.

File metadata

  • Download URL: eodag-cube-0.5.0.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for eodag-cube-0.5.0.tar.gz
Algorithm Hash digest
SHA256 24130b5020da2d12d2efb9d7c1b0f07b9db0f491a1f9007ecd12dfa321985e21
MD5 8ee35ef2db824d35b67657e67cfed9e2
BLAKE2b-256 c1be7f0d27e90d36e97e17d2e8d94ea30bbbe3cd59d87df76751dc5ad63009e5

See more details on using hashes here.

File details

Details for the file eodag_cube-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: eodag_cube-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 21.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for eodag_cube-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7e30e04c09ab4d985ff10371d89943492c2f5a19a52041c4cd938c55321d7b7e
MD5 3488845062a17693a5a455a7046f3bdf
BLAKE2b-256 175f72efcac1989733368c9de54bb4c21bc1f8911353cbe311bbbd30a351c335

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page