Skip to main content

Satellite data access from Amazon S3 via python

Project description

satdata

Python application

Simplified access to GOES-16 data from python or the command line

Installation

You can install the most recent version of satdata from pypi using pip:

$> python -m pip install satdata

or clone the repository and use pip to install the local copy

$> git clone https://github.com/leifdenby/satdata
$> python -m pip install .

Usage

You can use the command line interface to query and download files:

$> python -m satdata.cli --help
usage: cli.py [-h] [--dt_max DT_MAX] [--region {F,C,M1,M2}]
              [--channel {1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16} | --product {CMIP,TPW,RSR}]
              [--fetch-files] [--debug]
              time

positional arguments:
  time                  query for files around this time, an ISO8601 formatted
                        time,for example 2020-01-20T16:20Z

optional arguments:
  -h, --help            show this help message and exit
  --dt_max DT_MAX       query-window around `time`, an ISO8601 formatted
                        duration for example P1D for one day or PT15M for 15
                        minutes
  --region {F,C,M1,M2}  F: full disk, C: continential US, M1: mesoscale region
                        1 (west), M2: mesoscale region 2 (east)
  --channel {1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16}
                        Radiance channel, options: 1: Blue, 2: Red, 3: Veggie,
                        4: Cirrus, 5: Snow/Ice, 6: Cloud Particle Size, 7:
                        Shortwave Window, 8: Upper-Level tropispheric water
                        vapour, 9: Mid-level tropospheric water vapour, 10:
                        Lower-level water vapour, 11: Cloud-top phase, 12:
                        Ozone, 13: 'Clean' IR longwave window, 14: 'Dirty' IR
                        longwave window, 15: 'Dirty' longwave window, 16:
                        'CO2' longwave infrared
  --product {CMIP,TPW,RSR}
                        Derived products, options: CMIP: Cloud and Moisture
                        Imagery, TPW: Total Precipitable Water, RSR: Reflected
                        Shortwave Radiation Top-Of-Atmosphere
  --fetch-files         fetch all files that match query (default is just to
                        print files that match query
  --debug               show debug info

For example, to query for full-disc data of the Total Precipitable Water (TPW) product near 30th January 2020 at 14:00 UTC run:

$> python -m satdata.cli --region F --product ACHA 2020-01-30T14:00

Or use the module directly from python:

import datetime
import satdata


t = datetime.datetime(day=16, month=1, year=2020, hour=16, minute=0)
dt_max = datetime.timedelta(minutes=20)

cli = satdata.Goes16AWS()
keys = cli.query(time=t, region='F', debug=True, dt_max=dt_max)
fn = cli.download(keys[0])[0]

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

satdata-0.2.4-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file satdata-0.2.4-py3-none-any.whl.

File metadata

  • Download URL: satdata-0.2.4-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

File hashes

Hashes for satdata-0.2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f32b137bc706c467989c8901df1cad506aa61b94350924b0626cf6a59ca96d3a
MD5 7a27aea76db86184574f9c8c2cc3f32d
BLAKE2b-256 483c890c08ec56bcb0da3953d583260fe8d9d46ef04a371b6aefee1d874d9ec2

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