2016-03-11 18:41:42 -07:00
Python Data Access Framework for AWIPS II
=========================================
.. image :: https://img.shields.io/pypi/v/python-awips.svg
2016-03-11 18:46:23 -07:00
:target: https://pypi.python.org/pypi/python-awips/
:alt: PyPI Package
2016-03-11 18:41:42 -07:00
.. image :: https://img.shields.io/pypi/dm/python-awips.svg
2016-03-11 18:46:23 -07:00
:target: https://pypi.python.org/pypi/python-awips/
:alt: PyPI Downloads
2016-03-11 18:41:42 -07:00
2016-03-16 12:18:27 -05:00
.. image :: https://readthedocs.org/projects/pip/badge/?version=latest
:target: http://python-awips.readthedocs.org/en/latest/
:alt: Latest Doc Build Status
2016-03-11 18:41:42 -07:00
Install
-------
2016-03-11 18:44:25 -07:00
- pip install python-awips
2016-03-11 18:41:42 -07:00
2016-03-12 22:17:13 -06:00
Requirements
2016-03-11 18:41:42 -07:00
-------------
2016-03-16 16:32:17 -05:00
- Python 2.7 or later
2016-03-11 18:44:25 -07:00
- pip install numpy shapely
2016-03-11 18:41:42 -07:00
From Github
-----------
2016-03-11 18:44:25 -07:00
- git clone https://github.com/Unidata/python-awips.git
- cd python-awips
- python setup.py install
2016-03-11 18:41:42 -07:00
Install for AWIPS II Python
--------------------
2016-03-12 22:17:13 -06:00
AWIPS II >=15.1.3 (March 2016) has `python-awips` installed in /awips2/python, as well as a full meteorological data stack (metpy, matplotlib, numpy, etc).
2016-03-12 20:07:23 -06:00
For AWIPS II systems 15.1.2 and lower:
2016-03-11 18:44:25 -07:00
- wget https://bootstrap.pypa.io/ez_setup.py -O - | /awips2/python/bin/python
2016-03-12 20:07:23 -06:00
- /awips2/python/bin/easy_install pip
2016-03-11 18:44:25 -07:00
- /awips2/python/bin/pip install python-awips
2016-03-11 18:41:42 -07:00
Grid Inventory
--------------
2016-03-12 20:07:23 -06:00
A short script to request available grid names from an EDEX server::
2016-03-11 18:44:25 -07:00
2016-03-11 18:41:42 -07:00
#!python
from awips.dataaccess import DataAccessLayer
# Set host
DataAccessLayer.changeEDEXHost("edex-cloud.unidata.ucar.edu")
# Init data request
request = DataAccessLayer.newDataRequest()
2016-03-16 16:32:17 -05:00
# Set datatype
2016-03-11 18:41:42 -07:00
request.setDatatype("grid")
#
# getAvailableLocationNames method will return a list of all available models
#
# LocationNames mean different things to different plugins beware...radar is icao,
# satellite is sector, etc
2016-03-16 16:32:17 -05:00
#
2016-03-11 18:41:42 -07:00
available_grids = DataAccessLayer.getAvailableLocationNames(request)
for grid in available_grids:
print grid
2016-03-16 12:18:27 -05:00
Documentation
------------------
* http://python-awips.readthedocs.org/en/latest/
* `Jupyter Notebook Examples <http://nbviewer.jupyter.org/github/Unidata/python-awips/tree/master/examples/notebooks/> `_