ubuntu常见问题处理及各种安装配置

各种安装配置

一键安装ROS

系统换源、安装scode等:

wget http://fishros.com/install -O fishros && . fishros

然后按照终端里面的提示一步一步弄就可以。

安装jtop

sudo apt-get install python3-pip python3-dev -y
sudo -H pip3 install jetson-stats
jtop
sudo systemctl restart jtop.service
reboot

卸载系统自带的opencv

sudo dpkg -l |grep "opencv"
sudo apt purge 
sudo apt autoremove

安装cuda11.2

下载地址

sudo apt install nvidia-cuda-toolkit
wget https://developer.download.nvidia.com/compute/cuda/11.2.0/local_installers/cuda_11.2.0_460.27.04_linux.run
sudo sh cuda_11.2.0_460.27.04_linux.run

sudo gedit ~/.bashrc
export PATH=/usr/local/cuda-11.2/bin${PATH:+:${PATH}}
export LD_LIBRARY_PATH=/usr/local/cuda-11.2/lib64${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
export CUDA_HOME=/usr/local/cuda-11.2
source ~/.bashrc
sudo ldconfig

如果运行nvidia-smi出现no devices were found错误,按照此方法解决。

ubuntu18.04在拯救者电脑上无法调光

sudo add-apt-repository ppa:apandada1/brightness-controller 
sudo apt update 
sudo apt install brightness-controller

ubuntu18.04网络连接失败

  1. 点击网络设置右下角“忘记连接配置”
  2. 参考链接

Velodyne雷达测试命令

配置好后运行如下命令

roslaunch velodyne_pointcloud VLP16_points.launch
rosrun rviz rviz -f velodyne

autoware欧式聚类突然没有效果

映射文件的问题,已经解决

安装Anaconda

配置方法

配置yolov8_ros

配置方法
问题处理
遇到了下面这个问题

Traceback (most recent call last):
  File "/home/hunter/yolov8-ros/src/Yolov8_ros/yolov8_ros/scripts/yolo_v8.py", line 5, in 
    import torch
  File "/home/hunter/.local/lib/python3.7/site-packages/torch/__init__.py", line 217, in 
    _load_global_deps()
  File "/home/hunter/.local/lib/python3.7/site-packages/torch/__init__.py", line 178, in _load_global_deps
    _preload_cuda_deps()
  File "/home/hunter/.local/lib/python3.7/site-packages/torch/__init__.py", line 158, in _preload_cuda_deps
    ctypes.CDLL(cublas_path)
  File "/home/hunter/anaconda3/envs/sg/lib/python3.7/ctypes/__init__.py", line 364, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: /home/hunter/anaconda3/envs/sg/lib/python3.7/site-packages/nvidia/cublas/lib/libcublas.so.11: cannot open shared object file: No such file or directory

这个是版本的问题,解决方法

安装python3.7

sudo apt-get update
sudo apt-get install python3.7
#安装成后的目录在/usr/bin/python3.7,同时将其设置成默认
sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.7 150
sudo update-alternatives --config python

参考链接

启动conda

conda create -n sg python=3.7 
conda activate sg  

在conda中安装pytroch

 conda install pytorch==1.7.1 torchvision==0.8.2 torchaudio==0.7.2 cudatoolkit=11.0 -c pytorch

你可能感兴趣的:(ubuntu,深度学习,python)