zisan icon indicating copy to clipboard operation
zisan copied to clipboard

按照您的步骤训练报了错误。我之前用您的代码训练1080p的图片是完全可以的,现在我训练1280*960的图片就报这个错误了

Open PixelChen24 opened this issue 3 years ago • 2 comments

cv2.error: OpenCV(4.5.3) C:\Users\runneradmin\AppData\Local\Temp\pip-req-build-q3d_8t8e\opencv\modules\core\src\copy.cpp:1026: error: (-215:Assertion failed) top >= 0 && bottom >= 0 && left >= 0 && right >= 0 && _src.dims() <= 2 in function 'cv::copyMakeBorder'

PixelChen24 avatar Sep 04 '21 07:09 PixelChen24

有以下原因参您参考:

【1】 有时候Yolo算法检测出来的检测框坐标偶尔会在边界出现负数错误,比如[-1,234,54,5],那么你需要输出坐标查到底是哪一个坐标出现问题,并且在出现负数错误的时候检测出来把负数变零

【2】 也可能是没有检测出目标 From JintuZheng

From: @.> Sent: Saturday, September 4, 2021 3:40 PM To: @.> Cc: @.**> Subject: [JintuZheng/zisan] 按照您的步骤训练报了错误。我之前用您的代码训练1080p的图片是完全可以的,现在我训练1280960的图片就报这个错误了 (#1)

cv2.error: OpenCV(4.5.3) C:\Users\runneradmin\AppData\Local\Temp\pip-req-build-q3d_8t8e\opencv\modules\core\src\copy.cpp:1026: error: (-215:Assertion failed) top >= 0 && bottom >= 0 && left >= 0 && right >= 0 && _src.dims() <= 2 in function 'cv::copyMakeBorder'

― You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/JintuZheng/zisan/issues/1, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ALH226OGJQ4UWMKK7YG6UODUAHEPLANCNFSM5DNAVWDA. Triage notifications on the go with GitHub Mobile for iOShttps://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Androidhttps://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

JintuZheng avatar Sep 04 '21 07:09 JintuZheng

好的,感谢指导

PixelChen24 avatar Sep 04 '21 14:09 PixelChen24