直方图均衡化的应用(高通滤波和直方图均衡化的应用顺序对图像处理的影响)

2023-12-01 15:20:03 :70

直方图均衡化的应用(高通滤波和直方图均衡化的应用顺序对图像处理的影响)

大家好,今天小编来为大家解答以下的问题,关于直方图均衡化的应用,高通滤波和直方图均衡化的应用顺序对图像处理的影响这个很多人还不知道,现在让我们一起来看看吧!

本文目录

高通滤波和直方图均衡化的应用顺序对图像处理的影响

滤波的话,一般低通滤波是平滑,如高斯模糊滤波,那么高通滤波应该是求边界。直方图均衡化主要的用处是将大面积的近似的灰度拉开距离,使看上去更清楚。例如,输入图的灰度区间是 0-20,经过直方图均衡化,灰度分布会变成 0-255. 先 直方图均衡化 再高通滤波,就是先增强,再求边界,有时可能会用到。先高通滤波,再直方图均衡化就不知道要干什么了。对边界增强?如果边界梯度很弱,结果图也会灰度很大,好像没有什么意义。图像处理的特点是没有一种通用方法。一定是在不同场合,针对不同图像,用不同的处理方法或处理顺序。你多看看书,多试试就明白了。

数字图像处理的问题!!均衡化处理的~~~

如果信号是连续的,那么均衡化是很好的方法。但是正是因为数字图像的离散性,会给图像均衡化增强带来很多挑战。且直方图的均衡化只适合解决偏暗的图像。如果要粗略的增强图像,可以采用直方图的规定化。

为什么对一幅数字图进行直方图均衡化处理,然后对处理过的图像再一次进行直方图均衡化不会改变

还是需要从连续信号的角度理解,均衡化一次后连续信号已经是均匀分布的了,均匀分布再做均衡化还是本身.

在离散的数字图像应用上,多次进行直方图均衡化的结果其实和只进行一次直方图均衡化的直方图分布还是有点不一样的(imhist),由于连续概率密度函数退化成离散的概率分布,离散化计算过程中四舍五入或截断会造成精度损失;即便入池,一般我们认为直方图多次与直方图一次效果差不多,只要进行一次直方图均衡化即可.

***

matlab 测试代码:

clear;I = imread(’1.png’);gray = rgb2gray(I);gray1 = histeq(gray);gray2 = histeq(gray1);gray3 = histeq(gray2);figure()subplot(2,1,1); = imhist( gray );plot(x,count);xlim();title(’原始灰度图像的直方图’);subplot(2,1,2); = imhist( gray1 );plot(x1,count1);hold on; = imhist( gray2 );plot(x2,count2); = imhist( gray3 );plot(x3,count3);xlim();legend({’1次histeq’,’2次histeq’,’3次histeq’});sumsqr(count1-count2)sumsqr(count2-count3)

***

用例图片:

1.png

MATLAB输出图像:

含有两个子图的MATLAB Figure

看MATLAB输出图像的子图二,放大细节,可以看到,直方图分布并不是完全一样的(灰度级为4的地方,随着histeq次数不一样,4出现的次数是不相同的 ).

均值滤波器在labwindows/CVI中的应用

IntroductionImage enhancement is the process of making an image more interpretable for a particular application. The techniques are often used instead of classification techniques for feature extraction. Display vs. File EnhancementImage enhancement may be performed:• temporarily, upon the image that is displayed in the Viewer• permanently, upon the image data in the data file.Enhancing a displayed image is much faster than enhancing an image on disk. Spatial Modeling Enhancements(基于组件应用建模)• Graphical models(实习中有练习) Correcting DataEach generation of sensors shows improved data acquisition and image quality over previous generations. However, some anomalies still exist that are inherent to certain sensors and can be corrected by applying mathematical formulas derived from the distortions. In addition, the natural distortion that results from the curvature and rotation of the Earth in relation to the sensor platform produces distortions in the image data, which can also be corrected.Generally, there are two types of data correction: radiometric and geometric. 这些辐射改正和几何改正(非10章之精校正)通常由卫星接收站完成。Radiometric Enhancement(辐射增强)Radiometric enhancement deals with the individual values of the pixels. It differs from spatial enhancement (discussed in “Spatial Enhancement”), which takes into account the values of neighboring pixels.Radiometric enhancements that are applied to one band may not be appropriate for other bands. 简明地说:辐射增强用不涉及像元邻域性的统一变换关系来改变某个波段的 pixel value,。 Histograms concept(我加的小标题)横坐标:pixel value(0-255);纵坐标:某像元值出现的Frequency 直方图是图像最基本的统计数据,它体现图的“调子”(明暗色调反差)。 Contrast StretchingWhen radiometric enhancements are performed on the display device, the transformation of data file values into brightness values is illustrated by the graph of a lookup table.Histograms和graph of a lookup table是分析辐射增强最有用的两种图。Linear and NonlinearThe terms linear and nonlinear, when describing types of spectral enhancement, refer to the function that is applied to the data to perform the enhancement. A piecewise linear stretch uses a polyline function to increase contrast to varying degrees over different ranges of the data, as in Figure 6-3.Linear Contrast StretchFigure 4-5 就是用一种线性变换来进行反差拉伸。注意149页底部有ERDAS提示:A two standard deviation linear contrast stretch is automatically applied to images displayed in the Viewer. Histogram Equalization(直方图均衡化)A nonlinear stretch that redistributes pixel values so that there is approximately the same number of pixels with each value within a range. The result approximates a flat histogram.See figure 6-7(补充:方法来源:累积直方图曲线作为变换关系。)The resulting histogram is not exactly flat. 因为实际制作Histogram Equalization软件,是用差分代替微分(——教材中的Bin)又:评论:最增强反差的方法,但并不等于效果最好。 Histogram Matching(直方图匹配)Histogram matching is the process of determining a lookup table that converts the histogram of one image to resemble the histogram of another. Histogram matching is useful for matching data of the same or adjacent scenes that were scanned on separate days, or are slightly different because of sun angle or atmospheric effects. This is especially useful for mosaicking or change detection(后者指比较同区域两图以发现变化). To achieve good results with histogram matching, the two input images should have similar characteristics:• The general shape of the histogram curves should be similar.• Relative dark and light features in the image should be the same.• For some applications, the spatial resolution should be the same.• The relative distributions of land covers should be about the same.(补充:方法来源:用二者的累积直方图曲线两次变换) Brightness InversionThe brightness inversion functions produce images that have the opposite contrast of the original image. Spatial Enhancement(空间增强)While radiometric enhancements operate on each pixel individually, spatial enhancement modifies pixel values based on the values of surrounding pixels. Spatial enhancement deals largely with spatial frequency, which is the difference between the highest and lowest values of a contiguous set of pixels.See Figure 6-11 Convolution Filtering (卷积过滤)The process of averaging small sets of pixels across an image. It is used to change the spatial frequency characteristics of an image.A convolution kernel(卷积模板) is a matrix that is used to average the value of each pixel with the values of surrounding pixels in a particular way. The numbers (often called coefficients) in the matrix serve to weight this average toward particular pixels. Convolution filtering is one method of spatial filtering. See Figure 6-12convolution相当于上学期GIS课中讲过的Moving windows 活动窗口法之移动平均法。下面讲三种类型的Kernel:Low-Frequency or low-pass Kernels (讲义上放在后的第三种Kernels,这里提到前面先讲 ) This kernel simply averages the values of the pixels, causing them to be more homogeneous. The resulting image looks either more smooth or more blurred, decreases spatial frequency.(补充:两种常用的 Low-Frequency Kernels——均值滤波和中值滤波,前者即滑动平均,后者取模板覆盖的像元值大小排列的中间像元的值。利用中值滤波可滤掉某些像元值异常的点。)Zero-Sum KernelsZero-sum kernels are kernels in which the sum of all coefficients in the kernel equals zero.This generally causes the output values to be:• zero in areas where all input values are equal (no edges)• low in areas of low spatial frequency• extreme in areas of high spatial frequencyTherefore, a zero-sum kernel is an edge detector.The resulting image often consists of only edges and zeros.几种常用的 Zero-Sum Kernels例:罗伯特算子: 索伯尔算子 拉普拉斯算子Zero-sum kernels can be biased to detect edges in a particular direction.其它方向的探测,如: High-Frequency or high-pass KernelsIt has the effect of increasing spatial frequency and serves as edge enhancers. Unlike edge detectors, they highlight edges and do not necessarily eliminate other features.When this kernel is used on a set of pixels, the relative low value gets lower, the relative high value becomes higher.See example of text (page 160-161) .补充: How to derove high-pass Kernels? ——某种算子与原图叠加1、原图“减”拉普拉斯算子拉普拉斯算子:(左-自)-(自-右)+(上-自)-(自-下) 即:原图减拉普拉斯算子:2、原图 + 原图减滑动平均两原图减滑动平均: CrispThe Crisp filter sharpens the overall scene luminance without distorting the interband variance content of the image. This is a useful enhancement if the image is blurred. 在后面讲解主成分变换(Principal Component or PC)方法后回头来理解此段。Wavelet Resolution Mergelow spatial resolution to be sharpened using a co-registered panchromatic image of relatively higher resolution. A primary intended target dataset is Landsat 7 ETM+. Increasing the spatial resolution of multispectral imagery in this fashion is, in fact, the rationale behind the Landsat 7 sensor design.Aside from traditional Pan-Multispectral image sharpening, this algorithm can be used to merge any two images, for example, radar with SPOT Pan. Fusing information from several sensors into one composite image can take place on four levels; signal, pixel, feature, and symbolic. This algorithm works at the pixel level. Wavelet TheoryWavelet-based image reduction is similar to Fourier transform analysis. In the Fourier transform, long continuous (sine and cosine) waves are used as the basis. The wavelet transform uses short, discrete “wavelets” instead of a long wave. Thus the new transform is much more local. The wavelet can be parameterized as a finite size moving window.(165和168页只要知道可通过小波变换可进行不同分辨率图像的融合就行)Algorithm TheorySpectral Enhancement(多光谱变换)The techniques require more than one band of data.处理思路(英文讲义上未解释):辐射增强和空间增强对一个波段或其局部进行变换,多光谱变换则对多波段图像的整体进行变换。具体方法与GIS课中所讲空间统计分析类似。假定有n个变量、m个样点数据,则可组成一个n行、m列的数据矩阵:具有各自地理位置的 样点1 样点2 …… 样点j …… 样点m空间变量 X1X2…Xi …Xn x11 x12 …… x1j …… x1mx21 x22 …… x2j …… x2m… xi1 xi2 …… xij …… xim …xn1 xn2 …… xnj …… xnm同样,我们这里将每一波段视为一维变量,将多波段图像视为多维空间,采用多维空间线性变换的方法,形成新的多维变量,即新的多波段图像。假定图像有m波段,每波段K列L行,共n个像元(n = KL)则m波段图像组成m维向量矩阵:不少人对多光谱变换概念模糊就是因为将此矩阵与图像本身矩阵相混淆,多光谱空间概念对下章讲分类提取也很重要。Spectral Enhancement 就是利用一个变换矩阵A,将原图像(矩阵X)变换为一个新的多维变量或多波段图象(矩阵Y)。即:Y = AX,或下面讲述几种多光谱变换的方法Principal Components Analysis (PCA,主成分分析)This is often used as a method of data compression. It allows redundant data to be compacted into fewer bands—that is, the dimensionality of the data is reduced. The bands of PCA data are noncorrelated and independent, and are often more interpretable than the source data.补充:有关统计概念 nVariance = /n-1(第i波段第p像元) P=1方差是信息丰富程度的一种度量。 nCovariance = /n-1 P=1协方差能体现变量间相似性或重复性,是信息冗余程度的一种度量。为此,协方差矩阵与直方图一样,成为图像处理中的一个基本分析数据和工具。COV = 式中,V ij为第 I 波段与第 j 波段之间的协方差。例:TM图像fj2的协方差矩阵为 1 2 3 4 5 6 71 87.431 50.610 84.522 18.195 96.021 35.029 80.2022 50.610 32.399 53.773 23.158 74.913 22.151 54.7733 84.522 53.773 93.785 30.101 127.842 36.951 95.8054 18.195 23.158 30.101 183.716 191.943 20.116 65.0465 96.021 74.913 127.842 191.943 389.152 62.380 198.1046 35.029 22.151 36.951 20.116 62.380 27.646 43.3807 80.202 54.773 95.805 65.046 198.104 43.380 127.426问题:哪波段信息量最大(小)?哪两波段间信息冗余最大(小)?主成分分析旨在寻求一个矩阵变换Y = AX,使所得新图像Y的协方差矩阵为:式中,V11 》 V 22 》…… 》 V mn,即新图像Y的各波段间的协方差为零,集中了图像大多数方差的前几个波段,分别称为PC1(第一主成分)、PC2、PC3…线性代数表明,以m个特征向量组成的mm方阵,作为变换矩阵A,即可达到上述目的,且变换中新旧图像Y和X的方差总量不变。

以上就是我们为大家找到的有关“直方图均衡化的应用(高通滤波和直方图均衡化的应用顺序对图像处理的影响)”的所有内容了,希望可以帮助到你。如果对我们网站的其他内容感兴趣请持续关注本站。

直方图均衡化的应用(高通滤波和直方图均衡化的应用顺序对图像处理的影响)

本文编辑:admin
Copyright © 2022 All Rights Reserved 威海上格软件有限公司 版权所有

鲁ICP备20007704号

Thanks for visiting my site.