-
Notifications
You must be signed in to change notification settings - Fork 4
Setup on WSL (Ubuntu 22.04)
Note: As our team shifts towards Jetson Orin Nano, we think it's better to use Ubuntu 22.04 as our testing environment. However, most of the parts are identical between different versions of Ubuntu, so the following steps should possibly also work on Ubuntu 18.04 and 20.04.
sudo apt install cmake
sudo apt install libboost-all-dev
sudo apt install libprotobuf-dev protobuf-compiler
sudo apt-get install libzbar-dev libzbar0
To install CUDA 12.1 on Ubuntu 22.04, follow the instructions on NVIDIA's website.
Note: It is advised to use network repo method for WSL installation as it's much simpler than the local repo method.
Example Shell Commands (
wget https://developer.download.nvidia.com/compute/cuda/repos/wsl-ubuntu/x86_64/cuda-keyring_1.0-1_all.deb
sudo dpkg -i cuda-keyring_1.0-1_all.deb
sudo apt-get update
sudo apt-get install cuda
To install cuDNN 8.6.0 on Ubuntu 22.04, follow the instructions on NVIDIA's website.
Note: Network repo method doesn't work for cuDNN on WSL. Use local repo method instead.
Assuming you've downloaded cudnn-local-repo-ubuntu2204-8.6.0.163_1.0-1_amd64.deb
to the current directory.
Example Shell Commands (
sudo dpkg -i cudnn-local-repo-ubuntu2204-8.6.0.163_1.0-1_amd64.deb
sudo cp /var/cudnn-local-repo-*/cudnn-local-*-keyring.gpg /usr/share/keyrings/
sudo apt-get update
sudo apt-get install libcudnn8
To install TensorRT 8.5.3 on Ubuntu 22.04, follow the instructions on NVIDIA's website.
Note: Network repo method doesn't work for TensorRT on WSL. Use local repo method instead.
Assuming you've downloaded nv-tensorrt-local-repo-ubuntu2204-8.5.3-cuda-11.8_1.0-1_amd64.deb
to the current directory.
Example Shell Commands (
sudo dpkg -i nv-tensorrt-local-repo-ubuntu2204-8.5.3-cuda-11.8_1.0-1_amd64.deb
sudo cp /var/nv-tensorrt-local-repo-ubuntu2204-8.5.3-cuda-11.8/*-keyring.gpg /usr/share/keyrings/
sudo apt-get update
sudo apt-get install tensorrt
OpenCV must be built from source on Ubuntu 22.04. To install OpenCV 4.7.0, follow the instructions on OpenCV's website.
Example Shell Commands (
# Download and Extract
wget -O opencv.zip https://github.com/opencv/opencv/archive/4.x.zip
unzip opencv.zip
# Create build folder
mkdir -p build && cd build
# CMake build
cmake ../opencv-4.x
# Build with make or ninja
cmake --build .
# Install compiled library
sudo make install