gray_histo_absT_gray_histo_absGrayHistoAbsGrayHistoAbsgray_histo_abs (算子)

名称

gray_histo_absT_gray_histo_absGrayHistoAbsGrayHistoAbsgray_histo_abs — 计算灰度值分布。

签名

gray_histo_abs(Regions, Image : : Quantization : AbsoluteHisto)

Herror T_gray_histo_abs(const Hobject Regions, const Hobject Image, const Htuple Quantization, Htuple* AbsoluteHisto)

void GrayHistoAbs(const HObject& Regions, const HObject& Image, const HTuple& Quantization, HTuple* AbsoluteHisto)

HTuple HImage::GrayHistoAbs(const HRegion& Regions, const HTuple& Quantization) const

HTuple HImage::GrayHistoAbs(const HRegion& Regions, double Quantization) const

HTuple HRegion::GrayHistoAbs(const HImage& Image, const HTuple& Quantization) const

HTuple HRegion::GrayHistoAbs(const HImage& Image, double Quantization) const

static void HOperatorSet.GrayHistoAbs(HObject regions, HObject image, HTuple quantization, out HTuple absoluteHisto)

HTuple HImage.GrayHistoAbs(HRegion regions, HTuple quantization)

HTuple HImage.GrayHistoAbs(HRegion regions, double quantization)

HTuple HRegion.GrayHistoAbs(HImage image, HTuple quantization)

HTuple HRegion.GrayHistoAbs(HImage image, double quantization)

def gray_histo_abs(regions: HObject, image: HObject, quantization: Union[int, float]) -> Sequence[int]

描述

算子 gray_histo_absgray_histo_absGrayHistoAbsGrayHistoAbsGrayHistoAbsgray_histo_abs calculates for the image (ImageImageImageImageimageimage) within RegionsRegionsRegionsRegionsregionsregions the absolute (AbsoluteHistoAbsoluteHistoAbsoluteHistoAbsoluteHistoabsoluteHistoabsolute_histo) ) histogram of the gray values.

The parameter QuantizationQuantizationQuantizationQuantizationquantizationquantization defines, how many frequencies of neighbored gray values are added for one frequency value. The resulting histogram AbsoluteHistoAbsoluteHistoAbsoluteHistoAbsoluteHistoabsoluteHistoabsolute_histo is a tuple, whose indices are mapped on the gray values of the input image ImageImageImageImageimageimage and whose elements contain the frequencies of the gray values. The indices i of the frequency value are calculated from the gray values g and the quantization q as follows:

whereas MIN denotes the minimal gray value, e.g., -128 for an int1 image type. Therefore, the size of the tuple results from the ratio of the full domain of gray values and the quantization, e.g., for images of int2 in . The origin gray value of the signed image types int1 resp. int2 is mapped on the index 128 resp. 32768, negative resp. positive gray values have smaller resp. greater indices.

注意

Note that the operator gray_histo_absgray_histo_absGrayHistoAbsGrayHistoAbsGrayHistoAbsgray_histo_abs only considers the given RegionsRegionsRegionsRegionsregionsregions and ignores any previously set domain of the input image ImageImageImageImageimageimage

执行信息

参数

RegionsRegionsRegionsRegionsregionsregions (输入对象)  region(-array) objectHRegionHObjectHRegionHobject

Region in which the histogram is to be calculated.

ImageImageImageImageimageimage (输入对象)  singlechannelimage objectHImageHObjectHImageHobject (byte / cyclic / direction / int1 / int2 / uint2)

Image the gray value distribution of which is to be calculated.

QuantizationQuantizationQuantizationQuantizationquantizationquantization (输入控制)  number HTupleUnion[int, float]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Quantization of the gray values.

默认值: 1.0

建议值: 1.0, 2.0, 3.0, 5.0, 10.0

限制: Quantization >= 1.0

AbsoluteHistoAbsoluteHistoAbsoluteHistoAbsoluteHistoabsoluteHistoabsolute_histo (输出控制)  histogram-array HTupleSequence[int]HTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Absolute frequencies of the gray values.

结果

算子 gray_histo_absgray_histo_absGrayHistoAbsGrayHistoAbsGrayHistoAbsgray_histo_abs 返回值 2 ( H_MSG_TRUE) if the image has defined gray values and the parameters are correct.当输入为空(无可用输入图像)时可设置行为通过算子 set_system(::'no_object_result',<Result>:)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)set_system("no_object_result",<Result>), the behavior in case of empty region is set via set_system(::'empty_region_result',<Result>:)set_system("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)set_system("empty_region_result",<Result>)。如有必要,则抛出异常。

可能的后继

histo_to_threshhisto_to_threshHistoToThreshHistoToThreshHistoToThreshhisto_to_thresh, gen_region_histogen_region_histoGenRegionHistoGenRegionHistoGenRegionHistogen_region_histo

替代

min_max_graymin_max_grayMinMaxGrayMinMaxGrayMinMaxGraymin_max_gray, intensityintensityIntensityIntensityIntensityintensity, gray_histogray_histoGrayHistoGrayHistoGrayHistogray_histo, gray_histo_rangegray_histo_rangeGrayHistoRangeGrayHistoRangeGrayHistoRangegray_histo_range

另见

disp_imagedisp_imageDispImageDispImageDispImagedisp_image, histo_2dimhisto_2dimHisto2dimHisto2dimHisto2dimhisto_2dim, scale_image_maxscale_image_maxScaleImageMaxScaleImageMaxScaleImageMaxscale_image_max, entropy_grayentropy_grayEntropyGrayEntropyGrayEntropyGrayentropy_gray

模块

基础