깃허브 링크
[https://github.com/XLearning-SCU/2022-CVPR-AirNet]
비, 안개, 노이즈 상황을 제거해주는 AI 모델
환경 세팅
yaml 파일을 통한 환경 세팅
airnet의 그래픽 카드와 현재 진행 중인 그래픽카드가 다르기에 이에 맞게 재 설치 필요
pip uninstall torch torchvision torchaudio -y
pip install torch==1.12.1+cu113 torchvision==0.13.1+cu113 torchaudio==0.12.1 --extra-index-url https://download.pytorch.org/whl/cu113
pip uninstall mmcv-full -y
pip install mmcv-full==1.6.0 -f https://download.openmmlab.com/mmcv/dist/cu113/torch1.12.0/index.html
export CUDA_HOME=$CONDA_PREFIX
export PATH=$CUDA_HOME/bin:$PATH
export LD_LIBRARY_PATH=$CUDA_HOME/lib64:$LD_LIBRARY_PATH
pip config set global.trusted-host pypi.org
pip config set global.trusted-host pypi.python.org
pip config set global.trusted-host files.pythonhosted.org
pip config set global.trusted-host download.openmmlab.com
ros2_ws/src/yolo_ros
cd AI_test/ros2_ws/src
git clone https://github.com/mgonzs13/yolo_ros.git
pip3 install -r yolo_ros/requirements.txt
이 경우 conda 같은 가상환경이 아닌 기본 환경에 깔림
cd ..
sudo rosdep init
rosdep update
source /opt/ros/humble/setup.bash
pip install empy==3.3.4
pip install catkin_pkg lark
rosdep install --from-paths src --ignore-src -r -y
colcon build
pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
pip3 install ultralytics