HigherHRNet论文复现错误记录

HigherHRNet论文复现错误记录,第1张

HigherHRNet论文复现记录
  • 费劲把环境配好后,运行时报错

费劲把环境配好后,运行时报错
[ WARN:0@263.390] global /io/opencv/modules/imgcodecs/src/loadsave.cpp (239)
 findDecoder imread_('data/coco/images/val2017/000000397133.jpg'): 
 can't open/read file: check file path/integrity
Traceback (most recent call last):
  File "tools/valid.py", line 220, in 
    main()
  File "tools/valid.py", line 153, in main
    for i, (images, annos) in enumerate(data_loader):
  File "/root/.local/lib/python3.6/site-packages/torch/utils/data/dataloader.py",
  line 517, in __next__
    data = self._next_data()
  File "/root/.local/lib/python3.6/site-packages/torch/utils/data/dataloader.py", 
  line 557, in _next_data
    data = self._dataset_fetcher.fetch(index)  # may raise StopIteration
  File "/root/.local/lib/python3.6/site-packages/torch/utils/data/_utils/fetch.py", 
  line 44, in fetch
    data = [self.dataset[idx] for idx in possibly_batched_index]
  File "/root/.local/lib/python3.6/site-packages/torch/utils/data/_utils/fetch.py",
  line 44, in 
    data = [self.dataset[idx] for idx in possibly_batched_index]
  File "/root/HigherHRNet/tools/../lib/dataset/COCODataset.py",
  line 122, in __getitem__
    img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB)
cv2.error: OpenCV(4.5.5) /io/opencv/modules/imgproc/src/color.cpp:182: 
error: (-215:Assertion failed) !_src.empty() in function 'cvtColor'

发现是文件路径问题,应该把数据放在一个单独的文件里面,如下图
20220511

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/langs/919026.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-16
下一篇 2022-05-16

发表评论

登录后才能评论

评论列表(0条)

保存