From efb25900b16ff0acc4e7f430aafe531d85fc96fc Mon Sep 17 00:00:00 2001 From: mjames-upc Date: Wed, 8 Jul 2015 12:35:44 -0600 Subject: [PATCH] bufrua demo + all dataaccess xml files --- dataaccess/acars-common-dataaccess.xml | 12 +++ dataaccess/binlightning-common-dataaccess.xml | 12 +++ dataaccess/bufrmos-common-dataaccess.xml | 41 ++++++++++ dataaccess/bufrua-common-dataaccess.xml | 82 +++++++++++++++++++ .../modelsounding-common-dataaccess.xml | 29 +++++++ dataaccess/obs-common-dataaccess.xml | 39 +++++++++ dataaccess/profiler-common-dataaccess.xml | 32 ++++++++ dataaccess/sfcobs-common-dataaccess.xml | 12 +++ examples/GetBufrUA.py | 24 ++++++ 9 files changed, 283 insertions(+) create mode 100644 dataaccess/acars-common-dataaccess.xml create mode 100644 dataaccess/binlightning-common-dataaccess.xml create mode 100644 dataaccess/bufrmos-common-dataaccess.xml create mode 100644 dataaccess/bufrua-common-dataaccess.xml create mode 100644 dataaccess/modelsounding-common-dataaccess.xml create mode 100644 dataaccess/obs-common-dataaccess.xml create mode 100644 dataaccess/profiler-common-dataaccess.xml create mode 100644 dataaccess/sfcobs-common-dataaccess.xml create mode 100755 examples/GetBufrUA.py diff --git a/dataaccess/acars-common-dataaccess.xml b/dataaccess/acars-common-dataaccess.xml new file mode 100644 index 0000000..2a0d6bd --- /dev/null +++ b/dataaccess/acars-common-dataaccess.xml @@ -0,0 +1,12 @@ + + + + + + + + + + \ No newline at end of file diff --git a/dataaccess/binlightning-common-dataaccess.xml b/dataaccess/binlightning-common-dataaccess.xml new file mode 100644 index 0000000..a116b2a --- /dev/null +++ b/dataaccess/binlightning-common-dataaccess.xml @@ -0,0 +1,12 @@ + + + + + + + + + + \ No newline at end of file diff --git a/dataaccess/bufrmos-common-dataaccess.xml b/dataaccess/bufrmos-common-dataaccess.xml new file mode 100644 index 0000000..0004cfb --- /dev/null +++ b/dataaccess/bufrmos-common-dataaccess.xml @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/dataaccess/bufrua-common-dataaccess.xml b/dataaccess/bufrua-common-dataaccess.xml new file mode 100644 index 0000000..ed742ab --- /dev/null +++ b/dataaccess/bufrua-common-dataaccess.xml @@ -0,0 +1,82 @@ + + + + + + + + + + + prMan + htMan + tpMan + tdMan + wdMan + wsMan + + + + + + + + + + + prTrop + tpTrop + tdTrop + wdTrop + wsTrop + + + + + + + + + + + prMaxW + wdMaxW + wsMaxW + + + + + + + + + + + prSigT + tpSigT + tdSigT + + + + + + + + + + + htSigW + wdSigW + wsSigW + + + + + + + + + + \ No newline at end of file diff --git a/dataaccess/modelsounding-common-dataaccess.xml b/dataaccess/modelsounding-common-dataaccess.xml new file mode 100644 index 0000000..b7bee9e --- /dev/null +++ b/dataaccess/modelsounding-common-dataaccess.xml @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + pressure + temperature + specHum + omega + uComp + vComp + cldCvr + + + + + \ No newline at end of file diff --git a/dataaccess/obs-common-dataaccess.xml b/dataaccess/obs-common-dataaccess.xml new file mode 100644 index 0000000..0cedfdd --- /dev/null +++ b/dataaccess/obs-common-dataaccess.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + skyCover + skyLayerBase + skyCoverType + skyCoverGenus + + + + + + + + + + + + presWeather + + + + + + + + + + \ No newline at end of file diff --git a/dataaccess/profiler-common-dataaccess.xml b/dataaccess/profiler-common-dataaccess.xml new file mode 100644 index 0000000..e123267 --- /dev/null +++ b/dataaccess/profiler-common-dataaccess.xml @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + height + uComponent + vComponent + HorizSpStdDev + wComponent + VertSpStdDev + peakPower + levelMode + uvQualityCode + consensusNum + + + + + \ No newline at end of file diff --git a/dataaccess/sfcobs-common-dataaccess.xml b/dataaccess/sfcobs-common-dataaccess.xml new file mode 100644 index 0000000..795f932 --- /dev/null +++ b/dataaccess/sfcobs-common-dataaccess.xml @@ -0,0 +1,12 @@ + + + + + + + + + + \ No newline at end of file diff --git a/examples/GetBufrUA.py b/examples/GetBufrUA.py new file mode 100755 index 0000000..691023b --- /dev/null +++ b/examples/GetBufrUA.py @@ -0,0 +1,24 @@ +#!/awips2/python/bin/python +from ufpy.dataaccess import DataAccessLayer + +request = DataAccessLayer.newDataRequest() +request.setDatatype("bufrua") +#request.setParameters("temperature","dewpoint") +request.setParameters("prMan","htMan") + + +locations = DataAccessLayer.getAvailableLocationNames(request) +print locations + +request.setLocationNames("72230") + +datatimes = DataAccessLayer.getAvailableTimes(request) +print datatimes[-1].validPeriod + +response = DataAccessLayer.getGeometryData(request,times=datatimes[-1].validPeriod) +print response + +ob = response[0] +print "KBMX observation from %s" %ob.getDataTime().getRefTime() +print "Temperature is",ob.getString("temperature") +print "Dewpoint is",ob.getString("dewpoint")