You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

34 lines
1.2 KiB

#!/bin/bash
export CUDA_HOME=/usr/local/cuda-11.8
export PATH=${CUDA_HOME}/bin:${PATH}
export LD_LIBRARY_PATH=${CUDA_HOME}/lib64:${LD_LIBRARY_PATH}
# Exit on error
# set -e # Commented out to allow checking specific error codes if needed
# Set CUDA environment (this part will likely be overridden or become redundant)
if [ -d "/usr/local/cuda" ]; then # This might point to a different version
export CUDA_HOME_DETECTED=/usr/local/cuda
echo "System default CUDA found at $CUDA_HOME_DETECTED (might be different from enforced $CUDA_HOME)"
elif [ -d "/usr/lib/cuda" ]; then
export CUDA_HOME=/usr/lib/cuda
echo "CUDA environment set to $CUDA_HOME"
else
echo "CUDA not found. The project requires CUDA to run."
echo "Please install CUDA and try again."
exit 1
fi
# Set LibTorch library path
if [ -d "$HOME/libtorch" ]; then
export LD_LIBRARY_PATH=$HOME/libtorch/lib:$LD_LIBRARY_PATH
echo "LibTorch library path set to $HOME/libtorch/lib"
elif [ -d "/usr/local/libtorch" ]; then
export LD_LIBRARY_PATH=/usr/local/libtorch/lib:$LD_LIBRARY_PATH
echo "LibTorch library path set to /usr/local/libtorch/lib"
fi
# Run the demo
echo "Starting tracking demo..."
./bin/tracking_demo