Last active
September 3, 2023 13:42
-
-
Save JihoChoi/06f73fe42ae9eba417176acb34404b98 to your computer and use it in GitHub Desktop.
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
# Install | |
- https://developer.nvidia.com/ | |
- https://youtu.be/UhuK9ShIpf8 | |
nvidia-smi | |
sudo nvidia-persistenced --persistence-mode # when nvidia-smi hand | |
lshw -class display | |
lspci | grep -i nvidia | |
sudo vim /etc/profile.d/cuda.sh | |
# append | |
- export PATH=$PATH:/usr/local/cuda/bin | |
- export CUDADIR=/usr/local/cuda | |
sudo chmod +x /etc/profile.d/cuda.sh | |
sudo vim /etc/ld.so.conf | |
# append | |
- /usr/local/cuda/lib64 | |
# reboot | |
nvcc --version | |
➜ ~ python3 --version | |
Python 3.6.8 | |
➜ ~ nvcc --version | |
nvcc: NVIDIA (R) Cuda compiler driver | |
Copyright (c) 2005-2019 NVIDIA Corporation | |
Built on Sun_Jul_28_19:07:16_PDT_2019 | |
Cuda compilation tools, release 10.1, V10.1.243 | |
# https://pytorch.org/get-started/locally/ | |
>>> import torch | |
>>> torch.__version__ | |
'1.3.0' | |
>>> torch.version.cuda | |
'10.1.243' | |
>>> torch.cuda.device(0) | |
<torch.cuda.device object at 0x7f50f21d22b0> | |
>>> torch.cuda.device_count() | |
1 | |
>>> torch.cuda.get_device_name(0) | |
'GeForce GTX 1060 6GB' | |
>>> torch.cuda.is_available() | |
True | |
export PATH=/usr/local/cuda-10.2/bin:$PATH | |
nvidia-smi | |
nvcc --version | |
nvcc --version | |
nvcc: NVIDIA (R) Cuda compiler driver | |
Copyright (c) 2005-2019 NVIDIA Corporation | |
Built on Wed_Oct_23_19:24:38_PDT_2019 | |
Cuda compilation tools, release 10.2, V10.2.89 | |
Python 3.6.9 (default, Nov 7 2019, 10:44:02) | |
[GCC 8.3.0] on linux | |
Type "help", "copyright", "credits" or "license" for more information. | |
>>> import torch | |
>>> torch.version.cuda | |
'10.1.243' | |
>>> torch.cuda.device_count() | |
File "<stdin>", line 1 | |
torch.cuda.device_count() | |
^ | |
IndentationError: unexpected indent | |
>>> torch.cuda.device_count() | |
8 | |
>>> exit | |
Use exit() or Ctrl-D (i.e. EOF) to exit | |
>>> exit() | |
(env) ➜ point-cloud-inference git:(master) ✗ python | |
Python 3.6.9 (default, Nov 7 2019, 10:44:02) | |
[GCC 8.3.0] on linux | |
Type "help", "copyright", "credits" or "license" for more information. | |
>>> import torch | |
>>> torch.__version__ | |
'1.3.1' | |
>>> torch.version.cuda | |
'10.1.243' | |
>>> torch.cuda.device_count() | |
8 | |
>>> torch.cuda.device(0) | |
<torch.cuda.device object at 0x7feac34b8320> | |
>>> torch.cuda.get_device_name(0) | |
'GeForce GTX 1080 Ti' | |
>>> torch.cuda.is_available() | |
True | |
# ------------------------- | |
# Errors, Uninstall, Remove | |
# ------------------------- | |
sudo dpkg --configure -a | |
Errors were encountered while processing: | |
cuda-libraries-dev-10-2 | |
cuda-visual-tools-10-2 | |
cuda-samples-10-2 | |
cuda-toolkit-10-2 | |
cuda-10-2 | |
cuda-documentation-10-2 | |
cuda | |
cuda-tools-10-2 | |
sudo apt-get remove --dry-run cuda | |
# software center | |
gnome-software | |
software-properties-gtk | |
sudo ln -s cuda-10.1 cuda | |
sudo apt-get install --fix-broken | |
// https://appuals.com/fix-unmet-dependencies-error-ubuntu/ | |
sudo apt-get autoremove --purge cuda | |
sudo add-apt-repository --remove ppa:someppa/ppa | |
sudo apt-get clean | |
sudo apt-get autoclean | |
sudo prime-select intel | |
sudo apt-get -f install | |
# REMOVE unmet dependencies | |
bash | |
sudo apt-get --purge remove 'cuda*' | |
sudo apt-get autoremove --purge 'cuda*' | |
sudo rm -rf /usr/local/cuda | |
# sudo rm -rf /usr/local/cuda-10.0 | |
dpkg --audit | |
sudo dpkg --remove --force-all cuda-libraries-dev-10-2 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Setup