#!/usr/bin/env bash # Download the released ROMA checkpoint (EurekaTian/ROMA, ~16-22GB bf16 safetensors) into the # location the demos expect by default: whole_model/model. # Run this INSIDE the container (working dir /app). Re-runs resume/skip already-downloaded files. set -euo pipefail REPO_ID="${ROMA_HF_REPO:-EurekaTian/ROMA}" TARGET_DIR="${ROMA_MODEL_PATH:-whole_model/model}" export HF_HUB_ENABLE_HF_TRANSFER="${HF_HUB_ENABLE_HF_TRANSFER:-1}" echo "Downloading ${REPO_ID} -> ${TARGET_DIR}" mkdir -p "${TARGET_DIR}" TOKEN_ARGS=() if [[ -n "${HF_TOKEN:-}" ]]; then TOKEN_ARGS=(--token "${HF_TOKEN}") fi huggingface-cli download "${REPO_ID}" \ --local-dir "${TARGET_DIR}" \ --local-dir-use-symlinks False \ "${TOKEN_ARGS[@]}" echo "Done. Checkpoint is at: ${TARGET_DIR}" ls -lh "${TARGET_DIR}" | head -40