wget https://raw.githubusercontent.com/ROBOTIS-GIT/robotis_tools/master/install_ros_melodic.sh
if your computer has nvidia graphic card and driver, you may have a problem with nouveau (ex: not booted up)
so you have to turn off nouveau.
from: here
sudo gedit /etc/modprobe.d/blacklist-nouveau.conf
blacklist nouveau
blacklist lbm-nouveau
options nouveau modeset=0
alias nouveau off
alias lbm-nouveau off
sudo apt install -y dkms
sudo apt install -y build-essential
sudo apt install linux-headers-$(uname -r)
echo options nouveua modeset=0 | sudo tee -a /etc/modprobe.d/nouveau-kms.conf
sudo update-initramfs -u
sudo reboot
from: here
- find recommended driver for your PC
ubuntu-drivers devices
- install the driver
sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt update
sudo apt install nvidia-driver-[driver#]
sudo reboot
from: here
-
be careful to clarify the compatibility of [GPU / CUDA / CUDA-cuDNN / Pytorch] version
-
my setup: RTX 3060 Ti / CUDA 11.1 / cuDNN 8.5 / 1.8.0+cu111
-
install CUDA 11.1
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-ubuntu1804.pin
sudo mv cuda-ubuntu1804.pin /etc/apt/preferences.d/cuda-repository-pin-600
wget https://developer.download.nvidia.com/compute/cuda/11.1.0/local_installers/cuda-repo-ubuntu1804-11-1-local_11.1.0-455.23.05-1_amd64.deb
sudo dpkg -i cuda-repo-ubuntu1804-11-1-local_11.1.0-455.23.05-1_amd64.deb
sudo apt-key add /var/cuda-repo-ubuntu1804-11-1-local/7fa2af80.pub
sudo apt-get update
sudo apt-get -y install cuda
- If you have a problem kinds of "cuda : Depends: cuda-10-0 (>= 10.0.130)", (from here)
wget https://developer.download.nvidia.com/compute/cuda/11.1.0/local_installers/cuda_11.1.0_455.23.05_linux.run
chmod +x cuda_11.1.0_455.23.05_linux.run
sudo ./cuda_11.1.0_455.23.05_linux.run
- install CUDA-cuDNN from Download cuDNN v8.0.5 (November 9th, 2020), for CUDA 11.1
tar -xzvf cudnn-11.1-linux-x64-v8.0.5.39.tgz
sudo cp cuda/include/cudnn*.h /usr/local/cuda/include
sudo cp cuda/lib64/libcudnn* /usr/local/cuda/lib64
sudo chmod a+r /usr/local/cuda/include/cudnn*.h /usr/local/cuda/lib64/libcudnn*
# check if 'CUDNN_MAJOR 8' is printed
cat /usr/local/cuda/include/cudnn_version.h | grep CUDNN_MAJOR -A 2
# export envrionment variables
echo "export PATH=/usr/local/cuda-11.1/bin${PATH:+:${PATH}}" >> ~/.bashrc
echo "export LD_LIBRARY_PATH=/usr/local/cuda-11.1/lib64:$LD_LIBRARY_PATH" >> ~/.bashrc
source ~/.bashrc
- install PyTorch
pip3 install torch==1.8.0+cu111 torchvision==0.9.0+cu111 torchaudio==0.8.0 -f https://download.pytorch.org/whl/torch_stable.html
# check if PyTorch works normally
python3
>> import torch
>> torch.rand(10).to('cuda')
refered from here
- clone OpenCV/conrtib 3.4 from github
git clone -b 3.4 https://github.com/opencv/opencv.git
git clone -b 3.4 https://github.com/opencv/opencv_contrib.git
- install OpenCV with CUDA, contrib: Ubuntu 18.04
# CUDA_ARCH_BIN=8.6 for RTX 30XX
cmake -D CMAKE_BUILD_TYPE=RELEASE \
-D CMAKE_C_COMPILER=gcc-6 \
-D CMAKE_CXX_COMPILER=g++-6 \
-D CMAKE_INSTALL_PREFIX=/usr/local \
-D OPENCV_GENERATE_PKGCONFIG=YES \
-D WITH_CUDA=ON \
-D CUDA_ARCH_BIN=8.6 \
-D CUDA_ARCH_PTX="" \
-D ENABLE_FAST_MATH=ON \
-D CUDA_FAST_MATH=ON \
-D WITH_CUBLAS=ON \
-D WITH_LIBV4L=ON \
-D WITH_GSTREAMER=ON \
-D WITH_GSTREAMER_0_10=OFF \
-D WITH_QT=ON \
-D WITH_OPENGL=ON \
-D BUILD_opencv_cudacodec=OFF \
-D CUDA_NVCC_FLAGS="--expt-relaxed-constexpr" \
-D WITH_TBB=ON \
-D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules \
../
time make -j1 # important, use only one core to prevent compile error
sudo make install
- install OpenCV with CUDA, contrib: Ubuntu 20.04
# CUDA_ARCH_BIN=8.6 for RTX 30XX
cmake \
-D CMAKE_BUILD_TYPE=RELEASE
-D CMAKE_C_COMPILER=gcc-6 \
-D CMAKE_CXX_COMPILER=g++-6 \
-D CMAKE_INSTALL_PREFIX=/usr/local \
-D OPENCV_GENERATE_PKGCONFIG=YES \
-D WITH_CUDA=ON \
-D CUDA_ARCH_BIN=8.6 \
-D CUDA_ARCH_PTX="" \
-D ENABLE_FAST_MATH=ON \
-D CUDA_FAST_MATH=ON \
-D WITH_CUBLAS=ON \
-D WITH_LIBV4L=ON \
-D WITH_GSTREAMER=ON \
-D WITH_GSTREAMER_0_10=OFF \
-D WITH_QT=ON \
-D WITH_OPENGL=ON \
-D BUILD_opencv_cudacodec=OFF \
-D CUDA_NVCC_FLAGS="--expt-relaxed-constexpr" \
-D WITH_TBB=ON \
../
download and run my shell script install_etc.sh
git clone https://github.com/zinuok/ubuntu_setup.git
chmod +x install_etc.sh
./install_etc.sh
To solve time conflicting problem between Window and Linux,
timedatectl set-local-rtc 1 --adjust-system-clock
- Settings -> Region&Language -> Manage Installed Languages -> Install/Remove Language... then you can see 'Korean'
- reboot
- open the terminal
ibus-setup
- add Hangul in ibus-setup: Input Method -> Add -> ... -> Korean -> Hangul
- add Hangul input source: Settings -> Region&Language -> Add an Input Source
- click 'gear' button
- add transition key input and check 'Start in Hangul mode'
from here
(Though this scripts includes px4 Firmware installation, the lastest Firmware version may not work. If you use the 'Firmware', therefore, download from v1.10.0 branch which is verified => ref this)
cd ~/ubuntu_setup/
chmod +x ubuntu_sim_ros_melodic.sh
bash ubuntu_sim_ros_melodic.sh
from: here
- install plugin
sudo usermod -a -G dialout $USER
sudo apt-get remove modemmanager -y
sudo apt install gstreamer1.0-plugins-bad gstreamer1.0-libav gstreamer1.0-gl -y
- download image file download from here
- execute
chmod +x ./QGroundControl.AppImage
./QGroundControl.AppImage (or double click)
from here
- Genome tweak install
sudo apt-get install -y gnome-tweak-tool
- add repository
sudo add-apt-repository ppa:noobslab/macbuntu
sudo apt-get update
sudo apt-get install -y macbuntu-os-ithemes-v1804
sudo apt-get install -y macbuntu-os-icons-v1804
-
themes
- download from here
- my themes: Mojave-dark
- unzip and copy
tar -xf [fime name] mkdir ~/.themes sudo cp -r [file name] ~/.themes
- apply
open gnome-tweak, go to 'Appearance' tab --> Themes --> Applications
-
icon
- download from here
- my icon: MacBuntu-OSX (which is already installed)
- unzip and copy
tar -xf [fime name] mkdir ~/.icons sudo cp -r [file name] ~/.icons
- apply
open gnome-tweak, go to 'Appearance' tab --> Themes --> Icons
-
cursor
- download from here
- unzip and copy
unzip [fime name]
- apply
open gnome-tweak, go to 'Appearance' tab --> Themes --> Cursor
-
remove annoying 'Undo' pop-up on Nautilus
- refered from here
# if you installed your theme with genome twek, cd .themes cd Mojave-Dark # or navigate to $(YOUR_THE) cd gtk-4.0 # add the following line # .app-notification { padding: 0; margin: -80px 0 0 0; opacity: 0;} sudo gedit gtk.css
-
dock
- plank dock install
sudo apt-get install -y plank sudo add-apt-repository ppa:noobslab/macbuntu && sudo apt update sudo apt-get install -y macbuntu-os-plank-theme-lts-v7
-
add to startup app
tweaks --> Startup Applications --> + -
plank mac theme install
- download from here
- copy
sudo cp -r [file name] /usr/share/plank/themes/
- apply in plank preferences
- plank settings (Ctrl + right click) --> Behaviour --> Dodge maximized window
-
remove original dock
sudo apt remove gnome-shell-extension-ubuntu-dock reboot
-
terminal