‘module‘ object has no attribute ‘fromarray‘
目的:调用 PIL 中的 Image 的 fromarray出现问题环境:PyCharm2020 和 python2.7 导入pillow6.2.2出现的问题:运行到 img = Image.fromarray(numpy_image, ‘RGB’) 报错: 'module' object has no attribute 'fromarray'解决方案:将导入 import PIL as Image 改为 from PIL import Image...
原创
2022-05-20 11:01:28 ·
459 阅读 ·
0 评论