代码报错整理

OpenCV(4.1.0) /io/opencv/modules/imgproc/src/color.cpp:182: error: (-215:Assertion failed) !_src.empty() in function ‘cvtColor’

读取图片的路径不对,更改路径后便正确
我的是在votdataset.py中读取图片中出错,数据集是图片直接在序列文件夹中,然而代码中是图片在序列文件夹/color/下,因此对照自己的数据集进行更正即可
frames = [’{base_path}/{sequence_path}/color/{frame:0{nz}}.{ext}’.format(base_path=self.base_path,
sequence_path=sequence_path, frame=frame_num, nz=nz, ext=ext)
for frame_num in range(start_frame, end_frame+1)]
我直接把color去掉就对了。

ModuleNotFoundError: No module named ‘modules’

File “run_tracker.py”, line 17, in
from modules.model import MDNet, BCELoss, set_optimizer
ModuleNotFoundError: No module named ‘modules’
第二次遇到这个问题,我真是猪脑子,以为是我配置的环境的问题,各种install,最后import的时候都有呀,,,其实不是,在run_tracker.py代码中调用了modules文件中的代码,可是我进入了tracking目录,肯定找不到modules, 所以要到和modules同一个目录下,这样运行就对了

Strat Failed:Failed to initialize graphics environment

这是我第n次启动pycharm遇到的问题,第一次我用的是./pycharm.sh命令,然后闪了一下没有进去,师兄让我换sh pycharm.sh命令,奇迹般的进去了;第二次又进不去了,报错如下,师兄说试试bash pycharm.sh命令,真的就可以了;第三次又遇到和第二次的错误,这下命令都试完了,怎么办呢?我跳出了tmux返回到原来的shell环境,就可以了。我不知道问什么,百度了也无果,如果哪位小伙伴知道了,欢迎留言。
在这里插入图片描述

pycharm already running

查看运行pycharm的进程
ps u # ps命令用于显示当前进程 (process) 的状态,这里可以看到对应命令中的PID
杀死进程
kill -9 PID

OMP: Error #13: Assertion failure at z_Linux_util.cpp(2361).

OMP: Hint Please submit a bug report with this message, compile and run commands used, and machine configuration info including native compiler and operating system versions. Faster response will be obtained by including all program sources. For information on submitting this issue, please see http://www.intel.com/software/products/support/.
谷歌一下,得到multi-gpu training problem,但是我用的是多线程呢,有点没懂,给出的解决方案为:
So the suggested solution would be downgrading the intel-openmp version by
conda install -y intel-openmp-2019.4
我没有试,直接注释了,下次再看

DeprecationWarning:‘imsave’ is deprecated! ‘imsave’ is deprecated in SciPy 1.0.0 ,and will be removed in 1.2.0

在这里插入图片描述
use ‘imageio.imwrite’ instead 所以直接安装imageio 然后导入即可
在这里插入图片描述

ValueError: Wrong number of columns at line 496

这里不得不说计算机的严谨,真的是超赞,少一个逗号都会报错
报错的代码为:

ground_truth_rect=np.loadtxt(str
评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值