Mixformer目标跟踪(pytracking同样适用)运行遇到的问题记录
PreciseRoIPooling问题
Using /home/mingtao/.cache/torch_extensions as PyTorch extensions root…
FAILED: prroi_pooling_gpu_impl.cuda.o
In file included from /usr/local/cuda/include/cuda_runtime.h:83,
from :
/usr/local/cuda/include/crt/host_config.h:139:2: error: #error – unsupported GNU version! gcc versions later than 10 are not supported! The nvcc flag ‘-allow-unsupported-compiler’ can be used to override this version check; however, using an unsupported host compiler may cause compilation failure or incorrect run time execution. Use at your own risk.
问题原因:
error: #error – unsupported GNU version! gcc versions later than 10 are not supported!
由于gcc版本和cuda版本不匹配引起
解决方案:
gcc cuda版本不匹配
从error入手,gcc版本和cuda版本不匹配,因此降低gcc和g++版本将报错问题解决1
https://blog.csdn.net/qq_45779334/article/details/123169473
如何更改gcc版本 2
查看gcc版本
ls /usr/bin/gcc* -l
ls /usr/bin/g++* -l
安装gcc,g++新版本
sudo apt-get install gcc-10
sudo apt-get install g++-10
切换软链接
sudo rm gcc
#新建gcc-5到gcc的软链接
sudo ln -s /usr/bin/gcc-10 /usr/bin/gcc g++
#删除原先的软链接
sudo rm g++
#新建gcc-5到gcc的软链接
sudo ln -s /usr/bin/g++-10 /usr/bin/g++
参考连接:https://blog.csdn.net/qq_45779334/article/details/123169473
https://blog.csdn.net/qqsuiying/article/details/121593987
显卡与cuda版本匹配问题
30系显卡,需要注意cuda版本,使用11.0以上版本,不然算力不匹配
实现多版本cuda
参考链接:https://blog.csdn.net/qq_39637158/article/details/124899569
cuda版本和torch和cudatoolkit版本对应
参考链接:https://pytorch.org/get-started/previous-versions/
UAV123中部分数据集测试没有结果的问题
出现错误
shape ‘[8, 8, 4, 4]’ is invalid for input of size 2048
test的时候,是每200个图片一组测试的,部分代码错误导致问题的出现
修改代码如下:
/lib/test/tracker/mixformer_online.py
99行
# for visualize attention maps
if self.params.vis_attn==1 and self.frame_id % 200 == 0:
attn_weights = []
hooks = []
if self.params.vis_attn==1 and self.frame_id % 200 == 0:
for hook in hooks:
hook.remove()
200->20000问题解决