Stage 0 complete: walking human detected via RSSI (spread 3->12dB, ~3dB body shadow); windowed analyzer
Some checks are pending
ci / test (push) Waiting to run
ci / track (push) Waiting to run

This commit is contained in:
Zachery Aaron Shores-Chmielewski 2026-08-21 23:57:17 +04:00
parent 47a32ad369
commit 67503f2606
2 changed files with 1631 additions and 0 deletions

1605
dataset/stage0_walk1.csv Normal file

File diff suppressed because it is too large Load diff

26
tools/stage0/analyze.py Executable file
View file

@ -0,0 +1,26 @@
#!/usr/bin/env python3
"""Windowed stats over an RSSI capture CSV (stage 0)."""
import csv
import sys
path = sys.argv[1] if len(sys.argv) > 1 else 'dataset/stage0_walk1.csv'
win = int(sys.argv[2]) if len(sys.argv) > 2 else 10
rows = []
for r in csv.reader(open(path)):
if len(r) == 3 and r[2] != 'dbm':
rows.append((float(r[1]), int(r[2])))
if not rows:
sys.exit('no data rows')
print(f'{path}: {len(rows)} samples, span {rows[-1][0]:.0f}s')
print(' window mean spread std')
for w in range(0, int(rows[-1][0]) + 1, win):
v = [d for t, d in rows if w <= t < w + win]
if not v:
continue
m = sum(v) / len(v)
sd = (sum((x - m) ** 2 for x in v) / len(v)) ** 0.5
sp = max(v) - min(v)
print(f'{w:3d}-{w + win:3d}s {m:6.1f} {sp:5d} {sd:5.2f} '
+ '#' * int(max(1, sp)))