win10 本地 配置 obbdetection oriented r cnn 失败

前情提要

因为服务器修改代码比较麻烦(要花钱),所以想本地修改完了到时候同步一下直接运行。

1.conda new

先用conda 创建新环境:
这里用win10 ,运行conda powershell promot

conda create -n obbdetection python=3.7 -y
conda activate obbdetection
conda install pytorch==1.6.0 torchvision==0.7.0 cudatoolkit=10.1 -c pytorch
#手动下载github上的zip包,自己解压到路径
#
cd BboxToolkit
pip install -v -e .  # or "python setup.py develop"
cd ..
pip install mmcv-full==1.4.0 -f https://download.openmmlab.com/mmcv/dist/cu101/torch1.6.0/index.html --no-cache-dir

2.遇到错误

安装pip install mmpycocotools
遇到错误

error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/

得去安装个东西,点开,
https://visualstudio.microsoft.com/zh-hans/visual-cpp-build-tools/
找到



虽然我和他选的一样,但是我的右下角显示6GB,我的C盘,拿什么来拯救你。
重启之后继续安装

3.继续conda new

pip install -r requirements/build.txt
pip install mmpycocotools
pip install -v -e .  # or "python setup.py develop"

安装
pip install -v -e . # or “python setup.py develop”
这一句又报错了,下午再改。

cannot import name '_nt_quote_args' from 'distutils.spawn' 

可能是系统的cuda是11.1,而conda创建的是10.1不对了,所以下午创建一个新的环境试试。

cuda 10.1.
等安装完了删掉11.6

现在还是报错,于是网上看到说pytorch版本问题。
https://github.com/pytorch/pytorch/issues/70390
解决方法:

pip install setuptools==59.6

显示我原来的版本是61.2
安装python setup.py develop这一句还是报错,先不管了,后边有问题再说,接着往下安装。
https://blog.csdn.net/ewqapple/article/details/89205067

没安装好mmdet框架不能使用程序。啊这c。

安装mmdet

win10安装mmdet很多坑

1.添加cl.exe到Path

F:\APP\Microsoft Visual Studio\VC\Tools\MSVC\14.29.30133\bin\Hostx64\x64
参考博客
http://t.csdn.cn/m4nwJ

妈的,直接pip install mmdet就行了,白瞎这么多时间。
装完了mmdet也不能用,说oriented rcnn不是库里的东西,报错了。不改了,还是用Linux付费跑吧。时间就是金钱,

文章出处登录后可见!

已经登录?立即刷新

共计人评分,平均

到目前为止还没有投票!成为第一位评论此文章。

(0)
青葱年少的头像青葱年少普通用户
上一篇 2022年5月20日
下一篇 2022年5月20日

相关推荐