Download scripts/r5_loopguard/lg_gate.sbatch from treoa/turkic-ocr-code: direct link, hf CLI and curl.
- Browser
- Download file 1.55 kB
-
https://huggingface.co/treoa/turkic-ocr-code/resolve/main/scripts/r5_loopguard/lg_gate.sbatch
- Command line
-
hf download hf://treoa/turkic-ocr-code/scripts/r5_loopguard/lg_gate.sbatch
-
curl -L -o lg_gate.sbatch https://huggingface.co/treoa/turkic-ocr-code/resolve/main/scripts/r5_loopguard/lg_gate.sbatch
1.55 kB
| #!/bin/bash | |
| #SBATCH --job-name=loopguard_run | |
| #SBATCH --partition=H100 | |
| #SBATCH --qos=nu-h100 | |
| #SBATCH --gres=gpu:h100:1 | |
| #SBATCH --cpus-per-task=16 | |
| #SBATCH --mem=96G | |
| #SBATCH --time=04:00:00 | |
| #SBATCH --output=/path/to/TURKIC_OCR_DATA/logs/%x_%j.out | |
| #SBATCH --dependency=singleton | |
| # LOOPGUARD-1 (records/R5/LOOPGUARD/design.json): the one GPU job. Copy of scripts/r5_onemodel/onemodel_gate.sbatch with this | |
| # experiment's names. It runs only reviewed code: READY lists the sha256 of every approved file (the code, | |
| # the reused r5_vlma / r5eval / linedet files and the two data pin lists), and the job refuses to start if READY is missing | |
| # or any listed file changed since the review. A resubmission by lg_run_gpu.sh submits THIS file again, so every segment | |
| # passes the same check. The candidate list is DATA/outputs/r5/loopguard/READY_CANDIDATE; it is copied to READY by hand. | |
| set -u | |
| C=/path/to/TURKIC_OCR_CODE | |
| D=/path/to/TURKIC_OCR_DATA | |
| READY=$D/outputs/r5/loopguard/READY | |
| hostname; date -u; nvidia-smi --query-gpu=name,memory.total --format=csv,noheader | |
| if [ ! -f "$READY" ]; then | |
| echo "NOT STARTED: no READY file (code review not finished); exit 3" | |
| exit 3 | |
| fi | |
| cd "$C" || exit 3 | |
| if ! sha256sum -c --quiet "$READY"; then | |
| echo "NOT STARTED: a reviewed file changed after the review; exit 3" | |
| exit 3 | |
| fi | |
| if [ ! -f "$C/scripts/r5_loopguard/lg_run_gpu.sh" ]; then | |
| echo "NOT STARTED: scripts/r5_loopguard/lg_run_gpu.sh missing; exit 3" | |
| exit 3 | |
| fi | |
| echo "review check passed; starting LOOPGUARD-1" | |
| exec bash "$C/scripts/r5_loopguard/lg_run_gpu.sh" | |