Download recipe/scripts/night2_chain.sh from gowombat/tiny-voca-da: direct link, hf CLI and curl.
- Browser
- Download file 2.5 kB
-
https://huggingface.co/gowombat/tiny-voca-da/resolve/main/recipe/scripts/night2_chain.sh
- Command line
-
hf download hf://gowombat/tiny-voca-da/recipe/scripts/night2_chain.sh
-
curl -L -o night2_chain.sh https://huggingface.co/gowombat/tiny-voca-da/resolve/main/recipe/scripts/night2_chain.sh
2.5 kB
| # Night of 2026-11-25, part 2 (started ~22:05 UTC when scripts/voice_night.sh ended). | |
| # The two voice runs against "too still" vowels are done: T (--texture 20, runs/v3trim-tex) | |
| # and M (--mel-critic, runs/v3trim-mc), both 100k -> 120k from v3-trim 100k. | |
| # The evals that pick a winner run on CPU (scripts/eval_vocoder.sh). The GPUs would sit idle | |
| # meanwhile, so each one does the step a winner needs next: | |
| # 1. vocoder pairs from that voice model (scripts/make_pairs.py, TTS voicing, ~5 min); | |
| # 2. vocoder C (round 7, mel-weight 5, the user's pick) adapted to those pairs, the same | |
| # recipe as round 7: fresh cosine at 5e-5, 500 warm-up steps, 20k steps (132k -> 152k). | |
| # GPU 0 = T, GPU 1 = M. The loser is stopped once the evals are in. | |
| # Run detached in the v3 image: | |
| # docker compose run -d --name tiny-voca-dk-night2 kit-v3 \ | |
| # bash -c "bash scripts/night2_chain.sh > checks/night2-chain.log 2>&1" | |
| set -uo pipefail | |
| cd /opt/kit | |
| stamp() { echo "== stage $1 $(date -u +%FT%TZ)"; } | |
| wait_gpu() { # device index, free bytes needed | |
| until CUDA_VISIBLE_DEVICES=$1 python -c "import sys, torch; sys.exit(0 if torch.cuda.mem_get_info(0)[0] > $2 else 1)" 2>/dev/null | |
| do sleep 30; done; } | |
| run() { # name, gpu | |
| local voice=models/v3trim-$1-s120000.pt pairs=data/vocoder-pairs-${1}120k out=runs/vocoder-r9-C$1 | |
| wait_gpu "$2" 8e9 | |
| stamp "$1-pairs" | |
| CUDA_VISIBLE_DEVICES=$2 python scripts/make_pairs.py --checkpoint "$voice" \ | |
| --annotations data/v3trim-prepared/annotations/train.jsonl --output "$pairs/train" --device cuda | tail -1 | |
| local start=(--init-from runs/vocoder-r7-C/last.pt --fresh-schedule); [[ -f "$out/last.pt" ]] && start=(--resume) | |
| stamp "$1-vocoder" | |
| CUDA_VISIBLE_DEVICES=$2 python -m tiny_voca.train_vocoder "${start[@]}" --prior --prior-high-hz 2500 --prior-high-gain 0.05 \ | |
| --prior-gain-range 0.0 0.1 --mel-weight 5 \ | |
| --manifests data/full-features/train.jsonl --validation data/full-features/validation.jsonl --output "$out" \ | |
| --steps 152000 --learning-rate 5e-5 --warmup 500 --batch 32 --teacher vocos --distill-mode spectrum --distill-weight 4 \ | |
| --pairs "$pairs/train/pairs.jsonl" --pair-fraction 0.7 \ | |
| --device cuda --workers 6 --save-every 1000 --keep-every 4000 >> "$out.log" 2>&1 | |
| local code=$? | |
| [[ $code -eq 0 ]] && cp --update=none "$out/vocoder.pt" "models/vocoder-r9-C$1-s152000.pt" | |
| echo "$1 exit=$code $(date -u +%FT%TZ)" | |
| } | |
| run tex 0 & | |
| run mc 1 & | |
| wait | |
| echo "exit=0 (see the tex/mc exit lines above)" | |