Skip to main content

easily download and plot NEXRAD weather radar reflectivity data

Project description

Travis-CI Coveralls.io AppVeyor Build Station image image Maintainability PyPi Download stats

Nexrad Quick-plot

Easy Python download and plot NEXRAD compositive reflectivity. Uses the RGB high resolution North American PNG images.

tested with pytest, flake8 and mypy type checking.

Install

python -m pip install -e .

Usage

Download NEXRAD data

Get NEXRAD reflectivity data with parallel download:

python download-nexrad.py start stop outdir

example: download from 2018-01-01 to 2018-01-02 to ~/data/nexrad:

python download-nexrad.py 2018-01-01T00 2018-01-03T00 ~/data/nexrad

Plot NEXRAD reflectivity data

(georegistered via Cartopy)

Plot all data in directory:

python plot-nexrad.py ~/data/nexrad/

Plot a specific file (subplots if multiple files specified):

python plot-nexrad.py ~/data/nexrad/2018-01-01T12:35:00.png

Plot via file glob match:

python plot-nexrad.py ~/data/nexrad/ -pat 2018-01-01T12*.png

Keogram (specify lat or lon and value):

python plot-nexrad.py ~/data/2017-08-21/nexrad/ -keo lat 40 

Coordinates

EPSG:4326 coordinates (WGS84) are in .wld files, which are generally the same for wide time spans of data. The .wld format is like:

0.005 (size of pixel in x direction)
0.0 (rotation of row) (Typically zero)
0.0 (rotation of column) (Typically zero)
-0.005 (size of pixel in y direction)
-126.0 (x coordinate of centre of upper left pixel in map units--here it's WGS84 longitude)
50.0 (y coordinate of centre of upper left pixel in map units--here it's WGS84 latitude)

Notes

Mass image downscaling

For initial analysis, the original Nexrad image size of 12200 x 5400 pixels may be too high to complete in a reasonable time. I choose to downsize by a factor of 10, which takes a long time, but is a one-time process.

mkdir orig
cp *.png orig

nice mogrify -scale 10% "*.png"

If you have trouble with this being very slow, try:

MAGICK_TEMPORARY_PATH=/run/shm nice mogrify -scale 10% "*.png"

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

NEXRAD_quickplot-0.6.2.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

NEXRAD_quickplot-0.6.2-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

Details for the file NEXRAD_quickplot-0.6.2.tar.gz.

File metadata

File hashes

Hashes for NEXRAD_quickplot-0.6.2.tar.gz
Algorithm Hash digest
SHA256 5a248ee7d376b24bf23aaaf75224d83645cce6fb3dc3406b12cf4a4217df788c
MD5 dbb74fca02dbe98600d40b1ea7eb19c2
BLAKE2b-256 4f0caf668fdfa7da445d54d37ab5d753b9be885db9feffba85c6b943d67d369f

See more details on using hashes here.

Provenance

File details

Details for the file NEXRAD_quickplot-0.6.2-py3-none-any.whl.

File metadata

File hashes

Hashes for NEXRAD_quickplot-0.6.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b11b5ab2e9c1fedb7c0977cac04191cf3c65323287a3815bc00319d200a24951
MD5 d3b78841f30e5d886642201b5ca70676
BLAKE2b-256 09e9239b34ee901c9af029a9d494c6d28fa78df2bda414b39f2047b032afd1bd

See more details on using hashes here.

Provenance

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