Python tool for aircraft Doppler audio geolocation using historical ADS-B flight data (Source-available)
Python acoustic-geolocationads-baircraft-trackingairplaneaudio-forensicsdoppler-effectdoppler-shiftgeolocationosintsignal-processing
Align coherent harmonic overlap with the existing event contract
Cinna Daviscff7d1646932
diff --git a/docs/COHERENT_DISCOVERY.md b/docs/COHERENT_DISCOVERY.mdindex d9d1405..6d366f9 100644--- a/docs/COHERENT_DISCOVERY.md+++ b/docs/COHERENT_DISCOVERY.md@@ -21,9 +21,18 @@ Alternatively, add the reference checkout's `src` to `PYTHONPATH`. The scriptprocesses the entire original recording with the reference template bank. Itcaptures actual measured ridge samples, skips unused straight-pass profile-rangecalculations, and exports the existing detected-event schema. It reuses the-reference's 40-point and 1% relative-fit-residual requirements without its hard-aircraft/close type gate. Slow and nearby proposals remain eligible. Duplicate-and harmonic ridges are grouped; their count is not an independent aircraft count.+reference's 40-point and 1% relative-fit-residual requirements. It removes the+later aircraft/close classification cutoffs at 30 m/s and 150 m. Duplicate and+harmonic ridges are grouped; their count is not an independent aircraft count.++The reference template bank and refinement limits remain unchanged. In+[`_refine_all`](https://github.com/digitalis-p/doppler-locate/blob/ed84e0f/src/dopploc/detect.py),+accepted fits require `6 < speed < 290` m/s and `35 < slant distance < 30000` m.+The fitted center must stay within `max(10 seconds, half-window / 2)` of the+template center, and the fit residual must not exceed `1.5 × harmonic order` Hz.+Tracing and fitting can also fail. Broad downstream matching priors cannot+recover a ridge rejected by these upstream limits. This experimental script+does not remove every speed or distance restriction requested in issue #341.These are acoustic proposals. They can include ground traffic, and short curvescan fit several unrelated archived flights. Neither a low residual nor ADS-B@@ -44,6 +53,9 @@ and first two background-labeled clips per publisher location for development,then the next two per class/location as a held-out set. No labels, flight IDs orlocations enter the detector. The complete case outcomes are in the[24-row table](../benchmarks/coherent-proposals-341-20261104.csv).+The table was committed at revision `69b11cf4`, before the supported-overlap correction.+That correction can change harmonic grouping, but not accepted traces or+whether a clip has proposals. The recorded rows remain unchanged.| Partition and publisher label | Clips | Ordinary discovery | Coherent adapter | Union || --- | ---: | ---: | ---: | ---: |diff --git a/src/dopplergeist/coherent_discovery.py b/src/dopplergeist/coherent_discovery.pyindex 9862bbd..f3a408f 100644--- a/src/dopplergeist/coherent_discovery.py+++ b/src/dopplergeist/coherent_discovery.py@@ -1,7 +1,8 @@-"""Adapt measured coherent traces without aircraft-type or geometry rejection.+"""Adapt already-refined coherent traces without an aircraft/close kind filter.Experimental audio proposals only. Straight-pass fit quality does not identifyan aircraft; the historical-track matcher and decision stage remain necessary.+The upstream detector's template and refinement limits still apply."""import numpy as np@@ -31,8 +32,8 @@ def events_from_coherent_traces(traces):raise ValueError("Coherent traces require ordered finite measured ridge samples")paths.append(points)- # Reference traces have a 0.25 s hop. Use elapsed overlap rather than a- # frame count tied to the ordinary discovery backend's 0.5 s hop.+ # _overlap uses a 0.5 s comparison grid even for 0.25 s source traces.+ # Match prepare_events: count supported samples, not gaps between endpoints.groups = []for path in sorted(_merge_duplicates(paths), key=lambda p: np.median(p[:, 1])):for group in groups:@@ -40,7 +41,7 @@ def events_from_coherent_traces(traces):if shared is None:continuet, base, frequency = shared- if np.ptp(t) < .6 * min(np.ptp(group[0][:, 0]), np.ptp(path[:, 0])):+ if len(t) * .5 < .6 * min(np.ptp(group[0][:, 0]), np.ptp(path[:, 0])):continueratio = frequency / baseharmonic = min(_HARMONIC_RATIOS, key=lambda h: abs(h - np.median(ratio)))