dataeval.metrics.stats.pixelstats ================================= .. py:function:: dataeval.metrics.stats.pixelstats(images, bboxes = None, per_channel = False) Calculates pixel :term:`statistics` for each image This function computes various statistical metrics (e.g., mean, standard deviation, entropy) on the images as a whole. :param images: Images to perform calculations on :type images: Iterable[ArrayLike] :param bboxes: Bounding boxes in `xyxy` format for each image to perform calculations :type bboxes: Iterable[ArrayLike] or None :returns: A dictionary-like object containing the computed statistics for each image. The keys correspond to the names of the statistics (e.g., 'mean', 'std'), and the values are lists of results for each image or :term:`NumPy` arrays when the results are multi-dimensional. :rtype: PixelStatsOutput .. seealso:: :obj:`dimensionstats`, :obj:`visualstats`, :obj:`Outliers` .. note:: - All metrics are scaled based on the perceived bit depth (which is derived from the largest pixel value) to allow for better comparison between images stored in different formats and different resolutions. .. rubric:: Examples Calculating the statistics on the images, whose shape is (C, H, W) >>> results = pixelstats(stats_images) >>> print(results.mean) [0.2903 0.2108 0.397 0.596 0.743 ] >>> print(results.entropy) [4.99 2.371 1.179 2.406 0.668]