Files
Support-Agent/labeling/auto/etiqueteur/WILDSTRUBEL_2026-09-01/outils/valeurs.py
T
maximeandClaude Opus 5.5 6fbd7510b7 Etiqueteur: October labels for 8 stations; its folder moves to labeling/auto/etiqueteur/, analyses and scripts versioned (D-126)
Labels for CLARIDEN, FLORIDA, JUNGFRAU (gaps 06-20.10, 26.10-01.11), LENZSPITZE,
NIEDERHORN, NORDEND, SNCF01, WILDSTRUBEL. Figures and tool outputs stay out of git.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-03 16:33:41 +01:00

22 lines
839 B
Python

"""error_value (et corr_x, corr_y) de tous les capteurs à des instants donnés (quart d'heure).
Usage : python3 valeurs.py data/WILDSTRUBEL T1,T2,... (T au format 2026-09-01T11:00Z)
"""
import csv, glob, sys
d, ts = sys.argv[1], sys.argv[2].split(',')
days = {t[:10].replace('-', '') for t in ts}
for f in sorted(glob.glob(f"{d}/displacement/*_advanced_*.csv")):
if f[-12:-4] not in days:
continue
out = {}
for r in csv.DictReader(open(f)):
t = r['time_utc']
m = int(t[14:16])
k = f"{t[:10]}T{t[11:13]}:{m - m % 15:02d}Z"
if k in ts:
ev = float(r['error_value'])
mark = '*' if ev > float(r['error_threshold']) else ' '
out.setdefault(k, []).append(f"{r['sensor_name']}={ev:.2f}{mark}")
for k in sorted(out):
print(k, ' '.join(out[k]))