Answer
fp32 keeps every pick. fp16 stays within a 30 ms tolerance; bf16 does not.
PR #71 rewrites how PhaseNet and the amplitude code run on a CPU. We re-picked the leaderboard's
26,531 picks (threshold 0.2, weight PhaseNet original, weight version 2) three ways
and compared each pick with the current code's.
fp32 · what the PR uses on Fargate and Graviton
picks identical to the millisecond
The other 2 moved by one sample (10 ms) on a flat-topped peak. Amplitudes agree to 9e-12. Runs 5.9 to 6.6 times faster on Graviton.
fp16 · not in the PR, tested for comparison
picks identical
99.83 % within 30 ms; 29 picks move further (up to 420 ms). Picks gained or lost all sit at the threshold. Speed not measured.
bf16 · the PR's mode on Intel AMX CPUs only
picks identical
98.06 % within 30 ms; 333 picks move further (up to 480 ms) and 437 appear or disappear. No speed gain on our hardware, which has no AMX.
Against the 7,593 analyst picks, none of the three changes recall by more than 0.001 or mean absolute error by more than 1 ms, and none moves the median bias. The difference is in reproducing the catalogue, not in accuracy.
Precision
How far do the picks move?
Share of the current code's picks that each mode reproduces within a given timing tolerance, at threshold 0.2. The 30 ms line is the tolerance used on this page: analyst P picks scatter by 23 ms (Ross et al. 2018) and the current code's P picks scatter around the analysts' by 32 ms on this benchmark. Curves stop short of 100 % because of picks that appear or disappear at the threshold (0.19 % for fp16, 1.65 % for bf16, none for fp32).
| mode | identical (0 ms) | within 10 ms | within 30 ms | largest shift | spread of shifts (σ) | picks appearing or disappearing |
|---|---|---|---|---|---|---|
| fp32 | 99.99 % | 100.00 % | 100.00 % | 10 ms | 0.1 ms | 0 / 0 |
| fp16 | 98.74 % | 99.49 % | 99.83 % | 420 ms | 4.7 ms | 16 / 34 |
| bf16 | 89.32 % | 95.31 % | 98.06 % | 480 ms | 11.3 ms | 181 / 256 |
For scale: the current code's own picks scatter around the analysts' with a σ (from the median absolute deviation) of 32 ms (P) and 38 ms (S) on this benchmark. bf16 adds a 11 ms scatter on top; fp16 5 ms.
Background
What fp32, fp16 and bf16 are
They are ways of storing each number inside the network. Fewer bits make the arithmetic faster on CPUs built for it, and round every intermediate value more coarsely. Think of it as digitizer resolution applied to every layer of PhaseNet.
| format | bits per value | bits of precision | rounding step (relative) | largest value |
|---|---|---|---|---|
| fp32 (single precision) | 32 | 24, like a 24-bit digitizer | 6×10-8 | 3×1038 |
| fp16 (half precision) | 16 | 11 | 5×10-4 | 65,504 |
| bf16 ("brain float") | 16 | 8 | 4×10-3 | 3×1038 |
PhaseNet's output is a probability trace per phase, and a pick is the sample where it peaks above the threshold. Rounding perturbs that trace a little. Where the peak is sharp nothing happens; where it is flat the maximum can jump to a neighbouring sample, and where it sits near the threshold the pick can appear or disappear. Under bf16 the 99th percentile change in the trace's peak value is 0.045; under fp32 it is too small to measure at the 10-4 level.
Precision
Against analyst picks
Recall within 0.5 s at threshold 0.2, as on the leaderboard. Of the 7,593 analyst picks, the number whose outcome changes is 0 for fp32, 2 for fp16 and 14 for bf16.
| track | phase | analyst picks | current code | fp32 | fp16 | bf16 |
|---|---|---|---|---|---|---|
| US sequences | P | 625 | 0.720 | 0.720 | 0.720 | 0.720 |
| US sequences | S | 439 | 0.754 | 0.754 | 0.754 | 0.754 |
| swarm sequences | P | 3,314 | 0.680 | 0.680 | 0.680 | 0.681 |
| swarm sequences | S | 3,215 | 0.658 | 0.658 | 0.659 | 0.658 |
Your tolerance
Choose what counts as the same pick
Starts at a 30 ms tolerance with 0.5 % of picks allowed to fail; change either. Picks that appear or disappear only because they sit just at the threshold are excused by the confidence margin.
A pick fails when it moves by more than the tolerance, or when it is lost or new and its
confidence is more than the margin above the threshold. Per-pick data: errors_pr_fp32.csv.gz · errors_pr_fp16.csv.gz · errors_pr_bf16.csv.gz.
Speed
Six times faster on AWS Graviton, in fp32
The same 5.55 station-days (42 benchmark windows) processed by four workers on an 8-vCPU machine, the shape of a Fargate task. Median of four repetitions; picking and amplitudes included, S3 reads and writes not.
| machine | current code | PR, fp32 | faster | Spot $ per 1,000 station-days |
|---|---|---|---|---|
| M1 Max laptop | 150 s | 129 s | 1.2× | – |
| c6g.2xlarge (Graviton2) | 145 s | 22 s | 6.6× | $0.58 → $0.09 |
| c7g.2xlarge (Graviton3) | 93 s | 16 s | 5.9× | $0.38 → $0.06 |
| c8g.2xlarge (Graviton4) | 77 s | 13 s | 6.1× | $0.30 → $0.05 |
Where the time goes
Most of the saving is the Wood-Anderson amplitude code: 90 % of the time saved on Graviton4. PhaseNet itself runs 1.7× faster there. These windows are aftershock sequences with many picks; an ordinary station-day has far fewer, so the gain in a campaign will be smaller. Not yet measured.
Why the laptop gains little
The PR's fast PhaseNet needs a library (oneDNN) that no macOS build of PyTorch includes, so on an Apple laptop only the amplitude code speeds up, and picking runs 1.34× slower.
Prices: on-demand from the AWS Pricing API, cheapest-AZ Spot from describe_spot_price_history, both 2026-10-26. For comparison, Fargate Spot costs about $0.17/h for the same 8 vCPU (CloudBank billing). Fargate itself was not timed.
Details
Method, full tables, limits
What each mode runs
Current code: sbm.PhaseNet.from_pretrained("original").classify and main's
AmplitudeExtractor() at 7dd1be7. fp32: PR head
a5d4d43 with the settings of its removed runner (vibesys/pick_workload.py at
4271d67): BatchNorm folded into the convolutions, polyphase transposed convolutions, fast windowing
(glue=fused), amplitudes impl="fused", signal="slim". bf16 and fp16: the same,
with weights and inputs in 16 bits, fp32 accumulation, and every layer's output rounded to 16 bits. This
emulates Intel AMX for bf16 and is a best case for fp16. Run on the M1 Max laptop.
Precision workload: 130 cached station-windows of docs/benchmark/results/{us,swarm}_sequences, 7,593 analyst picks. Picks at a 0.02 floor, thresholded afterwards, paired with
benchmark_metrics.match_picks within 0.5 s. The cached waveforms for Mendocino, Monroe and San
Simeon CI are not the streams the leaderboard picked, so absolute US recall differs from the board; every mode
read the same files.
Picks against the current code, both thresholds
| threshold | mode | track | picks | identical | moved | lost | new | p99 |shift| | p99 |Δconfidence| |
|---|---|---|---|---|---|---|---|---|---|
| 0.2 | fp32 | swarm sequences | 22,428 | 99.996 % | 1 | 0 | 0 | 0 ms | 0.000 |
| 0.2 | fp32 | US sequences | 4,103 | 99.976 % | 1 | 0 | 0 | 0 ms | 0.000 |
| 0.2 | fp16 | swarm sequences | 22,428 | 98.863 % | 243 | 12 | 25 | 10 ms | 0.004 |
| 0.2 | fp16 | US sequences | 4,103 | 98.050 % | 77 | 3 | 8 | 10 ms | 0.006 |
| 0.2 | bf16 | swarm sequences | 22,428 | 89.772 % | 2,151 | 143 | 208 | 40 ms | 0.034 |
| 0.2 | bf16 | US sequences | 4,103 | 86.863 % | 512 | 27 | 37 | 40 ms | 0.045 |
| 0.3 | fp32 | swarm sequences | 18,652 | 99.995 % | 1 | 0 | 0 | 0 ms | 0.000 |
| 0.3 | fp32 | US sequences | 3,459 | 99.971 % | 1 | 0 | 0 | 0 ms | 0.000 |
| 0.3 | fp16 | swarm sequences | 18,652 | 98.949 % | 183 | 13 | 12 | 0 ms | 0.004 |
| 0.3 | fp16 | US sequences | 3,459 | 98.236 % | 60 | 1 | 7 | 10 ms | 0.005 |
| 0.3 | bf16 | swarm sequences | 18,652 | 90.682 % | 1,644 | 94 | 130 | 30 ms | 0.032 |
| 0.3 | bf16 | US sequences | 3,459 | 87.280 % | 420 | 20 | 32 | 40 ms | 0.044 |
Every fp32 difference at the 0.02 floor (10 picks)
| sequence | station | phase | time | confidence, current | confidence, fp32 | side |
|---|---|---|---|---|---|---|
| Etna edifice 2022-2024 | IV.EPDN | S | 2023-05-28 05:17:05.230 | 0.0558 | – | vanilla only |
| Etna edifice 2022-2024 | IV.EPDN | S | 2023-05-28 05:17:05.240 | – | 0.0558 | pr_fp32 only |
| Jones-Guthrie 2014-2015 | OK.U32A | P | 2014-07-13 02:43:48.210 | 0.6186 | – | vanilla only |
| Jones-Guthrie 2014-2015 | OK.U32A | P | 2014-07-13 02:43:48.220 | – | 0.6186 | pr_fp32 only |
| Jones-Guthrie 2014-2015 | US.WMOK | P | 2014-03-22 03:59:47.520 | 0.0427 | – | vanilla only |
| Maurienne 2017-2019 | GU.RRL | P | 2017-10-27 01:13:23.180 | 0.0470 | – | vanilla only |
| Maurienne 2017-2019 | GU.RRL | P | 2017-10-27 01:13:23.210 | – | 0.0470 | pr_fp32 only |
| Mendocino 2024 | BK.RBOW | S | 2024-12-05 20:12:28.290 | 0.4039 | – | vanilla only |
| Mendocino 2024 | BK.RBOW | S | 2024-12-05 20:12:28.300 | – | 0.4041 | pr_fp32 only |
| Mendocino 2024 | NC.KCT | P | 2024-12-05 19:17:16.163 | – | 0.0203 | pr_fp32 only |
Same arrival one to three samples apart with confidences equal to about 10-4. Folding BatchNorm changes the order of the fp32 sums, which moves the probability trace by about 10-6 and can flip which sample of a flat peak is the maximum.
Amplitudes
| amplitude | picks | stations | with a value | missing-value pattern differs | max relative difference |
|---|---|---|---|---|---|
| Wood-Anderson | 13,727 | 44 | 7,535 | 0 | 9.4e-12 |
| velocity | 13,727 | 44 | 13,530 | 0 | 4.1e-12 |
Western US and Oklahoma stations only: EarthScope served no response for the Etna (IV) stations, and the French and most Czech stations were not measured.
Exact agreement across Graviton generations
| picks identical to the ms | c6g current | c7g current | c8g current | c6g PR | c7g PR | c8g PR |
|---|---|---|---|---|---|---|
| c6g current | 10,620 | 10,616 | 10,620 | 10,619 | 10,615 | 10,619 |
| c7g current | 10,616 | 10,620 | 10,616 | 10,617 | 10,619 | 10,617 |
| c8g current | 10,620 | 10,616 | 10,620 | 10,619 | 10,615 | 10,619 |
| c6g PR | 10,619 | 10,617 | 10,619 | 10,620 | 10,616 | 10,620 |
| c7g PR | 10,615 | 10,619 | 10,615 | 10,616 | 10,620 | 10,616 |
| c8g PR | 10,619 | 10,617 | 10,619 | 10,620 | 10,616 | 10,620 |
10,620 picks per run at threshold 0.2. The current code itself differs by 4 picks between Graviton2 and Graviton3, so a millisecond rule cannot hold across our own hardware even without the PR.
Timing per repetition and cost at on-demand prices
| machine | code | wall per repetition (s) | picking | Wood-Anderson | velocity |
|---|---|---|---|---|---|
| M1 Max laptop | current code | 152.1, 151.5, 149.4, 137.4 | 322 s | 192 s | 9.3 s |
| M1 Max laptop | PR, fp32 | 126.5, 132.3, 129.5, 128.7 | 432 s | 32 s | 2.8 s |
| c6g.2xlarge (Graviton2) | current code | 144.8, 144.2, 144.7, 144.5 | 67 s | 395 s | 10.6 s |
| c6g.2xlarge (Graviton2) | PR, fp32 | 21.9, 21.8, 21.8, 21.7 | 36 s | 23 s | 2.2 s |
| c7g.2xlarge (Graviton3) | current code | 93.3, 93.1, 93.1, 93.2 | 23 s | 268 s | 7.7 s |
| c7g.2xlarge (Graviton3) | PR, fp32 | 15.7, 15.7, 15.7, 15.7 | 25 s | 16 s | 1.9 s |
| c8g.2xlarge (Graviton4) | current code | 76.6, 76.6, 76.7 | 37 s | 206 s | 6.7 s |
| c8g.2xlarge (Graviton4) | PR, fp32 | 12.6, 12.6, 12.6, 12.5 | 21 s | 12 s | 1.7 s |
Stage times summed over the four workers.
| instance | CPU | on-demand $/h | Spot $/h | on-demand $ per 1,000 station-days, current / PR |
|---|---|---|---|---|
| c6g.2xlarge (Graviton2) | AWS Graviton2 (Neoverse-N1) | $0.272 | $0.0802 | $1.969 / $0.297 |
| c7g.2xlarge (Graviton3) | AWS Graviton3 | $0.289 | $0.0824 | $1.347 / $0.227 |
| c8g.2xlarge (Graviton4) | AWS Graviton4 | $0.318 | $0.0772 | $1.219 / $0.200 |
Limits and defects found in the PR
jma_wc, the global weight, was not scored.obs(PickBlue) cannot use the fast path: building it raisesdoes not cover this model setup: ['padding/filter'].- bf16 was emulated, not run on AMX hardware. fp16 speed was not measured.
- Streams the model resamples (30 of 130 windows) fall back to SeisBench's windowing. Timing used 100 Hz only.
- The 707-line
s3_helper.pyrewrite was not reviewed. veliir.c(velocity amplitudes) does not build on ARM, so SciPy ran on Graviton. Built with its x86-only CPU probe guarded, it matched SciPy to 10-11.- As merged, nothing selects the fast settings, so production would run the current code.
Reproduce
Harness in scripts/vibesys_pr71/;
export_results.py writes the tables in
docs/benchmark/results/vibesys_pr71/,
and scripts/build_vibesys_report.py builds this page from them.
References
- Ross, Z. E., Meier, M.-A. and Hauksson, E. (2018). P wave arrival picking and first-motion polarity determination with deep learning. Journal of Geophysical Research: Solid Earth 123, 5120-5129. doi:10.1029/2017JB015251
- Zhu, W. and Beroza, G. C. (2019). PhaseNet: a deep-neural-network-based seismic arrival-time picking method. Geophysical Journal International 216, 261-273. doi:10.1093/gji/ggy423