Commit Graph
650 Commits
Author SHA1 Message Date
serversdownandClaude Opus 5.5 e1e8a851c8 docs: where the 1995 default-clock events come from
Brian's account: units come back from calibration with the internal
battery unplugged, so a comms-test trigger before the date is set
carries the default.  DL2 holds 17 such events on 6 units, all within
1995-09-01 12:02 .. 09-03 11:24.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-03 12:12:02 -05:00
serversdownandClaude Opus 5.5 8a40eb638a fix(decode): a Blastware file's footer is its last 26 bytes -- no more day-late histograms
Every DL2 file ends in a valid footer: 0e 08 and two valid times on
70,041 / 70,041.  The decoder took the first '0e 08 + plausible year'
instead, and 14 files also hold an earlier record, ~1.1 KB before the
end, with the stop time followed by zeros:
- a histogram started at its own stop -- a day late on BE9558's daily
  histograms (K558L9XP.FK0H: 2025-10-08 19:10:01 for Blastware's
  2025-10-07 19:14:08); T003LCYV.JD0H got no time at all;
- a waveform lost its stop, so the trigger was never computed and the
  stop was stamped instead (K440I4LG.JK0W: 11:14:12 for 11:14:08).

The last 26 bytes are now taken when they are a footer; otherwise the
old search stands unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-03 12:10:44 -05:00
serversdownandClaude Opus 5.5 dd9f6dde7a docs(changelog): Unreleased -- histograms go to the histogram codec
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-03 11:32:57 -05:00
serversdownandClaude Opus 5.5 f768ec42f3 merge: histograms go to the histogram codec, and a loud interval no longer hides a short one
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-03 11:32:01 -05:00
serversdownandClaude Opus 5.5 aec4a38473 fix(decode): histograms go to the histogram codec, and a loud interval no longer hides a short one
Three causes behind the histograms the checker found decoding wrongly:

1. The file decoder tried the waveform codec first, whatever the record
   type.  It accepted BE9440 / BE9557 / BE17354's 2018 5 s histograms and
   returned ~5x too many 'samples' (K440HDXX.XH0H: SFM 44,504, Blastware
   6,976).  The codec now follows STRT[18] (0x46 / 0x0A on 70,041 /
   70,041 DL2 files); only an unknown type falls back to trial order, and a
   chosen codec that fails is a decode problem rather than a silent switch.

2. The sub-minute layout check required each record's 'zero word' to be
   0000.  It is the high word of the interval's PVS squared, non-zero above
   1.28 in/s, so a one-block histogram with a loud interval was not
   recognised (T193KR5M.X90H, K440HA3C.JM0H, R352HFZ7.530H decoded to
   nothing).  The check is now the measured relation peak <= PVS <=
   sqrt(3) * peak, which holds on 34,502,955 / 34,502,955 DL2 sub-minute
   intervals.  The no-terminal-tail trim uses the same test.  Two test
   builders wrote PVS bytes no real record has (one still in the retracted
   little-endian layout); they now write peak^2 in the measured layout, and
   the retraction test keeps a legacy builder of its own.

3. Checker carve-out interval-count-is-duration: Blastware's Number of
   Intervals is (stop - start) / interval from the footer times, and its
   own interval table lists one block fewer when the unit never wrote the
   last minute.  SFM matches the table (T193KSWP.FF0H: 2,880 vs 2,850).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 16:20:32 -05:00
serversdownandClaude Opus 5.5 99b6b315d6 docs(changelog): Unreleased -- the job number from the file
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 16:09:48 -05:00
serversdownandClaude Opus 5.5 fec59679e6 merge: a Blastware file's job number, and whether Blastware shows it
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 16:09:16 -05:00
serversdownandClaude Opus 5.5 7a58bad28d feat(decode): a Blastware file's job number, and whether Blastware shows it
The setup block has Series IV's 0x1A layout here too: report flags at
k - 9 (bit 0x02 = job number shown) and the number, uint16 BE, at k - 8,
kept while switched off.  The flag matches Blastware's JobNumber on
2,997 / 2,997 DL2 events that print one and 66,986 / 66,986 that don't.
Every printed value is 1 and matches; hidden ones hold real numbers
(802, 1012, 1013, 622), so the value is only proven for 1.

- ProjectInfo.job_number_enabled / job_number, named as in
  micromate.setup_block.
- write_event_hdf5 stores both as .h5 attrs when read (additive).
- The checker reports the number only when shown, and scores a number
  only SFM shows as a mismatch.  The old test that pinned JobNumber as
  sfm_blank now checks only the ZC cases it also covered.

Not carried into the DB, the API or the PDF report yet (needs a column).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:31:23 -05:00
serversdownandClaude Opus 5.5 15a27d5921 docs(changelog): Unreleased -- the file's pre-trigger is the event's
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:23:49 -05:00
serversdownandClaude Opus 5.5 a30cf47825 merge: the file's pre-trigger is the event's -- corrects today's #48 note
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:23:33 -05:00
serversdownandClaude Opus 5.5 5bed7d6c6f docs: the file's pre-trigger is the event's, not the setting -- corrects today's #48 note
The pre-trigger float in an event file's setup block varies from event
to event on the same unit, often on the same day (BE18193: -0.25 and
-0.248 on 2026-08-21; 253-256 samples at 1024 sps, -0.002 to -0.249 s
at 4096 sps), and Blastware reports the same per-event value as
Pre-triggerLength.  So it is the event's own pre-trigger, and the note
written earlier today overstated what the files say about #48: the live
1A holds the setting, so a missing anchor in a file says little about
whether the live read loses its anchor.  #48 stays open.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:23:32 -05:00
serversdownandClaude Opus 5.5 55d74c0a7b docs(changelog): Unreleased -- the event-file fields in the protocol reference
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:04:10 -05:00
serversdownandClaude Opus 5.5 9c0b608c38 merge: the event-file fields in the protocol reference (Appendix D.6) and CLAUDE.md
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:03:58 -05:00
serversdownandClaude Opus 5.5 b6e726f850 docs: the event-file fields SFM reads from the file alone (reference Appendix D.6)
New Appendix D.6 records the bytes and DL2 verification for every field
SFM reads from a Blastware event file: record type STRT[18], the
recording-setup block (sample rate k-42, pre-trigger k-36, record time
k-30, the four notes), the geophone range (label+29), each histogram
interval's PVS^2, and the mic scale (0.25 Pa per count, dB offset
81.9384).  None of these were written down outside code and issues.

Retracted in place:
- D.3.1's STRT[20] = record time: it is 00 on 70,041 / 70,041 DL2 files.
- the 2026-08-26 reading of sub-minute histogram records as little-
  endian: big-endian from byte 5 since v0.32.0 (#47/#49), and the
  '2-word tail' is the PVS^2.  Also in CLAUDE.md.

Measured for #48 (files only): the 1A 'stable anchor' be 80 00 00 00 00
is the setup's pre-trigger -0.25 s plus 00 00.  It is present only on
the 3,886 / 6,541 DL2 waveforms recorded at exactly -0.25 s, and on no
histogram.  The live 1A read is still unmeasured.

CLAUDE.md: Where things stand reflects the range fix on dev (6,524 /
6,524 waveforms exact); the 8x sensitive-range item and the MicL dB
item are marked resolved in place.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 14:03:47 -05:00
serversdownandClaude Opus 5.5 be58b4f8f0 docs(changelog): Unreleased -- the geophone range from the file
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 12:04:15 -05:00
serversdownandClaude Opus 5.5 057df47460 merge: a Blastware file's geophone range from its setup -- Sensitive events no longer 8x
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-02 12:03:41 -05:00
serversdownandClaude Opus 5.5 4844135f01 fix(decode): a Blastware file's geophone range comes from its setup -- Sensitive events no longer read 8x
In the setup's channel blocks, the byte 29 after each geophone label is
the range: 0x00 Normal (10 in/s), 0x01 Sensitive (1.25 in/s).  It matches
Blastware's GeoRange on 70,042 / 70,042 DL2 events, all three channels
agreeing on every one (35 Sensitive).  SFM's live 1A has the same byte
at label+33.  SFM assumed Normal, so every Sensitive event's peaks,
vector sum and .h5 samples read 8x high.

- Event.geo_range (0 / 1, None when not read -- channels disagreeing,
  an unknown value or a missing block -- with a decode_problems entry).
- decode_blastware_bytes scales peaks and the histogram vector sum by it.
- event_hdf5.write_event_hdf5: geo_range defaults to None = the event's
  own, else Normal; an explicit argument still wins.
- waveform_store.save_imported_bw and scripts/backfill_sidecars.py stop
  forcing 'normal', so imports and the backfill store the file's range.
  The waveform_store line was agreed with the parity session, which owns
  that file; its own branch keeps a geo_range parameter, defaulting to
  None at its next dev merge.
- The checker's SFM side converts at the event's range and reports
  GeoRange; tests that pinned the old 8x gap now pin the fix, and the
  saturation carve-out is still tested against an 8x value.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-01 16:26:15 -05:00
serversdownandClaude Opus 5.5 6c7c6b0a15 chore(release): v0.33.0 — SFM reads Series-3 events from the file alone, and proves it
A Blastware event that reaches SFM without its ASCII report -- every DL2
event before 2025, and every event SFM downloads itself -- now carries
its sample rate, record time, pre-trigger, notes and event type, the
histogram vector sum the unit stores, and a mic reading at one count =
0.25 Pa.  The new decode checker proves each against Blastware's own
_XML.XML reports for 70,042 DL2 events.

- CHANGELOG: Unreleased -> v0.33.0 with theme and Migration.
- TOOL_VERSION 0.33.0 (gates the backfill regeneration).
- pyproject, CLAUDE.md and README versions; README status entry and
  roadmap (the Series-III codec item was long done; the file-only goal
  added); CLAUDE.md 'Where things stand' brought up to v0.33.0.

Deploy: back up seismo_relay.db, then backfill_sidecars.py and
backfill_event_shape.py (~2 h on the NAS).  No schema change, no
migration, event times do not move.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-11-01 14:20:15 -05:00
serversdownandClaude Opus 5.5 287ef2a653 docs(changelog): Unreleased -- one MicL count is 0.25 Pa
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-31 02:19:49 -04:00
serversdownandClaude Opus 5.5 30a249ef57 merge: one MicL count is 0.25 Pa; Blastware's dB offset 81.9384
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-31 02:19:17 -04:00
serversdownandClaude Opus 5.5 18951505f0 fix(decode): Blastware's mic dB offset is 81.9384, a hair above exact 0.25 Pa
The checker caught 280 regressions in the first mic fix: every one a dB
value at count 129, where 20 log10(129 x 0.25 Pa / 20 uPa) = 124.149997
rounds to 124.1 and Blastware prints 124.2.  Blastware's dB offset sits in
[81.9383, 81.9385] -- any value there matches its dB(L) on 1,729,252 /
1,729,253 DL2 intervals (the last printed '0.000'); exact 81.93820 rounds
count 129 down, and the old 81.94 misses counts 119 and 132.  Single
precision does not explain it.  psi keeps 0.25 Pa per count, which
matches every interval.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-31 01:55:45 -04:00
serversdownandClaude Opus 5.5 5644dbd5ad fix(decode): one MicL count is 0.25 Pa -- the mic psi was ~95x low
SFM converted mic counts to psi with a '~0.5 psi full-scale' guess
(0.0125 / 32768 psi per count).  Measured against 1,729,253 DL2
histogram intervals' 'MicL Peak' columns: one count is exactly 0.25 Pa.
count x 0.25 Pa matches Blastware's psi(L) on every interval, and
20 log10(count x 0.25 Pa / 20 uPa) its dB(L) on all but 17 exact
half-way cases.

- event_file_io: _MIC_FS_PSI -> _MIC_PSI_PER_COUNT = 0.25 / 6894.757
  (3.626e-5 psi per count, was 3.81e-7).  The event's mic peak in psi,
  and with it the .h5 mic trace (event_hdf5 back-solves its scale from
  that peak), come right on events with no report.
- waveform_codec.mic_count_to_db: the offset is 20 log10(0.25 / 20e-6)
  = 81.938, not 81.94 -- the old value missed 49 of those intervals at a
  rounding edge (count 119 printed 123.4, 81.94 gave 123.451).

The decoded count was always right: count 16 on K441LTON.900 is
Blastware's 106.0 dB.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-31 01:28:23 -04:00
serversdownandClaude Opus 5.5 dc42ae041a docs(changelog): Unreleased -- a histogram's stored peak vector sum
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-30 01:54:27 -04:00
serversdownandClaude Opus 5.5 0fc68065fe merge: a histogram's peak vector sum from the stored per-interval value
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-30 01:53:54 -04:00
serversdownandClaude Opus 5.5 625bc39116 fix(decode): a histogram's peak vector sum is the one the unit stores
Every histogram interval carries its peak vector sum SQUARED, uint32 BE
in 0.005 in/s units: bytes [21:25] of a standard block (long documented
as 'constant 00 00' plus 'purpose unknown'), the last 4 bytes of a
sub-minute record (the undecoded 'meta_var').  sqrt(stored) x 0.005 is
the Geo PVS Blastware prints: 1,668,073 / 1,668,074 standard and 34.5 M
sub-minute DL2 intervals checked against the _XML.XML reports.

SFM computed the event's PVS from each channel's interval peak, which
can come from different moments, and read high on 86% of DL2's
histograms (T004JTRF.ME0H: 1.782 against Blastware's 1.358).  It now
takes the largest stored interval value.  histogram_codec.interval_pvs
returns the per-interval series; records gain 'pvs_sq'.  Waveforms are
unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-30 01:29:58 -04:00
serversdownandClaude Opus 5.5 b6fc71bd28 docs(changelog): Unreleased -- record type from the bytes (#41)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 23:32:32 -04:00
serversdownandClaude Opus 5.5 ede6292e4d merge: a Blastware event's record type from its bytes (#41)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 23:31:53 -04:00
serversdownandClaude Opus 5.5 46daea17b2 fix(decode): a Blastware event's record type comes from its bytes, not its filename (#41)
STRT[18] is the record-type byte: 0x46 on every one of DL2's 6,577
waveform files, 0x0A on every one of its 63,535 histograms.  The decoder
read the type from the filename's last letter, so an event with no
Blastware name -- SFM's own downloads, the call-in path -- or a manual
download ('.QZ0') came out 'Waveform' whatever it was.

The filename is now a cross-check that logs a disagreement; the bytes
win.  An unknown byte (Manual / Event / Combo never occur in DL2) is
record_type None with a decode_problems entry, not a guess.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 23:06:25 -04:00
serversdownandClaude Opus 5.5 b92c8e489e docs(changelog): Unreleased -- the Series 3 decode checker, and the corrected #53 note
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 22:46:08 -04:00
serversdownandClaude Opus 5.5 fed6489330 merge: the Series 3 decode checker -- SFM's file-only decode against Blastware's XML reports
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 22:45:24 -04:00
serversdownandClaude Opus 5.5 c0d837c14f fix(checker): final-review fixes -- regressions, baselines, the PVS carve-out, the headline
- A matching event that now fails outright is a regression: compare_runs
  walks the previous run's matching rows, so a check that collapses to
  one error row no longer hides every field it used to match.  Counts
  moved are taken over the events both runs checked.
- The default baseline is the newest completed run (run.json written) of
  the same scope; a 2,000-event sample is no baseline for a full run.
  changes.md names the previous run's scope.
- The PVS saturation carve-out now needs Blastware's OORANGE, a channel
  Blastware clamped at SFM's ceiling, and SFM's sum within three channels
  at the ceiling -- an unclipped Sensitive-range channel read 8x can no
  longer let an 8x sum through.
- 'Fields fully matching' needs a match: an always-empty element proves
  nothing.  Events without a report are a line of their own.
- CLAUDE.md: histogram PVS described correctly; 35 sub-minute histograms
  plus 2 one-minute no-mic ones, not '~37 sub-minute'.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 20:11:33 -04:00
serversdownandClaude Opus 5.5 e9d352ad99 docs: the decode checker's first full run; correct the #53 note
First full run over DL2's 70,042 report-paired events (22 min, --jobs 4):
every expectation the spec set holds.  Setup and notes match everywhere;
geophone samples are exact on 6,491/6,524 waveforms across 2016-2026,
the other 33 being the 1.250 in/s range read 8x on SFM's Normal
assumption; every histogram is typed as a waveform without its filename
(#41); the three #53 files are the only waveform time mismatches.  New
findings: histogram PVS, mic psi, mic dB on ~1,000 events, ~37
sub-minute histograms, 26 histogram start dates.

The #53 note is corrected in place: those files decode as waveforms with
Blastware's full sample count; only their time falls back to the footer
start.  scratch/verify_bw_fields_against_xml.py is retired -- the
checker replaces it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:55:07 -04:00
serversdownandClaude Opus 5.5 c8fc649568 tooling(scratch): decode-check run-to-run changes and a one-event view
Each run is diffed against the previous one (--compare-to, or the newest
other run in ~/dl2-archive/checker-runs): changes.md lists every
(event, field) that matched before and no longer does, how many now
match, and how each field's counts moved; summary.md leads with the
regression count.  --file NAME checks one event and prints its table,
writing no run folder.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:30:53 -04:00
serversdownandClaude Opus 5.5 5e85cf1018 tooling(scratch): decode-check summary and grouped detail report
summary.md for Brian: per field, events per verdict, how many fields
fully match, non-matches by event year, carve-out counts.  details.json
for Claude: each non-matching (field, verdict) with the attribute values
its failures concentrate in (>= 10% of the failures; concentrated at
>= 95% of compared events) and example events, each with a one-event
re-run command.  On a 2,000-event sample the event-type mismatches group
as 'type = Full Histogram, 1815/1815' -- #41, named by the report.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:30:00 -04:00
serversdownandClaude Opus 5.5 5b48be3f25 tooling(scratch): run the decode check over the archive in parallel
check_s3_decode.py pairs each Series 3 event file with its _XML.XML
report (deduped by basename -- Sent/ mirrors the root), checks each in a
process pool, and writes results.jsonl.gz and run.json to a run folder
outside the repo.  A missing report or any failure is one row for that
event; the run goes on.  Partial runs by serial, year, type, field
prefix or random sample.

Timing: --sample 2000 --jobs 4 took 35 s on tmi-dev (~20 min projected
for all 70,042).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:28:50 -04:00
serversdownandClaude Opus 5.5 ff7dd908a7 feat(codec): carve-outs for proven Blastware differences -- saturation first
A mismatch becomes 'accepted' only through a written carve-out whose
evidence does not rest on SFM's output.  Saturation: Blastware clamps a
clipped channel to the range maximum and prints OORANGE, while the file
holds counts past full scale.  SFM's value must sit at the ceiling
(r - 0.0006 .. r * 1.01), so a Sensitive-range event read 8x high on
SFM's Normal assumption stays a mismatch; a vector sum is accepted when
a clipped channel under it is at the ceiling.  series_pairs() is now the
one place waveform rows and interval columns are paired.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:27:01 -04:00
serversdownandClaude Opus 5.5 3662d2fac1 feat(codec): compare SFM's file-only decode with Blastware's XML, field by field
Every field the report carries (bar its format version and Blastware's
file name), the notes in order, the job number, the channel list, every
waveform sample and every histogram interval column.  Numbers match at
Blastware's printed precision, halves rounding away from zero; N/A and
empty text are no_reference; >100 needs SFM's above-range flag; OORANGE
is a mismatch unless a carve-out says otherwise.  Waveform rows pair
cells with the channels still running, so channels that end early
(T438HGTZ.B30W) match, and any row-length disagreement is counted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:26:00 -04:00
serversdownandClaude Opus 5.5 3e69a2acdd feat(codec): SFM's side of the decode check, from the event bytes alone
decode_blastware_bytes with no filename and no report: the values SFM
produces today in Blastware's field names, its notes, channels and raw
counts, with its Normal-range assumption kept.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:24:31 -04:00
serversdownandClaude Opus 5.5 52809a5310 feat(codec): parse Blastware's _XML.XML event report
The reference for the Series 3 decode checker: scalars and value units,
channels, the job number, the user notes in order under their
operator-edited labels, waveform rows as printed (ragged where channels
end at different lengths) and histogram intervals.  Seven real DL2
events as fixtures, each covering a case the comparison must handle.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 19:23:43 -04:00
serversdownandClaude Opus 5.5 b023083c79 docs(changelog): T438HGTZ.B30W is not a decoder truncation
Its Tran, Vert and MicL end 3 samples before Long in Blastware's own XML
sample table as well; the setup-field harness compared Tran's length with
the table's row count.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 18:30:27 -04:00
serversdownandClaude Opus 5.5 6bdd140c29 docs(plan): the Series 3 decode checker, task by task -- and T438HGTZ is not truncated
Eight tasks: the XML report parser, SFM's side from the bytes alone, the
field-by-field comparison, carve-outs (saturation first), the parallel
runner, the summary and grouped detail report, run-to-run changes with a
one-event view, and the first full run checked against what is known.

While pinning the plan's test values on real files: T438HGTZ.B30W, called
"3 samples short" by the setup-field harness, matches Blastware exactly.
Its Tran, Vert and MicL end 3 samples before Long, and Blastware's own
sample table does the same -- its last three rows carry only the Long cell.
The harness compared Tran's length with the table's row count.  The spec
now says so, and the plan compares samples row by row by running channel.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 18:30:08 -04:00
serversdownandClaude Opus 5.5 af703808db docs(spec): the Series 3 decode checker -- SFM's file-only decode against Blastware's XML reports
The first of four pieces toward SFM producing everything Blastware reports
from the event file alone: compare every field, sample and histogram
interval with DL2's 70,042 _XML.XML reports (2016-2026), report what
matches, what doesn't and what SFM can't produce yet, grouped for
diagnosis, run after run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 17:47:34 -04:00
serversdownandClaude Opus 5.5 29c8e2b034 docs(changelog): Unreleased — Blastware file-only setup and notes (#44, #45), the XML checker
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 17:30:45 -04:00
serversdownandClaude Opus 5.5 42fe35f3b3 merge: a Blastware file's setup and notes from its recording-setup block (#44, #45)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 17:30:31 -04:00
serversdownandClaude Opus 5.5 6def0d1f41 docs: park the event importer; DL2's XML reports reach back to 2016, its ASCII pairs only to 2025
- README roadmap, Ingestion gaps: a bulk importer for event files on disk,
  parked -- one of the four ways events should reach SFM.
- CLAUDE.md: the 14,338 ASCII pairs were described as "back to 2018"; they
  are all 2025-26 events.  Corrected in place.  DL2's Sent/ _XML.XML files
  are Blastware's full event reports, samples included, for 70,042 events
  back to 2016 -- the reference for proving SFM's file-only decode.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 17:21:26 -04:00
serversdownandClaude Opus 5.5 f46afafdb4 tooling(scratch): check file-only setup and note fields against Blastware's XML reports
verify_bw_fields_against_xml.py decodes each Blastware event file the way
ingest does, without a report, and compares sample rate, record time,
pre-trigger, sample count, the four notes and the job number with the
event's _XML.XML report -- Blastware's full event report, which DL2 kept
for 70,042 events back to 2016 (ASCII reports exist only for 2025-26).
Every disagreement counts against SFM; there is no carve-out list yet.
The first piece of the decode checker.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 17:20:47 -04:00
serversdownandClaude Opus 5.5 b4706a30f0 fix(decode): a Blastware file's setup and notes come from its recording-setup block (#44, #45)
Without a paired ASCII report, a Blastware import stored no sample rate,
the record-type byte as its record time (every waveform read "70 s"), a
pre-trigger and sample count read from STRT bytes that are neither, and
blank notes (the reader stopped at the NUL after each label).

- The recording-setup block is found by structure -- 1c 08, the setup
  name, NUL -- not by the name "Standard Recording Setup", which 37% of
  DL2's files do not use.  One match in each of 70,041 archive files.
- Sample rate (uint16 BE, name-42), pre-trigger (f32 BE, name-36) and
  record time (f32 BE, name-30).  A waveform's sample count is the
  decoded count.  A histogram gets a sample rate only: Blastware reports
  neither a record time nor a pre-trigger for one.
- The setup name and the four user notes by position, as bw_ascii_report
  reads them: the labels are operator-editable ("Seis. Loc:",
  "Location:", "Project: ").
- STRT now yields only the waveform key.

Verified against Blastware's own _XML.XML event reports for the 70,042
DL2 archive events that have one (2016-2026): sample rate 70,042/70,042,
record time 6,524/6,524, pre-trigger 6,484/6,484, notes 70,042/70,042,
sample count 6,523/6,524 (one waveform the decoder ends 3 samples short;
separate).  Events imported with an ASCII report are unchanged -- the
report still overlays.

Not changed: the waveform-time estimate still finds the record time by
the marker; moving it would add a validation constraint for 37% of files
and is to be measured first.  The job number is not read yet (2,997
archive events carry one).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
2026-10-29 17:20:39 -04:00
serversdown a8c91809a6 chore(git): ignore symlinked example-events directory 2026-10-29 15:49:37 -04:00
serversdownandClaude Opus 5.5 184a03a5cd docs(changelog): Unreleased — tier model superseded by Terra-View ADR 0003
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MUHR251NLznsFvPSrfegqL
2026-10-27 18:50:02 -04:00
serversdownandClaude Opus 5.5 560869ed61 merge: the SFM/SDM tier model marked superseded by Terra-View ADR 0003
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MUHR251NLznsFvPSrfegqL
2026-10-27 18:50:02 -04:00