AttributeError: module 'numpy' has no attribute 'float'.
`np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations. Did you mean: 'cfloat'?
这是pycharm给的报错原因,笔者查了相关资料,发现都太麻烦了,仔细看错误,会发现系统推荐我们使用np.float64 这种用法,所以我们先定位到np.float相关代码处,如下图所示:
文章来源:https://www.toymoban.com/news/detail-643575.html
重新运行demo文件,成功 文章来源地址https://www.toymoban.com/news/detail-643575.html
到了这里,关于最近复现deepsort,发现run demo 出现错误module ‘numpy‘ has no attribute ‘float‘.的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!