16 lines
892 B
Bash
16 lines
892 B
Bash
#!/bin/bash
|
|||
|
|
# Copies the detectors to WORK/<name>, applies a python replacement (file, old, new) given as triples, then runs the NORDEND range score and the full benchmark of the copy into WORK/<name>/{range,bench}.txt. Args: WORK name [file old new]...
|
||
|
|
set -e
|
||
|
|
W=$1; N=$2; shift 2
|
||
|
|
R=/home/maxime/aimsight-optimizer
|
||
|
|
rm -rf "$W/$N"; mkdir -p "$W/$N"
|
||
|
|
cp -r /home/maxime/aimsight-detectors/scripts /home/maxime/aimsight-detectors/bench "$W/$N/"
|
||
|
|
rm -rf "$W/$N"/*/__pycache__
|
||
|
|
while [ $# -ge 3 ]; do
|
||
|
|
python3 "$R/sessions/NORDEND_2026-08-17T0515_2026-11-07T1400_20261118T1024Z/tools/replace.py" "$W/$N/scripts/$1" "$2" "$3"
|
||
|
|
shift 3
|
||
|
|
done
|
||
|
|
cd "$R"
|
||
|
|
python3 "$W/$N/bench/score.py" data/NORDEND --labels labeling/auto/NORDEND.jsonl --from 2026-08-17 --to 2026-11-08 > "$W/$N/range.txt" 2>&1
|
||
|
|
python3 "$W/$N/bench/regression.py" --labels labeling/auto --data data > "$W/$N/bench.txt" 2>&1
|
||
|
|
echo "done $N"
|