File size: 916 Bytes
91ac3cc | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #!/usr/bin/env bash
set -euo pipefail
PROJECT_DIR="${PROJECT_DIR:-/workspace/KAWK50M}"
VENV_DIR="${VENV_DIR:-${PROJECT_DIR}/.venv}"
if [[ ! -d "${PROJECT_DIR}" ]]; then
echo "Project directory not found: ${PROJECT_DIR}" >&2
exit 1
fi
cd "${PROJECT_DIR}"
if [[ ! -x "${VENV_DIR}/bin/python" ]]; then
python -m venv --system-site-packages "${VENV_DIR}"
fi
# Keep the CUDA-enabled PyTorch bundled with the RunPod image available while
# installing this project into an isolated environment (PEP 668 compatible).
source "${VENV_DIR}/bin/activate"
python -m pip install --upgrade pip
python -m pip install -e .
mkdir -p data/raw data/clean data/tokenized artifacts runs
nvidia-smi
python -m scripts.model_info --config configs/model_50m.yaml
echo
echo "Bootstrap complete."
echo "Virtual environment: ${VENV_DIR}"
echo "After tokenizer and token binaries are present, run:"
echo " bash runpod/train_5090.sh"
|