发布于 2015-09-11 16:10:16 | 159 次阅读 | 评论: 0 | 来源: 网络整理

The ImageStat module calculates global statistics for an image, or for a region of an image.

class PIL.ImageStat.Stat(image_or_list, mask=None)

Calculate statistics for the given image. If a mask is included, only the regions covered by that mask are included in the statistics. You can also pass in a previously calculated histogram.

参数:
  • image – A PIL image, or a precalculated histogram.
  • mask – An optional mask.
extrema

Min/max values for each band in the image.

count

Total number of pixels.

sum

Sum of all pixels.

sum2

Squared sum of all pixels.

pixel

Average pixel level.

median

Median pixel level.

rms

RMS (root-mean-square).

var

Variance.

stddev

Standard deviation.

最新网友评论  共有(0)条评论 发布评论 返回顶部

Copyright © 2007-2017 PHPERZ.COM All Rights Reserved   冀ICP备14009818号  版权声明  广告服务