tephpy.samples#
Sounding data shipped with tephpy (gallery spec §3.1).
Four samples from two stations, each read by name through a public reader.
from tephpy import samples
snd = samples.sounding("norman-12z")
Norman, Oklahoma, 2013-05-20 — the morning of the Moore EF5 tornado: the 12Z ascent of the canonical example (spec §4), and the 17Z special released about three hours before the tornado touched down. Both are in one IGRA v2 station file.
Camborne, 2026-07-21 12Z — one ascent, shipped twice: as the IGRA record
and as the University of Wyoming TEXT:CSV body. The pair exists so the
reader how-to can show both supported routes into a
Sounding converging on the same profile
(narrative spec §3.6), which needs the same physical ascent on both sides.
Provenance. All four captured by
tests/fixtures/generate_io_fixtures.py.
The Norman file, 2026-08-20, from NCEI’s IGRA v2 period-of-record file for station USM00072357, keeping the two ascents of that date as whole byte-faithful blocks — a header record and its declared level count.
The Camborne IGRA file, 2026-07-27, the same way from that station’s year-to-date file.
The Camborne Wyoming body, 2026-07-27, from the University of Wyoming sounding archive, thinned to every 40th data row plus the first and last; kept rows are byte-faithful and the header row is complete.
Attribution. The IGRA files are from the NOAA/NCEI Integrated Global Radiosonde Archive version 2, a U.S. Government work in the public domain; cite it as Durre, I., X. Yin, R. S. Vose, S. Applequist, and J. Arnfield (2016), doi:10.7289/V5X63K0Q. The Wyoming body is sounding data courtesy of the University of Wyoming, College of Engineering, Department of Atmospheric Science. That archive publishes no redistribution terms, so it travels here as a considered risk rather than a granted permission — narrative spec §3.6 states the position and #202 carries the question.
Notes
Added in version 0.1.0.
Functions#
|
Report the sample names |
|
Return the file a shipped sample is read from. |
|
Read a shipped sounding by name. |
Package Contents#
- tephpy.samples.available() tuple[str, ...][source]#
Report the sample names
sounding()accepts.Notes
Added in version 0.1.0.
- tephpy.samples.path(name: str) pathlib.Path[source]#
Return the file a shipped sample is read from.
Two formats ship, so there is no one file to return without being asked — this took no argument while the package carried a single IGRA station file. It is a file beside this module rather than an
importlib.resourcestraversable: the caller this exists for is a reader opening it withigra.readorwyoming.parse, and a zip-imported install would hand them a path that vanishes on the next line.Note that one file may hold several samples: both Norman ascents are in one IGRA station record, so two names give the same path and differ only in the ascent they select from it.
- Parameters:
- name
str One of the names
available()reports.
- name
- Returns:
pathlib.PathThe file holding that sample.
- Raises:
ValueErrorIf name is not a shipped sample.
Notes
Added in version 0.1.0.
- tephpy.samples.sounding(name: str) tephpy.sounding.Sounding[source]#
Read a shipped sounding by name.
Every sample goes through a public reader —
igra.readorwyoming.parse— which is the same documented route a user’s own file takes. A sample reached by a private path would demonstrate nothing a reader could repeat.- Parameters:
- name
str One of the names
available()reports.
- name
- Returns:
SoundingThe ascent.
- Raises:
ValueErrorIf name is not a shipped sample.
Notes
Added in version 0.1.0.