All Projects → dmbaturin → pytaf

dmbaturin / pytaf

Licence: MIT License
TAF (Terminal Aerodrome Forecast) and METAR parser and decoder

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to pytaf

forest
FOREST - Forecast and Observation Research and Evaluation Survey Tool
Stars: ✭ 31 (-24.39%)
Mutual labels:  meteorology
improver
IMPROVER is a library of algorithms for meteorological post-processing.
Stars: ✭ 76 (+85.37%)
Mutual labels:  meteorology
aeyrium-sensor
A Flutter sensor plugin which provide easy access to the Pitch and Roll on Android and iOS devices.
Stars: ✭ 57 (+39.02%)
Mutual labels:  aviation
mptrac
Massive-Parallel Trajectory Calculations (MPTRAC) is a Lagrangian particle dispersion model for the analysis of atmospheric transport processes in the troposphere and stratosphere.
Stars: ✭ 19 (-53.66%)
Mutual labels:  meteorology
descent-app
Top of descent path calculator. Let's calculate your descent!
Stars: ✭ 28 (-31.71%)
Mutual labels:  aviation
em-overview
Overview of the aircraft encounter models that support safety analysis and development of aircraft avoidance systems.
Stars: ✭ 14 (-65.85%)
Mutual labels:  aviation
Cardinal-EMS
Aircraft engine management system using Qt.
Stars: ✭ 20 (-51.22%)
Mutual labels:  aviation
climate
The R climate package: an interface for downloading in-situ meteorological (and hydrological) dataset
Stars: ✭ 51 (+24.39%)
Mutual labels:  meteorology
FlightAnalysis
This library extracts flight information from aircraft movements like departure airfield and time, arrival airfield and time, total flight time and more.
Stars: ✭ 15 (-63.41%)
Mutual labels:  aviation
QFlightinstruments
QFlightInstruments is a Qt library containing flight instruments widgets including: Airspeed Indicator, Altimeter, Vertical Speed Indicator, Turn Coordinator, Attitude Indicator, Heading Indicator, Electronic Attitude Direction Indicator (EADI) and Electronic Horizontal Situation Indicator (EHSI).
Stars: ✭ 65 (+58.54%)
Mutual labels:  aviation
ecPoint-Calibrate
Interactive GUI (developed in Python) for calibration and conditional verification of numerical weather prediction model outputs.
Stars: ✭ 19 (-53.66%)
Mutual labels:  meteorology
gribr
GRIB interface for R using ECMWF ecCodes
Stars: ✭ 18 (-56.1%)
Mutual labels:  meteorology
RTLSDR-Airband
Multichannel AM/NFM demodulator
Stars: ✭ 487 (+1087.8%)
Mutual labels:  aviation
grib-rs
GRIB format parser for Rust
Stars: ✭ 23 (-43.9%)
Mutual labels:  meteorology
firehose examples
Example programs that demonstrate how to use the FlightAware Firehose service
Stars: ✭ 30 (-26.83%)
Mutual labels:  aviation
leaflet-experiments
Demos and experiments with LeafletJS
Stars: ✭ 20 (-51.22%)
Mutual labels:  aviation
python-awips
A framework for querying AWIPS meteorological datasets from an EDEX Data Server.
Stars: ✭ 31 (-24.39%)
Mutual labels:  meteorology
atc-reinforcement-learning
Reinforcement learning for an air traffic control task. OpenAI gym based simulation.
Stars: ✭ 37 (-9.76%)
Mutual labels:  aviation
nmc met io
提供对MICAPS文件, 卫星云图, 天气雷达等数据的读写, 并访问CIMISS和MICAPS CASSANDRA数据库文件等.
Stars: ✭ 77 (+87.8%)
Mutual labels:  meteorology
vad-plotter
Plotter for NEXRAD VWP retrievals.
Stars: ✭ 18 (-56.1%)
Mutual labels:  meteorology
*pytaf is python module for parsing and decoding aviation weather forecasts*

TAF
---

TAF stands for "Terminal Aerodrome Forecast". It's the weather
forecast reporting format used in aviation.

Unlike "normal" weather forecasts for everyday use, TAF is issued for no more than
next 24-30 hours, and includes information critical for flight safety, such as
exact clouds type and ceiling.


This is what a TAF report from the United States may look like:

::

    TAF
      AMD KMKE 172034Z 1721/1824 14013G19KT P6SM SCT028 BKN035 BKN250
     FM180100 17008KT P6SM SCT035 BKN120
     FM181000 17007KT P6SM VCSH BKN040 OVC080
      TEMPO 1811/1815 6SM -TSRA BR BKN030CB
     FM181500 18009KT P6SM VCSH BKN050
     FM182100 16012KT P6SM SCT050 BKN150

What it means:

::

    "TAF AMD KMKE": TAF amended for General Mitchell International Airport,

    "172034Z": Issued at 20:34 Zulu time (UTC) on [September the] 17th

    "1721/1824": Valid from 21:00 UTC on 17th to 24:00 UTC on 18th

    "14013G19KT": Wind from 140 degrees at 13 knots, gusting to 19 knots

    "P6SM": Visibility more than 6 statute miles

    "SCT028 BKN035 BKN250": Clouds scattered at 2800 (28*100) feet, broken at 3500 feet, broken at 25000 feet

    "FM180100 ...": From 01:00 UTC on 18th [wind, visibility, clouds]

    "FM181000 17007KT P6SM VCSH BKN040 OVC080": From 10:00 UTC on 18th [wind, visibility],
          showers in the vicinity, clouds broken at 4000, overcast at 8000

    "TEMPO 1811/1815 6SM -TSRA BR BKN030CB": Temporarily between 11:00 UTC and 15:00 UTC on 18th
           visibility 6 statute miles, light thunderstorms and rain, mist, broken cumulonimbus clouds at 3000

     ...

**Note:** despite the terse format, TAF reports are
written by humans, and are supposed to be interpreted by humans too.

This means the format (from computer point of view) is loosely
standardized and is not guaranteed to be machine readable.

Moreover, TAF format is not exactly the same in all countries.
Not different enough for people to have problems understanding it,
but different enough to make implementing a universal parser
very hard, if not impossible.

United Stated civil airports produce the most machine friendly and
standardized reports and those are the most likely to be interpreted correctly.
Effort was made to interpret European Union civil airport reports
properly, but they exhibit more regional variations, so the interpretation
may be incomplete.
Remember that the interpretation is provided for information purposes only
and should not be used for flight planning (at least not without inspecting
the original undecoded report).

Information about the US TAF format can be found at NOAA website:
http://aviationweather.gov/static/help/taf-decode.php

You can get raw and interpreted reports from there too:
http://www.aviationweather.gov/adds/tafs/


API
---

pytaf contains two base classes: pytaf.TAF and pytaf.Decoder

The constructor of the TAF class takes a string, takes it apart, and stores raw values in a TAF object.

The Decoder is initialized with a TAF object and provides decode() method that returns a string that contains
a human-readable interpretation.

::

    import pytaf

    taf = pytaf.TAF("<my TAF string>")
    decoder = pytaf.Decoder(taf)
    print(decoder.decode_taf())

This is what a decoded string may look like:

::

    TAF for KSFO issued 05:46 UTC on the 20th, valid from 06:00 UTC on the 20th to 12:00 UTC on the 21st
    Wind: variable at 04 knots 
    Visibility: more than 6 statute miles 
    Sky conditions: few clouds at 1000 feet, scattered clouds at 1500 feet, broken clouds at 20000 feet 


Hacking
-------

If you want to change the decoder output format (e.g. output to HTML),
inherit from pytaf.Decoder and overload the _decode_taf() method.
That method contains nothing but calls to other methods and output
string formatting.

The Decoder class provides methods for decoding every type of weather information independently,
so you can easily combine them to wrap that information in any desirable format.

If you want to redefine the interpretation, e.g. produce numeric values
for display in a widget rather than plain english descriptions, you may want to use the TAF object directly.
All its methods return dicts with pretty straightforward key names.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].