Datasets:

Modalities:
Text
ArXiv:
llmtcl / scripts /basic_benches_eval.sh
Maple222's picture
Add files using upload-large-folder tool
f9dff7a verified
#!/usr/bin/env bash
MODEL_ROOT="out/pretrain/openllama"
TASKS="arc_easy,arc_challenge,hellaswag,sciq,mmlu,truthfulqa_mc1,truthfulqa_mc2"
BATCH=4
OUT_ROOT="out/eval/openllama_benches"
MONTHS=(2407 2408 2409 2410 2411 2412 2501 2502 2503 2504 2505 2506)
export HF_ALLOW_CODE_EVAL=1
for ((i=4; i<${#MONTHS[@]}; i+=4)); do
for ((j=0; j<4 && (i+j)<${#MONTHS[@]}; j++)); do
m=${MONTHS[$((i+j))]}
gpu=$j
ckpt="${MODEL_ROOT}/${m}/final"
out="${OUT_ROOT}/${m}"
mkdir -p "$out"
echo "[GPU ${gpu}] evaluating month ${m} -> ${out}"
CUDA_VISIBLE_DEVICES=${gpu} \
litgpt evaluate "${ckpt}" \
--batch_size ${BATCH} \
--tasks "${TASKS}" \
--out_dir "${out}" \
> "${out}/log.txt" 2>&1 &
done
wait
done
echo "All months evaluated."