Files
seismo-relay/sfm
serversdownandClaude Opus 5.5 e506bcff9b fix(sfm): Thor .h5 samples use Thor's LSB, not the MiniMate count scale (#42)
Every idf-import .h5 converted Thor's raw geo counts with the MiniMate
body-codec scale, full_scale / _GEO_INT16_FS.  A Thor count is
0.000310308 in/s (micromate.idf_file._GEO_LSB_IPS), so the float samples
disagreed with the event's own peak by a constant:

  10/32768 (until 686ab6e, 2026-08-25)   samples -1.65%
  10/32000 (since)                       samples +0.71%

v0.30.0's LSB fix (726c2ce) never reached this path.  It corrected the
decoder's peaks, which were already right in the DB, sidecar and h5
peak attrs.  The sample arrays go through the shared .h5 writer instead.

write_event_hdf5 now takes geo_ips_per_count.  save_imported_idf and
backfill_thor_events (which replays the same bridge with its own write)
both pass _GEO_LSB_IPS.  MiniMate callers are unchanged.

Measured: all 8 thor-idf fixtures (4 IDFW + 4 IDFH, 24 channels) go from
max|sample| / peak = 1.00706 to 1.00000 through the real ingest path.

Operational consequence: no schema change, no migration, TOOL_VERSION
not bumped here.  Existing idf-import .h5 files keep the wrong scale
until regenerated: scripts/backfill_thor_events.py (--force, or bump
TOOL_VERSION at release), then backfill_event_shape.py, because the
offset detector reads these samples.  Series-3 files are unaffected.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 13:05:51 -04:00
..
2026-03-30 23:23:29 -04:00