在运行yolov9时,报错:attributeerror: ‘FreeTypeFont’ object has no attribute ‘getsize’

在网上搜索的结果大部分给出字体不对之类的答案但通过仔细研究,发现该报错的报错原因不是字体不对,而是因为安装了新版本的 Pillow (10)删除了该getsize 功能,降级到 Pillow 9.5 解决了该问题
可以尝试以下方法进行解决:
pip install Pillow==9.5
在运行yolov9时,报错:attributeerror: ‘FreeTypeFont’ object has no attribute ‘getsize’

在网上搜索的结果大部分给出字体不对之类的答案但通过仔细研究,发现该报错的报错原因不是字体不对,而是因为安装了新版本的 Pillow (10)删除了该getsize 功能,降级到 Pillow 9.5 解决了该问题
可以尝试以下方法进行解决:
pip install Pillow==9.5
341
3229
900

被折叠的 条评论
为什么被折叠?