Skip to content

Repository files navigation

DAS Realtime Detection Demos

Portable, reproducible demonstrations of waveform-domain screening for distributed acoustic sensing (DAS). The project compares a streaming amplitude baseline (STA/LTA) with two multi-channel coherence methods (SVD and QR) and evaluates them through controlled replay of historical data.

The default examples use deterministic synthetic data. No private Fervo data, credentials, absolute project paths, or proprietary directory conventions are included.

Algorithms

  • Streaming STA/LTA spatially averages channels and detects short-term amplitude increases relative to the preceding background. It is fast, but it does not explicitly measure spatial coherence.
  • SVD coherence measures concentration in a dominant coherent spatial mode over Fourier-domain temporal subwindows. Coherent machinery can also score highly.
  • QR coherence uses a QR proxy for coherence and reports the dominant temporal subwindow. This is approximate timing, not a P- or S-wave pick.

See docs/algorithms.md and docs/interpretation.md before interpreting results.

Installation

python -m venv .venv
.venv/Scripts/activate      # Windows PowerShell
python -m pip install -e ".[test,notebooks,dascore]"

The core synthetic workflow needs NumPy, pandas, matplotlib, and PyYAML. DASCore is optional until user-provided DAS files are loaded.

Quick start

python examples/run_all_detectors.py
pytest -q

Then open the three notebooks in order. Each has one configuration section, loads examples/config.example.yaml, uses synthetic data by default, reports processing time and approximate detection latency, and imports all scientific logic from src/das_realtime_detection.

Historical replay

HistoricalDASReplay divides a patch or spool into chronological, half-open chunks while preserving source timestamps. Pacing may be acquisition-speed, accelerated by speed_factor, or disabled for deterministic tests. Consumers can receive chunks directly or read atomically written .npz files. Each chunk reports acquisition duration, processing time, progress, and backlog.

External data

Copy examples/config.example.yaml, set data.use_synthetic: false, and set data.input_path to a readable DAS file. The notebooks validate the path and use dascore.read; unsupported formats fail with an actionable message. Dataset-specific MD corrections, raw-file indexing, well selection, and time zone assumptions belong in a local adapter and are intentionally absent here.

Outputs

The notebooks print candidate intervals and timing measurements and can save compact figures under a configured relative output directory. Notebook output is cleared before version control. Replay chunks are only written when an output directory is explicitly configured.

Interpretation and limitations

A candidate means amplitude change or coherent waveform energy, depending on the detector. It is not automatically an earthquake. Narrowband operational signals, machinery, vibroseis, and other coherent sources require contextual review and catalog comparison. Thresholds are starting values; validate them against cataloged events and representative quiet periods. QR timing is limited to one analysis subwindow and is not a phase arrival.

Relationship to DASieve

DASieve's existing dasieve.detection.EventDetector operates on phase picks and emits association windows. These demos add optional waveform screening before phase picking. DASieve's file watcher observes genuinely arriving files; this project's replay engine produces controlled historical cadence.

Citation and contributions

Use CITATION.cff for citation metadata. Issues and focused pull requests are welcome. Scientific changes should include deterministic tests and explain their effect on thresholds, state continuity, timing, and event merging.

About

Portable, deterministic demos for real-time DAS waveform detection and historical replay

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages