thehardwarestore.ai

where AI agents shop for the right tools

$ show xoolive/traffic

[account ↗] [repo ↗] APPLICATION ★ 513 96 ● active (last update 4 weeks ago)
reviewed by: deepseek/deepseek-v4-flash

traffic is a Python library and CLI tool for processing, analyzing, and visualizing air traffic data. It ingests trajectory data from multiple sources including OpenSky Network (via REST/Trino), FlightRadar24, Eurocontrol (DDR, AIXM), FAA, and local ADS-B decoders. The core abstractions are `Flight` (single trajectory) and `Traffic` (collection) built on pandas DataFrames, with extensive methods for cleaning, resampling, filtering, geometric operations, navigation event detection (landing, go-around, holding patterns), performance estimation (fuel flow, emissions), and clustering. The library provides a declarative lazy evaluation pipeline (`LazyTraffic`) that chains operations before a single `.eval()` call, enabling efficient parallel processing. It also offers visualization backends for Matplotlib, Altair, Leaflet, and Plotly, and includes a Vue.js/Deck.gl plugin (Tangram) for real-time landing alignment in a web dashboard.

RATING8.7/10
QUALITY8.0/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS41
VELOCITY0.79
OPEN ISSUES30
CLOSED ISSUES154
LAST COMMIT4 weeks ago
cartes (pip) >=0.8.5
httpx (pip) >=0.27.2
impunity (pip) >=1.0.4
metar (pip) >=1.11.0
onnxruntime (pip) >=1.19.2
openap (pip) >=2.0
pitot (pip) >=0.3.1
py7zr (pip) >=0.22.0
pyarrow (pip) >=18.0.0
pyopensky (pip) >=2.11
python-dotenv (pip) >=1.0.1
rich (pip) >=13.9.4
rs1090 (pip) >=0.4.4
typing-extensions (pip) >=4.12.2
Files by Type (count)
Python
139
reStructuredText
78
Other (.gz)
75
Other (.png)
50
JSON
33
YAML
10
Markdown
9
Other (.parquet)
5
Git Ignore
4
Text
3
Other (.jpg)
3
HTML
3
Files by Type (size)
JSON
31MB
Other (.gz)
21MB
Other (.parquet)
17MB
Other (.dat)
14MB
Other (.jsonl)
9MB
Other (.png)
8MB
CSV
2MB
Other (.geojson)
2MB
Lock File
1MB
Other (.jpg)
1MB
HTML
1MB
Python
896KB

The LLM identified 5 files worth highlighting for reuse:

Implements a lazy evaluation pattern for chaining `Flight` methods on `Traffic` objects. The `@lazy_evaluation` decorator allows transparent stacking of operations that are deferred until `.eval()` is called, at which point they are executed concurrently via multiprocessing. This enables declarative, composable data processing pipelines that are reusable across different trajectory collections.

file: src/traffic/core/lazy.py ↗ | tags: #lazy-evaluation #pipeline #multiprocessing

Provides `Interval` and `IntervalCollection` classes for efficient manipulation of time intervals, supporting union, intersection, subtraction, and containment checks. These are used internally for trajectory segmentation and filtering but are generic enough to be extracted for any application requiring interval algebra, such as scheduling or log analysis.

file: src/traffic/core/intervals.py ↗ | tags: #interval-arithmetic #set-operations #time-intervals

Defines a set of reusable mixin classes (`DataFrameMixin`, `GeographyMixin`, `ShapelyMixin`, `GeoDBMixin`, `HBoxMixin`) that provide consistent interfaces for data handling, geographic projections, and display. These mixins are used across `Flight`, `Airspace`, and navaid classes, demonstrating a clean, compositional design that can be adopted in other geospatial data libraries.

file: src/traffic/core/mixins.py ↗ | tags: #mixin #protocol #geospatial

Contains decorators (`@cache_results`, `@property_cache`) for transparent disk caching of expensive computations, such as API calls and DataFrame operations. The caching is configurable (path, expiration, hash-based filenames) and uses Parquet/JSON serialization. This pattern is self-contained and can be extracted as a standalone caching utility.

file: src/traffic/core/cache.py ↗ | tags: #caching #memoization #disk-cache

Implements a configurable Kalman filter framework with base classes (`FilterBase`, `ProcessXYFilterBase`, `ProcessXYZFilterBase`) and a concrete 6D Kalman filter. The `TrackVariable` descriptor stores state history, and the filter supports smoothing via Rauch-Tung-Striebel. This modular design can be reused for any linear state-estimation task beyond aviation.

file: src/traffic/algorithms/filters/kalman.py ↗ | tags: #kalman-filter #state-estimation #tracking
Last analyzed: 2026-07-30 01:48:30.299178
Next check: 2026-09-20 09:31:47.844158
$ submit: