• 做数据集增强时,训练一半出现IndexError: tuple index out of range这种错误,不知道怎么改,有神仙赐教一下嘛?


    在用YOLOv5做图像训练时,首先做了数据集的增强,但是增强中出现了如下的错误
    首先出现这样的警告
    (A:/stdy py37-g/agu_img.py:153: DeprecationWarning: An exception was ignored while fetching the attribute __array_interface__ from an object of type ‘JpegImageFile’. With the exception of AttributeError NumPy will always raise this exception in the future. Raise this deprecation warning to see the original exception. (Warning added NumPy 1.21)
    img = np.array(img)
    ![Alt]在这里插入图片描述
    然后出现这样报错,就很懵逼,具体报错如下,不知道怎么下手改
    A:/stdy py37-g/agu_img.py:153: DeprecationWarning: An exception was ignored while fetching the attribute __array_interface__ from an object of type ‘JpegImageFile’. With the exception of AttributeError NumPy will always raise this exception in the future. Raise this deprecation warning to see the original exception. (Warning added NumPy 1.21)
    img = np.array(img)
    Traceback (most recent call last):
    File “”, line 1, in
    File “A:\PyCharm 2019\helpers\pydev_pydev_bundle\pydev_umd.py”, line 197, in runfile
    pydev_imports.execfile(filename, global_vars, local_vars) # execute the script
    File “A:\PyCharm 2019\helpers\pydev_pydev_imps_pydev_execfile.py”, line 18, in execfile
    exec(compile(contents+“\n”, file, ‘exec’), glob, loc)
    File “A:/stdy py37-g/agu_img.py”, line 161, in
    bbs_aug = seq_det.augment_bounding_boxes([bbs])[0]
    File “A:\Anaconda3\envs\pytorch_gpu\lib\site-packages\imgaug\augmenters\meta.py”, line 1183, in augment_bounding_boxes
    hooks=hooks
    File “A:\Anaconda3\envs\pytorch_gpu\lib\site-packages\imgaug\augmenters\meta.py”, line 645, in augment_batch_
    hooks=hooks)
    File “A:\Anaconda3\envs\pytorch_gpu\lib\site-packages\imgaug\augmenters\meta.py”, line 3127, in augment_batch
    hooks=hooks
    File “A:\Anaconda3\envs\pytorch_gpu\lib\site-packages\imgaug\augmenters\meta.py”, line 645, in augment_batch_
    hooks=hooks)
    File “A:\Anaconda3\envs\pytorch_gpu\lib\site-packages\imgaug\augmenters\flip.py”, line 1016, in augment_batch
    height = bbsoi.shape[0]
    IndexError: tuple index out of range

    求各路大神赐教

  • 相关阅读:
    【DataRoom】- 基于VUE的开源的大屏可视化设计器
    GB28181视频监控国标平台EasyGBS如何进行服务迁移?
    Linux编程:定时器setitimer
    浅谈一下Android开发项目组件化之后发布到远程仓库的相关内容
    Python排序:冒泡,选择,插入,希尔,归并,快速
    html实现竖直步骤条
    个人小程序申请制作流程
    TCP(三次握手和四次挥手)与UDP特点、概念、区别
    单目标应用:猎豹优化算法(The Cheetah Optimizer,CO)求解微电网优化MATLAB
    【多线程和锁】
  • 原文地址:https://blog.csdn.net/weixin_44386584/article/details/128085426