Last active
July 12, 2023 02:23
-
-
Save ShreyasSkandan/69f727d48f85d34e0e9b26308ade0040 to your computer and use it in GitHub Desktop.
Installing CUDA on Jetson (Manual Installation)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# For latest CUDA 9.0 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/cuda-repo-l4t-9-0-local_9.0.252-1_arm64.deb | |
# For latest CUDNN 7.0.5 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libcudnn7_7.0.5.13-1+cuda9.0_arm64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libcudnn7-dev_7.0.5.13-1+cuda9.0_arm64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libcudnn7-doc_7.0.5.13-1+cuda9.0_arm64.deb | |
# For latest OpenCV 3.3.1 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libopencv_3.3.1_t210_arm64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libopencv-dev_3.3.1_t210_arm64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libopencv-python_3.3.1_t210_arm64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2GA/m892ki/JetPackL4T_32_b196/libopencv-samples_3.3.1_t210_arm64.deb | |
# For host machine CUDA 9.0 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2/pwv346/JetPackL4T_32_b157/cuda-repo-ubuntu1604-9-0-local_9.0.252-1_amd64.deb | |
# For host machine OpenCV 3.3.1 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2/pwv346/JetPackL4T_32_b157/libopencv_3.3.1_amd64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2/pwv346/JetPackL4T_32_b157/libopencv-dev_3.3.1_amd64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2/pwv346/JetPackL4T_32_b157/libopencv-python_3.3.1_amd64.deb | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/3.2/pwv346/JetPackL4T_32_b157/libopencv-samples_3.3.1_amd64.deb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Setup CUDA 8.0 on TX2 | |
# Step 1: Download Jetpack from https://developer.nvidia.com/embedded/jetpack | |
# Step 2: Extract contents of installer | |
bash JetPack-L4T-3.1-linux-x64.run --noexec | |
# Step 3: Run Chooser to generate a repository.json file | |
./Chooser | |
# Step 4: Inside the JSON file, you will find the link to a debian installer of arm64 cuda! | |
# -- Download said version of CUDA | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/006/linux-x64/cuda-repo-l4t-8-0-local_8.0.34-1_arm64.deb | |
# Step 5: Install CUDA 8.0 using dpkg -i | |
sudo dpkg -i cuda-repo-l4t-8-0-local_8.0.34-1_arm64.deb | |
sudo apt update | |
sudo apt search cuda | |
# Step 6: You should see cuda-toolkit-8.0 and a bunch of other related libraries | |
sudo apt install cuda-toolkit-8.0 | |
# Step 7: You can also install the CUDA Samples to sanity check your installer | |
sudo apt install cuda-samples-8.0 | |
# Step 8: Export PATH and LD_LIBRARY variables | |
export PATH=/usr/local/cuda-8.0/bin${PATH:+:${PATH}} | |
export LD_LIBRARY_PATH=/usr/local/cuda-8.0/lib64${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}} | |
# Step 9: Install CUDA Samples | |
# -- go to directory in which you want to install samples and run, | |
cuda-install-samples-8.0.sh . | |
# Step 10: Run deviceQuery | |
cd NVIDIA_CUDA-8.0_Samples/1_Utilities/deviceQuery/ | |
make | |
./deviceQuery | |
# You should see Result = PASS | |
# Other: CUDNN 5.1 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/006/linux-x64/cuDNN-v5.1.zip | |
# Other: OpenCV 2.4 | |
wget http://developer.download.nvidia.com/devzone/devcenter/mobile/jetpack_l4t/006/linux-x64/libopencv4tegra-repo_2.4.13-17-g5317135_arm64_l4t-r24.deb | |
# Check your CUDA and CUDNN installation | |
ldconfig -p | grep cu and grep dnn | |
# Check your OpenCV installation | |
dpkg --list | grep opencv |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
haha thank you. I am using balena to control devices remotely and turns out balena replaces the regular jetpack with its balena OS what makes everything harder!