feat(decode): over range inside a histogram's intervals, as in the event
Inside an interval the rule is the event's: a peak past 2,000 units (the mic in counts) is Blastware's OORANGE, and the interval's vector sum is OORANGE when any geophone is. DL2 (2026-11-09): numeric up to 1,846 (geophones) / 1,414 (mic), OORANGE from 2,001; vector sums 16 / 16 OORANGE with a geophone over, 2,862 / 2,862 numeric without. event_file_io.over_full_scale(count, channel); the checker renders those interval cells as OORANGE. The saturation carve-out compares SFM's own words properly (_differs): an OORANGE from SFM never counts as saturation, and an OORANGE equal to Blastware's is not a difference. Its interval tests run on the numeric values it used to see. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01ALX2R8pghDaZuti9U7mEE9
This commit is contained in:
1 parent
836c9e864b
commit
e25784d9db
4 files changed
+54
-10
No files matched your search
@@ -1131,6 +1131,15 @@ _SUMMARY_CHANNEL_LEN = 21 # the payload; the record is 22 with its id
|
||||
_SUMMARY_FULL_SCALE = 2000
|
||||
|
||||
|
||||
def over_full_scale(count: int, channel: str) -> bool:
|
||||
"""Whether a decoded peak passes full scale: Blastware's OORANGE. A geophone
|
||||
count is in ADC counts (16 to the unit), the mic's in its own. The same rule
|
||||
holds inside a histogram's intervals: numeric up to 1,846 / 1,414, OORANGE
|
||||
from 2,001 (DL2, 2026-11-09)."""
|
||||
per_unit = 1 if channel == "MicL" else _HIST_GEO_COUNTS_PER_UNIT
|
||||
return abs(count) > _SUMMARY_FULL_SCALE * per_unit
|
||||
|
||||
|
||||
def _unit_summary(chain: dict[int, bytes]) -> Optional[dict]:
|
||||
"""The unit's per-channel event summary from a record chain:
|
||||
{"pvs_sample": int, "Tran": {...}, ...}, each channel {"min", "max",
|
||||
|
||||
Reference in new issue
Block a user