Python tool for aircraft Doppler audio geolocation using historical ADS-B flight data (Source-available)
Python acoustic-geolocationads-baircraft-trackingairplaneaudio-forensicsdoppler-effectdoppler-shiftgeolocationosintsignal-processing
Integrate current main and exercise recorded Python fallback fixtures
Cinna Davisd93518010345
diff --cc .github/workflows/real-performance.ymlindex 1af3218,e7a813c..b30c361--- a/.github/workflows/real-performance.yml+++ b/.github/workflows/real-performance.yml@@@ -88,57 -61,12 +88,58 @@@ jobs- name: Real-input regression testsenv:DOPPLERGEIST_REAL_CPA_FIXTURE: benchmark-inputs/point-120.json- run: python -m pytest -q tests/test_real_prepared_measurements.py tests/test_real_geometry_kinematics.py tests/test_real_batch_scalar_parity.py+ run: python -m pytest -q tests/test_real_prepared_measurements.py tests/test_real_geometry_kinematics.py tests/test_real_batch_scalar_parity.py tests/test_real_motion_support_batch.py tests/test_real_single_pass_sieve.py tests/test_real_refinement_lookup.py tests/test_real_cpa_preparation.py tests/test_real_native_ridge.py tests/test_real_ridge_backend.py tests/test_real_legacy_batch_cache.py tests/test_real_native_acoustic.py tests/test_real_native_acoustic_pipeline.py tests/test_real_batch_ceilings.py tests/test_real_acoustic_screen_cache.py+ - name: Verify the explicit Python fallback on recorded arithmetic+ env:++ DOPPLERGEIST_REAL_CPA_FIXTURE: benchmark-inputs/point-120.json+ DOPPLERGEIST_RIDGE_BACKEND: python+ DOPPLERGEIST_ACOUSTIC_BACKEND: python+ run: python -m pytest -q tests/test_real_batch_scalar_parity.py tests/test_real_legacy_batch_cache.py+ - name: Compare real CPA preparation+ run: python scripts/benchmark_real_cpa_rows.py --baseline-source "$RUNNER_TEMP/baseline/src" --output results/cpa-rows.json --repeats 5 --iterations 20- name: Compare complete payloads and timingsrun: |+ native_option=()+ if [ -f src/dopplergeist/_native_ridge.c ]; then+ native_option=(--require-current-native)+ fi+ if [ -f src/dopplergeist/_native_acoustic.c ]; then+ native_option+=(--require-current-native-acoustic)+ fifor width in 10 120; do- python scripts/benchmark_prepared_measurements.py compare --fixture "benchmark-inputs/point-$width.json" --baseline-source "$RUNNER_TEMP/baseline/src" --current-source src --repeats 2 --timeout-s 600 --output "results/performance-$width"+ python scripts/benchmark_prepared_measurements.py compare --fixture "benchmark-inputs/point-$width.json" --baseline-source "$RUNNER_TEMP/baseline/src" --current-source src --repeats 2 --timeout-s 600 --output "results/performance-$width" "${native_option[@]}"done+ - name: Profile remaining point work outside the timing comparison+ run: |+ python -m cProfile -o results/current-point.prof scripts/benchmark_prepared_measurements.py _worker --source src --fixture benchmark-inputs/point-120.json --output results/current-point-profile --require-native --require-native-acoustic+ python - <<'PY'+ import json+ from pathlib import Path+ import pstats++ statistics = pstats.Stats("results/current-point.prof")+ root = Path.cwd()+ records = []+ for (filename, line, function), (primitive, total, own, cumulative, callers) in statistics.stats.items():+ path = Path(filename)+ relative = path.relative_to(root).as_posix() if path.is_relative_to(root) else filename+ module = (relative[4:-3].replace("/", ".") if relative.startswith("src/")+ and relative.endswith(".py") else path.stem)+ records.append({"module": module, "file": relative, "line": line, "function": function,+ "primitive_calls": primitive, "total_calls": total,+ "self_seconds": own, "cumulative_seconds": cumulative})+ records.sort(key=lambda row: (-row["cumulative_seconds"], -row["self_seconds"],+ row["file"], row["line"], row["function"]))+ summary = {"scope": "Separate profiled width-120 worker, including imports and input loading; excluded from timing medians",+ "timer": "cProfile default elapsed timer; diagnostic attribution, not an uninstrumented CPU measurement",+ "total_calls": statistics.total_calls, "primitive_calls": statistics.prim_calls,+ "total_profiled_seconds": statistics.total_tt, "top_50": records[:50],+ "dopplergeist_functions": [row for row in records if row["module"].startswith("dopplergeist")]}+ output = Path("results/current-point-profile-stats.json")+ output.write_text(json.dumps(summary, indent=2) + "\n")+ print(json.dumps({"profile_summary": str(output), "excluded_from_timing_medians": True,+ "top_10": records[:10]}, indent=2))+ PY- uses: actions/upload-artifact@v4if: always()with:diff --cc src/dopplergeist/tiled_search.pyindex 274d0fa,ef508e1..a502613--- a/src/dopplergeist/tiled_search.py+++ b/src/dopplergeist/tiled_search.py@@@ -20,13 -20,12 +20,13 @@@ import numpy as nimport pandas as pdfrom pyproj import Transformer- from .data_access import CONUS, DataUnavailable, content_hash, sha256, write_json+ from .data_access import CONUS, DataUnavailable, cached_sha256, content_hash, sha256, write_jsonfrom .finite_search import RetentionLedger, bounded_assessment, classified_assessment, identify_mode, mode_seedfrom .resource_usage import process_peak_rss_kib-from .geometry import AcousticSupportError, ecef-from .matching import _cache_ridge_fits-from .search import cpa_table, filter_association_event, pair_candidates, score_candidate+from .geometry import ACOUSTIC_BACKEND, AcousticSupportError, ecef+from .matching import RIDGE_FIT_BACKEND, _cache_ridge_fits+from .search import (_CPA_DTYPE, _PreparedCPATrack, _ordered_cpa_rows,+ filter_association_event, pair_candidates, score_candidate)def _verified_terrain_hash(path, cache):@@@ -752,13 -720,7 +752,13 @@@ def search_national(indexes, terrain, erasters += terrain.geoid.rastersterrain_signature = {"constant_m": getattr(terrain, "constant", None),"rasters": {str(r.name): sha256(r.name) for r in rasters}}+ runtime_identity = {"python": platform.python_version(), "machine": platform.machine(),+ "packages": {name: version(name) for name in ("numpy", "scipy", "pandas", "pyproj", "rasterio", "pyarrow")}}+ if RIDGE_FIT_BACKEND != "python-irls-v1":+ runtime_identity["ridge_fit_backend"] = RIDGE_FIT_BACKEND+ if ACOUSTIC_BACKEND != "python-acoustic-v1":+ runtime_identity["acoustic_backend"] = ACOUSTIC_BACKEND- identity = {"indexes": [{"input_hash": i.report["input_hash"], "file_sha256": sha256(i.path)} for i in indexes],+ identity = {"indexes": [{"input_hash": i.report["input_hash"], "file_sha256": cached_sha256(i.path)} for i in indexes],"terrain": terrain_signature, "additional_input_hashes": input_hashes or {},"events": events, "acoustic_hashes": acoustic, "bounds": list(bounds), "time_range_s": list(time_range_s),"budget": asdict(budget), "scoring": scoring or {}, "filters": filters, "crs": crs, "code": modules,