Earth Sciences
Universal neural networks for real-time earthquake early warning trained with generalized earthquakes
X. Zhang and M. Zhang
Discover how Xiong Zhang and Miao Zhang are revolutionizing earthquake monitoring through a novel deep learning approach. By utilizing a data recombination method to improve model generalization, their research enables accurate real-time earthquake early warning across diverse regions. Remarkably, their models can pinpoint earthquake locations and magnitudes within just four seconds of P-wave detection!
~3 min • Beginner • English
Introduction
The study addresses the challenge of rapidly and accurately reporting earthquake source parameters for early warning using limited, early P-wave data from seismic networks. Traditional EEW systems involve multiple modules (phase picking, association, location, magnitude estimation, alert filtering) and numerous empirically tuned thresholds, creating trade-offs between speed and false alarms. Single-station onsite methods rely on a few seconds of P-wave features and usually require confirmation from additional stations to avoid false alerts. While deep learning has improved phase detection and association and enabled end-to-end monitoring, most models are region-specific and depend on fixed station geometries, limiting generalization and requiring transfer learning when moved to new regions. The purpose of this study is to develop universally applicable neural networks that can detect earthquakes and estimate location and magnitude in real time across diverse regions and station layouts, using the full information in continuous waveform streams at the earliest stage of an event.
Literature Review
Prior EEW approaches include network-based systems such as ElarmS and threshold-based onsite methods, which require carefully tuned parameters and multiple stations to ensure reliability. Machine learning has been used to improve individual steps (phase picking, association) and end-to-end workflows. Single-station CNNs have been developed for detection and coarse localization or parameter inference, though back-azimuth estimates can be noise-sensitive. Multistation methods using fully convolutional networks or graph neural networks incorporate station spatial information to estimate location and magnitude. However, these approaches generally exhibit limited generalization across regions and station geometries and often require transfer learning. Recent work shows early-stage parameter estimation is possible, but applications have been largely confined to the training region and fixed station configurations.
Methodology
Core idea: construct generalized training earthquakes by recombining real single-station seismograms so that synthetic events can occur at arbitrary locations with arbitrary station geometries. Assumption: for a global 1D layered approximation, seismograms with the same epicentral distance and depth share similar arrival-time moveout features, permitting recombination across regions.
Data collection and base set: 94,586 three-component single-station seismograms from real events in central Italy (M≥2.5; 42,945 seismograms), Oklahoma (M≥3.0; 36,203), and Southern California (M≥2.5; 15,438). Depths for Italy are ~5–17 km; for Oklahoma ~0–8 km; epicentral distances mostly 0–110 km. To improve magnitude training for large events, 1,454 single-station waveforms from 21 M>6.0 Japanese earthquakes (K-NET) were added (converted from acceleration to velocity). All data were resampled to 20 Hz, rotated to E, N, Z, mean/trend removed, instrument responses deconvolved. Bandpass filters: 2–8 Hz for detection/location; 0.5–9 Hz for magnitude.
Generalized earthquake synthesis: For each training sample, randomly choose an earthquake location within the monitoring volume (X: 16–66 km; Y: 0–100 km; depth: 0–20 km) and 4–12 station locations within a larger station coverage (X: 0–82 km; Y: 0–100 km). For each synthetic station compute epicentral distance r and azimuth φ. From the base dataset, select a three-component waveform with matching epicentral distance and source depth. Rotate the E and N components to the new azimuth by applying a 2D rotation to align with the synthetic source-receiver geometry. Normalize amplitudes to a common magnitude using the empirical scaling log(A) = Mw − 1.110 log(r/100) − 0.00189 (r − 100) − 3.0 so that recombined waveforms are amplitude-consistent. Apply a 2–8 Hz bandpass for detection/location.
Training datasets: 355,001 generalized earthquakes within monitoring areas for detection and location networks. Additionally, 2,000 events are generated outside the monitoring area and labeled with zero-PDF to train out-of-range rejection. To simulate real-time EEW, 30 s windows are used with random truncation start times 1–26 s after first P arrival among stations to produce samples in which only a subset of stations has triggered. For the magnitude network, inputs are single-station waveforms; 200,000 samples are generated from the 94,586 base waveforms with random truncations (1–25 s post-P arrival). To emphasize large events, 100,000 additional samples are generated from the 1,454 M>6 waveforms.
Neural network architectures: Three models are used: (1) detection, (2) location, and (3) magnitude. Detection and location use 2D fully convolutional architectures; magnitude uses 1D convolutional layers. Input formatting: Detection input is a tensor of size 12×1024×3 (stations × time samples × components). Each 30 s window at 20 Hz yields 600 samples, zero-padded to 1024 to suit pooling/upsampling. Variable station counts (<12) are zero-padded in the station dimension. The detection output is a 1D Gaussian-like PDF over time with peak marking the first triggered P arrival; noise-only inputs are labeled zero. Location input augments waveform channels with station XY coordinates normalized to [0,1] based on ranges (X: 0–82 km, Y: 0–100 km). Stations and inputs are sorted by X and separately by Y; the total input is 12×1024×10 with five channels for data sorted by X (three components + X + Y) and five channels sorted by Y (same content reordered), producing a unique image-like pattern per event and network geometry. The location output is a 3D Gaussian-like PDF over a grid covering X: 16–66 km, Y: 0–100 km, depth: −6 to 22.8 km (labeling depth range broader than generation range to accommodate Gaussian tails). Magnitude model input per station is 1024×5: three normalized waveform channels plus epicentral distance (normalized 0–1 for 0–110 km) and log of the waveform normalization factor (scaled 0–1 for 10.0 to 0.0). Output is a 1D Gaussian-like PDF over magnitude.
Training details: Convolutional kernels are 3×3 (2D) or length-3 (1D), with zero-padding to preserve sizes. MaxPooling layers extract key features; UpSampling layers restore output dimensions. To mitigate vanishing gradients, copy/skip-like connections are used in location and magnitude models. Dropout layers: 2 (detection), 4 (location), 2 (magnitude). Optimizer: Adam, learning rate 1e−4. Detection and location models are merged for simultaneous operation. Operationally, when detection triggers, theoretical P times are computed from the predicted origin and stations whose theoretical P falls inside the current window are considered triggered; their waveforms, epicentral distances, and normalization factors are fed to the magnitude network, and final magnitude is the mean over triggered stations.
Testing and deployment setup: Real-time simulations use sliding 30 s windows with 0.5 s step. PDF thresholds for issuing an alarm were selected via validation: detection 0.7 and location 0.6. The models are applied without region-specific retraining to: (a) the 2018 Osaka, Japan sequence (one day of continuous data; 179 cataloged events M≥2.0 for parameter assessment), (b) the 2019 Ridgecrest, US sequence (one day of continuous data; 349 events M≥2.5 for assessment), (c) 130 onshore events across Japan (Hi-net; M≥5.0) and Northern California, US (M≥4.0) with one-hour continuous data per event, and (d) 9 offshore Japan S-net events (M>5). A case study is conducted for the 2016 M7.3 Kumamoto event using K-NET strong-motion data. Station selections are within 110 km, and if more than 12 are available, the closest 12 to the epicenter are used. Monitoring areas are centered to include station coverage and encompass all stations.
Key Findings
- Universal applicability: Networks trained on recombined single-station data from Italy, Oklahoma, and Southern California generalize to Japan and Northern California without retraining, working with varying station counts and layouts.
- Early-warning timeliness: First alarms are typically issued ~4 s after the first P arrival when detection and location PDF thresholds (0.7 and 0.6) are met; sparse networks (3–5 stations) may need >8 s.
- Mainshock case studies: Osaka M6.1 (2018) and Ridgecrest M6.4 (2019) can be detected and located within 2.2–2.7 s; at 4 s, epicenter errors are 3.9 km (Osaka) and 3.2 km (Ridgecrest), with magnitudes underestimated early (5.5 vs 6.1; 5.8 vs 6.7) but improving by 15 s.
- Robustness on sequences: Using 179 Osaka events (M>2.0) and 349 Ridgecrest events (M>3.5), mean epicenter errors are 2.6 km (Osaka) and 4.5 km (Ridgecrest); magnitude mean absolute errors are 0.08 and 0.11.
- Early-time accuracy curves: At 4 s after first trigger, Osaka errors: 4.8 km epicentral distance, 0.18 magnitude; Ridgecrest: 6.3 km, 0.20. At 15 s, Osaka: 2.7 km, 0.05; Ridgecrest: 4.9 km, 0.07. Depth errors at 4 s/15 s: Osaka 2.7/5.0 km; Ridgecrest 4.1/3.1 km.
- First alarm performance across 139 events: Mean errors at first alarm are 5.5 km (epicentral), 4.2 km (depth), and 0.32 (magnitude); timing centers near 4 s.
- Generalization across regions: For 130 onshore events (Japan Hi-net and N. California), mean errors are 4.9 km (epicentral), 4.0 km (depth), and 0.17 (magnitude). For 9 offshore Japan S-net events, mean errors are 7.3 km, 8.7 km, and 0.22, indicating sensitivity to complex offshore structures.
- Detection in continuous data: 4,385 events detected across one-hour continuous datasets; models can detect events smaller than the M≥2.5 training minimum.
- Catalog consistency: No false alarms for M>3.0 in Osaka day-long test; in Ridgecrest, 15 of 106 M>3.0 and 1 of 16 M>4.0 cataloged events were missed, likely due to closely spaced events in time.
- Comparison with traditional picking-based EEW: Using Ridgecrest events, the mean first alarm time is 0.7 s earlier than a traditional ElarmS-like workflow, with lower location and magnitude errors at first alarm. For the 2016 M7.3 Kumamoto event, the neural network reached M~5.9 at 01:25:11.9 and converged toward the final magnitude by 01:25:16.9, about 2 s earlier than the traditional method’s comparable updates.
- Large-event case (Kumamoto M7.3): First report at 3.5 s after first P with 6.1 km location error and initial magnitude ~5.4; by 15 s, location error ~5.0 km and magnitude ~7.1.
Discussion
The work demonstrates that training with generalized, recombined earthquakes enables neural networks to learn region-agnostic waveform moveout and amplitude patterns for rapid, direct parameter inference. By operating on continuous multistation waveform windows and integrating station coordinates, the networks bypass multiple fragile intermediate steps of traditional EEW, reducing reliance on region-specific thresholds and configurations. Results across diverse regions show consistent early-warning performance and accuracy within seconds of first P arrival, meeting the core goal of initiating timely EEW. Comparisons with a traditional picking-based workflow indicate earlier alarms and improved first-alarm accuracy, highlighting the value of end-to-end waveform-based inference. The models also handle variable station counts and can exploit partial triggering, which is crucial in real-time operations with incomplete data, outages, or transmission delays. While depth and offshore performance are more challenging due to complex structures and surface-only stations, the framework nonetheless delivers actionable estimates fast enough to inform protective actions.
Conclusion
This study introduces a generalized data recombination strategy and fully convolutional neural network suite for universal, real-time EEW. By synthesizing hundreds of thousands of training samples with arbitrary station layouts and locations, the models learn robust features that transfer across regions without retraining. The system detects and locates events and estimates magnitudes within a few seconds of first P arrival, typically issuing alarms around 4 s, and achieves kilometer-scale epicentral accuracy and small magnitude errors. The approach reduces dependence on complex, region-tuned parameter settings and enables rapid deployment. Future work should address depth estimation and offshore performance by incorporating region-specific training samples or fine-tuning, adding station elevation and broader station coverage, integrating additional sensors (e.g., smartphones), handling multiple simultaneous events in a window, expanding strong-motion training across magnitudes, and increasing robustness to abnormal real-time data artifacts.
Limitations
- Structural simplification: Training recombination assumes a global 1D layered model and ignores focal mechanisms and complex path effects; this degrades performance for offshore and complex tectonic settings.
- Depth resolution: Surface network geometry provides weak constraints on depth, yielding larger depth errors than epicentral errors, particularly at shallow depths.
- Multiple events per window: The 30 s window may contain overlapping events; the network tends to favor the dominant event or produce low PDFs, risking misses or mixed parameter estimates.
- Teleseismic and out-of-area events: Although 2,000 out-of-range samples were included for rejection, additional teleseismic training data could further reduce false triggers.
- Station coverage constraint: The monitoring area must be covered by the station distribution; performance suffers for offshore events monitored only by onshore stations.
- Data artifacts: Gaps, spikes, clipping, and other anomalies in real-time streams can bias parameter estimates, especially for small events; more training on such artifacts would improve robustness.
- Magnitude scaling for large events: Limited strong-motion training data and class imbalance can cause early underestimation; more diverse strong-motion datasets across magnitudes are needed.
- Threshold dependence: Though fixed PDF thresholds (0.7 detection, 0.6 location) work across tested regions, they remain operational hyperparameters that may affect detection/false-alarm tradeoffs.
Related Publications
Explore these studies to deepen your understanding of the subject.

