Download scripts/r5_ref/ref_step_build.sh from treoa/turkic-ocr-code: direct link, hf CLI and curl.
- Browser
- Download file 661 Bytes
-
https://huggingface.co/treoa/turkic-ocr-code/resolve/main/scripts/r5_ref/ref_step_build.sh
- Command line
-
hf download hf://treoa/turkic-ocr-code/scripts/r5_ref/ref_step_build.sh
-
curl -L -o ref_step_build.sh https://huggingface.co/treoa/turkic-ocr-code/resolve/main/scripts/r5_ref/ref_step_build.sh
661 Bytes
| # R5 REF, step 1 inside the CPU allocation: build the replication split, the preprocessed pool array, the lists and the dictionaries; register rand_test. | |
| # Reads only kohtd_train.tsv and kohtd_val.tsv (and their images). No test manifest, no test image. | |
| set -eu | |
| unset HF_TOKEN HUGGING_FACE_HUB_TOKEN | |
| C=/path/to/TURKIC_OCR_CODE | |
| D=/path/to/TURKIC_OCR_DATA | |
| S=$C/scripts/r5_ref | |
| $C/.venv_ref_tf/bin/python -I $S/ref_build_data.py $C/src/ref/htrflor_1ca49af840dd8cb6d8498c152dbed3cc8441b6b0/src $D/data/processed/r5/manifests $D/data/processed/r5/ref --workers 14 | |
| $C/.venv_ref_tf/bin/python -I $S/ref_register_rand_test.py | |
| ls -la $D/data/processed/r5/ref | |