interplane.Get Omega
Read in your language

gpu-head-to-head

aien-dev/gpu-head-to-head

Brought by drakestapleton

branch main Branches Tags History

gpu-head-to-head / q35-9b / tools / ref9b.sh

20 lines · 1498 bytes Raw Blame History
1#!/usr/bin/env bash
2# Throwaway: capture LLAMA16 (BF16 GGUF) greedy reference outputs for the correctness gate.
3# Not a timed cell. Holds /tmp/aien-gb10.lock for its few minutes.
4set -u
5H=/home/drakestapleton/handoffs/H2H9B; REPO=/home/drakestapleton/handoffs/HeadToHead/repo
6LLAMA_DIR=/home/drakestapleton/h2h/dl/llama-bin/llama-b11913
7CUDART_DIR=/home/drakestapleton/h2h/dl/cudart-llama-b11913-bin-ubuntu-cuda-13.4-arm64
8mkdir -p $H/results/ref
9exec 9>/tmp/aien-gb10.lock; flock 9
10echo "$(date -u +%Y-%m-%dT%H:%M:%SZ) Main(H2H-9B): GPU-START LLAMA16 reference capture (lock held, <10 min)" >> /home/drakestapleton/handoffs/BOARD.md
11LD_LIBRARY_PATH=$CUDART_DIR:$LLAMA_DIR taskset -c 5-9,15-19 $LLAMA_DIR/llama-server -m /home/drakestapleton/h2h/gguf/q35-9b-bf16.gguf \
12 --host 127.0.0.1 --port 18293 -ngl 999 -fa on -c 32768 -np 1 --jinja < /dev/null > $H/results/ref/server.log 2>&1 &
13SPID=$!
14for _ in $(seq 1 300); do curl -s -m 2 127.0.0.1:18293/v1/models | grep -q q35 && break; sleep 1; done
15taskset -c 0-1 python3 $REPO/bench/bench.py --port 18293 --model q35-9b-bf16 --arm LLAMA16 --round REF --metric agree \
16 --prompts $REPO/prompts/decode.jsonl --concurrency 1 --max-tokens 128 --warmup 0 --reps 16 \
17 --out $H/results/ref/LLAMA16-REF.jsonl --cell-run LLAMA16-REF-agree 2> $H/results/ref/client.log
18echo "client exit $?"
19kill $SPID; wait $SPID 2>/dev/null
20echo "$(date -u +%Y-%m-%dT%H:%M:%SZ) Main(H2H-9B): GPU-END LLAMA16 reference capture" >> /home/drakestapleton/handoffs/BOARD.md