File size: 1,030 Bytes
3044426
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
# Sourced by run scripts. Isolated project venv: simulation/.venv (no conda).

SIM_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
PROJECT_ROOT="$(cd "$SIM_ROOT/.." && pwd)"
export SIM_ROOT PROJECT_ROOT

if [ -x "$SIM_ROOT/.venv/bin/python" ]; then
  export PATH="$SIM_ROOT/.venv/bin:$PATH"
  export VIRTUAL_ENV="$SIM_ROOT/.venv"
fi

# Isaac Lab lives under simulation/modules (moved/cloned by setup/00_init_modules.sh).
export ISAACLAB_DIR="$SIM_ROOT/modules/IsaacLab"
export SCRIPTS_DIR="$SIM_ROOT/scripts"
export PYTHONPATH="$SIM_ROOT/source${PYTHONPATH:+:$PYTHONPATH}"
export CHECKPOINTS_DIR="$PROJECT_ROOT/checkpoints"
export DATA_DIR="${DATA_DIR:-$PROJECT_ROOT/data}"
export RUNS_DIR="${RUNS_DIR:-$SIM_ROOT/runs}"

if [ -z "${CUDA_HOME:-}" ]; then
  for _cuda in /app/apps/cuda/12.6.2 /usr/local/cuda; do
    if [ -x "$_cuda/bin/nvcc" ]; then
      export CUDA_HOME="$_cuda"
      export PATH="$CUDA_HOME/bin:$PATH"
      break
    fi
  done
  unset _cuda
fi
export CUDA_VISIBLE_DEVICES="${CUDA_VISIBLE_DEVICES:-0}"