from PIL import Image
from PIL import ImageStat
im1 = Image.open("1.png")
im1_gray = im1.convert("L")
start = ImageStat.Stat(im1_gray)
print(
Python PIL之图片的平均亮度ImageStat
最新推荐文章于 2024-01-04 11:19:02 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)
from PIL import Image
from PIL import ImageStat
im1 = Image.open("1.png")
im1_gray = im1.convert("L")
start = ImageStat.Stat(im1_gray)
print(