报错:attributeerror: ‘FreeTypeFont‘ object has no attribute ‘getsize‘
在运行yolov5时,报错:attributeerror: 'FreeTypeFont' object has no attribute 'getsize'
在网上搜索的结果大部分给出字体不对。。。之类的答案,
但通过仔细研究,发现该报错的报错原因是版本问题

这是因为安装了新版本的 Pillow (10)删除了该getsize功能,降级到 Pillow 9.5 解决了该问题
pip install Pillow==9.5

浙公网安备 33010602011771号