Image Statistics

Tutorials

There are currently no tutorials for ImageStats.

How To Guides

There are currently no how to’s for ImageStats. If there are scenarios that you want us to explain, contact us!

DataEval API

class dataeval.metrics.ImageStats(flags: ImageHash | ImageProperty | ImageVisuals | ImageStatistics | Sequence[ImageHash | ImageProperty | ImageVisuals | ImageStatistics] | None = None)

Calculates various image property statistics

Parameters:

flags ([ImageHash | ImageProperty | ImageStatistics | ImageVisuals], default None) – Metric(s) to calculate for each image per channel - calculates all metrics if None

compute() Dict[str, Any]

Computes the specified measures on the cached values

Returns:

Dictionary results of the specified measures

Return type:

Dict[str, Any]

reset()

Resets the internal metric cache

update(preds: Iterable[ndarray], targets=None) None

Updates internal metric cache for later calculation

Parameters:

batch (Sequence) – Sequence of images to be processed

Channel Statistics

Tutorials

There are currently no tutorials for ChannelStats.

How To Guides

There are currently no how to’s for ChannelStats. If there are scenarios that you want us to explain, contact us!

DataEval API

class dataeval.metrics.ChannelStats(flags: ImageStatistics | None = None)
compute() Dict[str, Any]

Computes the specified measures on the cached values

Returns:

Dictionary results of the specified measures

Return type:

Dict[str, Any]

reset() None

Resets the internal metric cache

update(preds: Iterable[ndarray], targets=None) None

Updates internal metric cache for later calculation

Parameters:

batch (Sequence) – Sequence of images to be processed

Image Flags

flag dataeval.flags.ImageHash(value)

Valid values are as follows:

XXHASH = <ImageHash.XXHASH: 1>
PCHASH = <ImageHash.PCHASH: 2>
flag dataeval.flags.ImageProperty(value)

Valid values are as follows:

WIDTH = <ImageProperty.WIDTH: 1>
HEIGHT = <ImageProperty.HEIGHT: 2>
SIZE = <ImageProperty.SIZE: 4>
ASPECT_RATIO = <ImageProperty.ASPECT_RATIO: 8>
CHANNELS = <ImageProperty.CHANNELS: 16>
DEPTH = <ImageProperty.DEPTH: 32>
flag dataeval.flags.ImageVisuals(value)

Valid values are as follows:

BRIGHTNESS = <ImageVisuals.BRIGHTNESS: 1>
BLURRINESS = <ImageVisuals.BLURRINESS: 2>
MISSING = <ImageVisuals.MISSING: 4>
ZERO = <ImageVisuals.ZERO: 8>
flag dataeval.flags.ImageStatistics(value)

Valid values are as follows:

MEAN = <ImageStatistics.MEAN: 1>
STD = <ImageStatistics.STD: 2>
VAR = <ImageStatistics.VAR: 4>
SKEW = <ImageStatistics.SKEW: 8>
KURTOSIS = <ImageStatistics.KURTOSIS: 16>
ENTROPY = <ImageStatistics.ENTROPY: 32>
PERCENTILES = <ImageStatistics.PERCENTILES: 64>
HISTOGRAM = <ImageStatistics.HISTOGRAM: 128>