CN101398929B - Method and device for restraining night image noise - Google Patents
Method and device for restraining night image noise Download PDFInfo
- Publication number
- CN101398929B CN101398929B CN200810168365XA CN200810168365A CN101398929B CN 101398929 B CN101398929 B CN 101398929B CN 200810168365X A CN200810168365X A CN 200810168365XA CN 200810168365 A CN200810168365 A CN 200810168365A CN 101398929 B CN101398929 B CN 101398929B
- Authority
- CN
- China
- Prior art keywords
- image
- pixel
- component value
- intermediate images
- threshold
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 32
- 230000000452 restraining effect Effects 0.000 title 1
- 238000012545 processing Methods 0.000 claims abstract description 35
- 210000003746 feather Anatomy 0.000 claims description 26
- 101150061927 BMP2 gene Proteins 0.000 claims description 14
- 230000008569 process Effects 0.000 claims description 9
- 230000000694 effects Effects 0.000 abstract description 8
- 230000010076 replication Effects 0.000 description 4
- 239000003086 colorant Substances 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 230000007704 transition Effects 0.000 description 2
- 230000002087 whitening effect Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012805 post-processing Methods 0.000 description 1
- 230000001629 suppression Effects 0.000 description 1
Images
Landscapes
- Image Processing (AREA)
Abstract
Description
技术领域technical field
本发明涉及图像处理中的图像去噪技术领域,特别涉及一种抑制夜景图像噪声的方法和装置。The invention relates to the technical field of image denoising in image processing, in particular to a method and device for suppressing night scene image noise.
背景技术Background technique
随着数码相机的日益普及,用户对所拍摄的数码照片的效果也提出了更高的要求。由于夜景拍摄时,夜晚光线本身不足,为了保证成像的清晰,一般采用了高灵敏度(ISO)的拍摄手段,虽然满足了希望的清晰要求,但同时也带来了噪声,这是因为数码相机本身所使用器材的局限性,导致拍摄出来的夜景噪声明显,严重影响了成像质量。With the increasing popularity of digital cameras, users have higher requirements for the effects of digital photos taken. Due to the lack of night light itself when shooting night scenes, in order to ensure the clarity of the image, a high-sensitivity (ISO) shooting method is generally used. Although it meets the desired clarity requirements, it also brings noise. This is because the digital camera itself The limitations of the equipment used lead to obvious noise in the night scene, which seriously affects the image quality.
为解决这一问题,用户通常需要采用一些软件来对拍摄到的夜景数码照片进行后期处理,此时对图像整体采用模糊化,明显地去除了噪声,但同时导致了整个图像的模糊化。而且,在后期处理过程中,需要靠用户来调整一系列的复杂参数,才能达到去除拍摄过程中引入的噪声的目的,不但实现起来很不方便,而且也很难达到理想的效果。To solve this problem, users usually need to use some software to post-process the night scene digital photos. At this time, the overall image is blurred, which obviously removes the noise, but at the same time causes the blurring of the entire image. Moreover, in the post-processing process, users need to adjust a series of complex parameters to achieve the purpose of removing the noise introduced in the shooting process, which is not only inconvenient to implement, but also difficult to achieve the desired effect.
发明内容Contents of the invention
有鉴于此,本发明的主要目的在于提供一种抑制夜景图像噪声的方法,能够方便有效地对夜景图像噪声进行抑制。In view of this, the main purpose of the present invention is to provide a method for suppressing night scene image noise, which can suppress night scene image noise conveniently and effectively.
本发明的另一目的在于提供一种抑制夜景图像噪声的装置,能够方便有效地对夜景图像噪声进行抑制。Another object of the present invention is to provide a device for suppressing night scene image noise, which can conveniently and effectively suppress night scene image noise.
为达到上述目的,本发明的技术方案具体是这样实现的:In order to achieve the above object, the technical solution of the present invention is specifically realized in the following way:
一种抑制夜景图像噪声的方法,该方法包括:A method for suppressing night scene image noise, the method comprising:
将原始夜景图像复制两份,得到第一临时图像和第二临时图像;Copying the original night scene image twice to obtain a first temporary image and a second temporary image;
对所述第一临时图像进行阈值处理,得到包含所述原始夜景图像噪声的灰度图像,对所述第二临时图像进行调暗处理,得到第三临时图像;Carrying out threshold processing on the first temporary image to obtain a grayscale image containing the noise of the original night scene image, and performing darkening processing on the second temporary image to obtain a third temporary image;
对所述原始夜景图像以及所述第三临时图像中的每一个像素点上的红R、绿G、蓝B分量,分别按照以下方式进行计算,得到最终所需图像,The red R, green G, and blue B components on each pixel in the original night scene image and the third temporary image are calculated in the following manner to obtain the final required image,
其中,i表示任一像素点;所述bmp[i]表示所述原始夜景图像中的第i个像素点上的R、G或B分量值;所述bmp2[i]表示所述第三临时图像中的第i个像素点上的R、G或B分量值;所述MaskBmp[i]表示所述包含所述原始夜景图像噪声的灰度图像中的第i个像素点的灰度值;result[i]表示计算得到的最终所需图像中的第i个像素点上的R、G或B分量值;所述transparency表示透明度,其取值为一大于等于0且小于等于1的实数;所述*表示乘号,所述-表示减号。Wherein, i represents any pixel; the bmp[i] represents the R, G or B component value on the i-th pixel in the original night scene image; the bmp2[i] represents the third temporary R, G or B component value on the ith pixel in the image; Said MaskBmp[i] represents the grayscale value of the i'th pixel in the grayscale image that contains the noise of the original night scene image; result[i] represents the R, G or B component value on the i-th pixel in the calculated final required image; the transparency represents transparency, and its value is a real number greater than or equal to 0 and less than or equal to 1; The * represents a multiplication sign, and the - represents a minus sign.
一种抑制夜景图像噪声的装置,该装置包括:A device for suppressing night scene image noise, the device comprising:
复制单元,用于将原始夜景图像复制两份,得到第一临时图像和第二临时图像;a copying unit, for copying the original night scene image twice to obtain a first temporary image and a second temporary image;
处理单元,用于对所述第一临时图像进行阈值处理,得到包含所述原始夜景图像噪声的灰度图像,对所述第二临时图像进行调暗处理,得到第三临时图像;A processing unit, configured to perform threshold processing on the first temporary image to obtain a grayscale image containing noise in the original night scene image, and perform darkening processing on the second temporary image to obtain a third temporary image;
第三计算子单元,用于对所述原始夜景图像以及由所述处理单元得到的第三临时图像中的每一个像素点上的R、G、B分量,分别按照以下方式进行计算,得到最终所需图像,The third calculation subunit is used to calculate the R, G, and B components of each pixel in the original night scene image and the third temporary image obtained by the processing unit in the following manner to obtain the final desired image,
其中,i表示任一像素点;所述bmp[i]表示所述原始夜景图像中的第i个像素点上的R、G或B分量值;所述bmp2[i]表示所述第三临时图像中的第i个像素点上的R、G或B分量值;所述MaskBmp[i]表示所述包含所述原始夜景图像噪声的灰度图像中的第i个像素点的灰度值;result[i]表示计算得到的最终所需图像中的第i个像素点上的红R、绿G或蓝B分量值;所述transparency表示透明度,其取值为一大于等于0且小于等于1的实数;所述*表示乘号,所述-表示减号。Wherein, i represents any pixel; the bmp[i] represents the R, G or B component value on the i-th pixel in the original night scene image; the bmp2[i] represents the third temporary R, G or B component value on the ith pixel in the image; Said MaskBmp[i] represents the grayscale value of the i'th pixel in the grayscale image that contains the noise of the original night scene image; result[i] represents the red R, green G or blue B component value on the i-th pixel in the calculated final required image; the transparency represents transparency, and its value is greater than or equal to 0 and less than or equal to 1 The real number; said * represents a multiplication sign, and said - represents a minus sign.
可见,采用本发明的技术方案,充分利用了夜景图像整体采光较少,一般整体呈现黑色的特点,对一定阈值内的像素做专门的处理以确定出夜景图像的噪声,再用原始夜景图像减去所述夜景图像的噪声,在保证图像整体效果不变的情况下,达到合理抑制夜景图像噪声的目的;本发明所述方案可应用于软件中,用户只需点击相应的按键,软件自身即可按照本发明所述方案在后台完成处理,省去了用户调整一系列复杂参数的过程,从而为用户节省了时间和费用,而且处理效果更加理想。It can be seen that the adoption of the technical solution of the present invention fully utilizes the feature that the overall lighting of the night scene image is less, and generally presents black as a whole, and special processing is performed on the pixels within a certain threshold to determine the noise of the night scene image, and then the original night scene image is used to reduce the noise. The noise of the night scene image is removed, and the purpose of reasonably suppressing the noise of the night scene image is achieved while ensuring that the overall effect of the image remains unchanged; the scheme of the present invention can be applied to software, and the user only needs to click the corresponding button, and the software itself will The processing can be completed in the background according to the scheme of the present invention, which saves the user the process of adjusting a series of complex parameters, thereby saving time and cost for the user, and the processing effect is more ideal.
附图说明Description of drawings
图1为本发明抑制夜景图像噪声方法实施例的流程图。FIG. 1 is a flow chart of an embodiment of the method for suppressing night scene image noise in the present invention.
图2为本发明抑制夜景图像噪声装置实施例的组成结构示意图。FIG. 2 is a schematic diagram of the composition and structure of an embodiment of the device for suppressing night scene image noise of the present invention.
具体实施方式Detailed ways
为解决现有技术中存在的问题,本发明针对夜景图像具有一些共有的特点,例如整体采光较少、一般呈现黑色、图像中有一些细节,但是细节多为高光彩色区域、暗部细节不多或者不明显等,提出了一种全新的抑制夜景图像噪声的方案:首先,为原始夜景图像设置一个阈值,通过该阈值确定出原始夜景图像的噪声;然后,将原始夜景图像减去所述噪声即得到了降噪后的夜景图像;该方案在不改变照片本身清晰度的前提下,能方便地对夜景照片中出现的噪声进行有效地抑制,从而使照片达到更完美的效果。In order to solve the problems existing in the prior art, the present invention has some common characteristics for night scene images, such as less overall lighting, generally black, and some details in the image, but the details are mostly high-light color areas, and there are few details in dark parts or Not obvious, etc., proposed a new scheme to suppress the noise of the night scene image: first, set a threshold for the original night scene image, and determine the noise of the original night scene image through the threshold; then, subtract the noise from the original night scene image The noise-reduced night scene image is obtained; under the premise of not changing the sharpness of the photo itself, this scheme can conveniently and effectively suppress the noise in the night scene photo, so that the photo can achieve a more perfect effect.
在介绍具体的实现方案之前,首先介绍一下红绿蓝(RGB)色彩模型的概念。RGB色彩模型是工业界的一种颜色标准,通过对R、G、B三个颜色通道进行变化以及对它们相互之间进行叠加来得到各种各样的颜色,所以,对于图像中的每一个像素点,均可用R、G、B三个分量(通道)来表示。通常,每个分量的取值范围为0~255;这样,当R、G、B分量分别取不同的值时,对应表示的颜色也将不同。比如,纯红色的R分量值为255,G分量值和B分量值均为0;亮红色的R分量值为246,G分量值为20,B分量值为50。Before introducing the specific implementation scheme, first introduce the concept of the red-green-blue (RGB) color model. The RGB color model is a color standard in the industry. Various colors are obtained by changing the three color channels of R, G, and B and superimposing them on each other. Therefore, for each image in the image Pixels can be represented by three components (channels) of R, G, and B. Usually, the value range of each component is 0 to 255; thus, when the R, G, and B components take different values, the corresponding colors will also be different. For example, the R component value of pure red is 255, the G component value and B component value are both 0; the R component value of bright red is 246, the G component value is 20, and the B component value is 50.
基于上述介绍,本发明所述方案的具体实现包括:将原始夜景图像复制两份,得到第一临时图像和第二临时图像;对第一临时图像进行阈值处理,得到包含所述原始夜景图像噪声的灰度图像,对第二临时图像进行调暗处理,得到第三临时图像;将原始夜景图像与第三临时图像以包含所述原始夜景图像噪声的灰度图像为蒙层通过Subtract模式进行合并,得到最终所需图像。Based on the above introduction, the specific implementation of the solution of the present invention includes: copying the original night scene image twice to obtain the first temporary image and the second temporary image; thresholding the first temporary image to obtain the noise containing the original night scene image The grayscale image of the second temporary image is darkened to obtain the third temporary image; the original night scene image and the third temporary image are merged by Subtract mode with the grayscale image containing the noise of the original night scene image as a mask , to get the final desired image.
为使本发明的目的、技术方案及优点更加清楚明白,以下参照附图并举实施例,对本发明进一步详细说明。In order to make the object, technical solution and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and examples.
图1为本发明抑制夜景图像噪声方法实施例的流程图。如图1所示,包括以下步骤:FIG. 1 is a flow chart of an embodiment of the method for suppressing night scene image noise in the present invention. As shown in Figure 1, the following steps are included:
步骤101:将原始夜景图像复制两份,得到第一临时图像和第二临时图像。Step 101: Duplicate the original night scene image twice to obtain a first temporary image and a second temporary image.
如何复制为现有技术,不再赘述。How to copy it as a prior art will not be described in detail.
需要说明的是,本步骤中对原始夜景图像进行复制仅为举例说明,并不用于限制本发明的技术方案。本实施例中,也可以直接对所述原始夜景图像进行下面的处理操作。It should be noted that the copying of the original night scene image in this step is only for illustration and is not intended to limit the technical solution of the present invention. In this embodiment, the following processing operations may also be directly performed on the original night scene image.
步骤102:对第一临时图像进行阈值处理,得到包含原始夜景图像噪声的灰度图像,对第二临时图像进行调暗处理,得到第三临时图像。Step 102: Perform threshold processing on the first temporary image to obtain a grayscale image containing noise in the original night scene image, and perform darkening processing on the second temporary image to obtain a third temporary image.
本步骤操作有两个目的:1)对图像进行阈值处理后,可以得到图像噪声的灰度图像,为后面去除噪声的操作做好了充分的准备;2)由于后面的操作会调整整个图像的亮度,而经过对图像的调暗处理,可以将图像的亮度变得暗一些,因此,再经过后面相关操作后,图像的亮度就可以跟原来的保持一致。This step has two purposes: 1) After the image is thresholded, the grayscale image of the image noise can be obtained, which is fully prepared for the subsequent operation of removing noise; 2) Since the subsequent operation will adjust the entire image Brightness, and after dimming the image, the brightness of the image can be made darker. Therefore, after related operations later, the brightness of the image can be kept consistent with the original.
在本步骤中,对第一临时图像进行阈值处理,得到包含原始夜景图像噪声的灰度图像的具体实现为:In this step, threshold processing is performed on the first temporary image to obtain a grayscale image containing noise in the original night scene image. The specific implementation is as follows:
通过分别比较所述第一临时图像中每一个像素点上的红(R)分量值、绿(G)分量值以及蓝(B)分量值,找出其中最大的分量值,并将所述最大的分量值设为r′;By comparing the red (R) component value, green (G) component value and blue (B) component value on each pixel in the first temporary image respectively, find out the maximum component value, and use the maximum The component value of is set to r′;
对于所述第一临时图像中的每一个r′,按照以下方式进行r分量值计算:For each r' in the first temporary image, the r component value is calculated in the following manner:
其中,定义Threshold为阈值点,Feather为羽化参数,像素值小于Threshold的点黑化,像素值大于Feather的点白化,在[Threshold,Threshold+Feather]范围内,白化是自然过渡的;阈值Threshold和羽化参数Feather是经验值,根据用户反馈和多次调解后得到的,这里的默认值为:Threshold=70,Feather=80;所述r表示计算所述原始夜景图像中每一个像素点上的r′而得到的每一个像素点上的值;所述*表示乘号,所述/表示除号,所述+表示加号,所述-表示减号;Among them, Threshold is defined as the threshold point, and Feather is the feathering parameter. The point with a pixel value smaller than Threshold is blackened, and the point with a pixel value greater than Feather is whitened. Within the range of [Threshold, Threshold+Feather], whitening is a natural transition; threshold Threshold and The feathering parameter Feather is an empirical value, obtained according to user feedback and multiple mediations. The default value here is: Threshold=70, Feather=80; the r means to calculate the r on each pixel in the original night scene image ' and the value on each pixel obtained; the * represents a multiplication sign, the / represents a division sign, the + represents a plus sign, and the - represents a minus sign;
将计算得到的r分量值分别赋值给对应像素点上的R分量、G分量和B分量,得到包含所述原始夜景图像噪声的灰度图像。The calculated r component values are respectively assigned to the R component, G component and B component on the corresponding pixel points to obtain a grayscale image containing the noise of the original night scene image.
对第二临时图像进行调暗处理,得到第三临时图像的具体实现包括:The implementation of dimming the second temporary image to obtain the third temporary image includes:
将所述第二临时图像中的每一个像素点上的R分量值、G分量值和B分量值,分别按照以下方式进行计算:The R component value, the G component value and the B component value on each pixel in the second temporary image are calculated in the following manner:
t=t′-t′*Amount/255,得到所述第三临时图像,t=t'-t'*Amount/255, to obtain the third temporary image,
其中,t′表示所述第二临时图像每一个像素点上的R、G、B分量值,t表示计算得到的所述第三临时图像每一个像素点上的R、G、B分量值;阈值Amount=180;所述*表示乘号,所述/表示除号,所述-表示减号。Wherein, t' represents the R, G, and B component values on each pixel of the second temporary image, and t represents the calculated R, G, and B component values on each pixel of the third temporary image; Threshold Amount=180; the * indicates a multiplication sign, the / indicates a division sign, and the - indicates a minus sign.
步骤103:将原始夜景图像与第三临时图像以包含原始夜景图像噪声的灰度图像为蒙层通过Subtract模式进行合并,得到最终所需图像。Step 103: Merge the original night scene image and the third temporary image by using the grayscale image containing the noise of the original night scene image as a mask in Subtract mode to obtain the final desired image.
本步骤中的Subtract模式会调整整个图像的亮度。The Subtract mode in this step will adjust the brightness of the entire image.
其具体实现包括:Its specific implementation includes:
对所述原始夜景图像以及所述第三临时图像中的每一个像素点上的R、G、B分量,分别按照以下方式进行计算:The R, G, and B components on each pixel in the original night scene image and the third temporary image are calculated in the following manner:
其中,i表示任一像素点;所述bmp[i]表示所述原始夜景图像中的第i个像素点上的R、G或B分量值;所述bmp2[i]表示所述第三临时图像中的第i个像素点上的R、G或B分量值;所述MaskBmp[i]表示所述包含所述原始夜景图像噪声的灰度图像中的第i个像素点的灰度值;result[i]表示计算得到的最终所需图像中的第i个像素点上的R、G或B分量值;所述transparency表示透明度,其取值为一大于等于0且小于等于1的实数;所述*表示乘号,所述-表示减号。Wherein, i represents any pixel; the bmp[i] represents the R, G or B component value on the i-th pixel in the original night scene image; the bmp2[i] represents the third temporary R, G or B component value on the ith pixel in the image; Said MaskBmp[i] represents the grayscale value of the i'th pixel in the grayscale image that contains the noise of the original night scene image; result[i] represents the R, G or B component value on the i-th pixel in the calculated final required image; the transparency represents transparency, and its value is a real number greater than or equal to 0 and less than or equal to 1; The * represents a multiplication sign, and the - represents a minus sign.
本实施例中,当透明度为transparency为1时,按Subtract模式进行合并后的图像的各个像素点上的R、G、B分量值为:In this embodiment, when the transparency is 1, the values of the R, G, and B components on each pixel of the merged image in the Subtract mode are:
则result即为去除噪声后的夜景图像。The result is the night scene image after noise removal.
本发明采用的夜景抑噪方法,只能应用在夜景中,是因为夜景图像中的大部分像素是比较黑的,也就是说R、G、B都比较小。如果R、G、B中的一个或多个像素值较高的话,这个像素就会比较亮。The night scene noise suppression method adopted by the present invention can only be applied in night scenes, because most of the pixels in the night scene images are relatively dark, that is to say, R, G, and B are relatively small. If one or more pixel values in R, G, and B are higher, the pixel will be brighter.
至此,即完成了本发明所述方法实施例中的抑制夜景图像噪声的处理过程。So far, the process of suppressing night scene image noise in the method embodiment of the present invention is completed.
基于上述方法,图2为本发明抑制夜景图像噪声装置实施例的组成结构示意图。如图2所示,该装置包括:Based on the above method, FIG. 2 is a schematic diagram of the composition and structure of an embodiment of the device for suppressing night scene image noise according to the present invention. As shown in Figure 2, the device includes:
复制单元21,用于将原始夜景图像复制两份,得到第一临时图像和第二临时图像;A copying
需要说明的是,本实施例中也可以没有复制单元21,而直接对原始夜景图像进行后面的处理操作。It should be noted that in this embodiment, there may be no copying
处理单元22,用于对所述第一临时图像进行阈值处理,得到包含所述原始夜景图像噪声的灰度图像,对第二临时图像进行调暗处理,得到第三临时图像;The
计算单元23,用于将所述原始夜景图像与所述第三临时图像以所述包含所述原始夜景图像噪声的灰度图像为蒙层通过Subtract模式进行合并,得到最终所需图像。The
其中,复制单元21包括:Wherein, the
待处理子单元211,用于保存原始夜景图像;The pending
复制子单元212,用于对待处理子单元211中的原始夜景图像进行所述的复制。The copying
需要说明的是,由于本实施例中可以没有复制单元21,因此,复制单元21中所包含的待处理子单元211和复制子单元212也可以没有。It should be noted that, since the
处理单元22可具体包括:The
第一处理子单元221,用于对所述第一临时图像进行阈值处理,得到包含所述原始夜景图像噪声的灰度图像,该子处理单元221又包括:The
查找子单元2211,用于找出所述第一临时图像中每一个像素点的红(R)分量值、绿(G)分量值以及蓝(B)分量值中最大的分量值,并将所述最大的分量值设为r′;The
第一计算子单元2212,用于对所述第一临时图像中的每一个r′,按照以下方式进行r分量值计算:The
其中,定义Threshold为阈值点,Feather为羽化参数,像素值小于Threshold的点黑化,像素值大于Feather的点白化,在[Threshold,Threshold+Feather]范围内,白化是自然过渡的;阈值Threshold和羽化参数Feather是经验值,根据用户反馈和多次调解后得到的,这里的默认值为:Threshold=70,Feather=80;所述r表示计算所述第一临时图像中每一个像素点上的r′而得到的每一个像素点上的值;所述*表示乘号,所述/表示除号,所述+表示加号,所述-表示减号;Among them, Threshold is defined as the threshold point, and Feather is the feathering parameter. The point with a pixel value smaller than Threshold is blackened, and the point with a pixel value greater than Feather is whitened. Within the range of [Threshold, Threshold+Feather], whitening is a natural transition; threshold Threshold and The feathering parameter Feather is an empirical value, obtained according to user feedback and multiple mediations, and the default value here is: Threshold=70, Feather=80; the r means to calculate the value of each pixel in the first temporary image The value on each pixel obtained by r'; the * represents a multiplication sign, the / represents a division sign, the + represents a plus sign, and the - represents a minus sign;
赋值子单元2213,用于将第一计算子单元2212计算得到的r分量值分别赋值给对应像素点上的R分量、G分量和B分量,得到包含所述原始夜景图像噪声的灰度图像。The
第二处理子单元222,用于对第二临时图像进行调暗处理,得到第三临时图像,该处理子单元222可以包括:The
第二计算子单元2221,用于将所述第二临时图像中的每一个像素点上的R分量值、G分量值和B分量值,分别按照以下方式进行计算:The
t=t′-t′*Amount/255,得到所述第三临时图像,t=t'-t'*Amount/255, to obtain the third temporary image,
其中,t′表示所述第二临时图像每一个像素点上的R、G、B分量值,t表示计算得到的所述第三临时图像每一个像素点上的R、G、B分量值;阈值Amount=180;所述*表示乘号,所述/表示除号,所述-表示减号。Wherein, t' represents the R, G, and B component values on each pixel of the second temporary image, and t represents the calculated R, G, and B component values on each pixel of the third temporary image; Threshold Amount=180; the * indicates a multiplication sign, the / indicates a division sign, and the - indicates a minus sign.
其中,计算单元23可具体为:Wherein, the
第三计算子单元231,用于对于所述原始夜景图像以及所述第三临时图像中的每一个像素点上的R、G、B分量,分别按照以下方式进行计算:The
其中,i表示任一像素点;所述bmp[i]表示所述原始夜景图像中的第i个像素点上的R、G或B分量值;所述bmp2[i]表示所述第三临时图像中的第i个像素点上的R、G或B分量值;所述MaskBmp[i]表示所述包含所述原始夜景图像噪声的灰度图像中的第i个像素点的灰度值;result[i]表示计算得到最终所需图像中的第i个像素点上的R、G或B分量值;所述transparency表示透明度,其取值为一大于等于0且小于等于1的实数;所述*表示乘号,所述-表示减号。Wherein, i represents any pixel; the bmp[i] represents the R, G or B component value on the i-th pixel in the original night scene image; the bmp2[i] represents the third temporary R, G or B component value on the ith pixel in the image; Said MaskBmp[i] represents the grayscale value of the i'th pixel in the grayscale image that contains the noise of the original night scene image; result[i] represents the calculated R, G or B component value on the i-th pixel in the final required image; the transparency represents transparency, and its value is a real number greater than or equal to 0 and less than or equal to 1; The * represents a multiplication sign, and the - represents a minus sign.
图2所示装置的具体工作流程请参照图1所示方法实施例中的相应说明,此处不再赘述。For the specific working process of the device shown in FIG. 2 , please refer to the corresponding description in the method embodiment shown in FIG. 1 , which will not be repeated here.
由上述实施例可以看出,本发明采用的抑制夜景图像噪声的方法,充分利用了夜景图像整体采光较少,一般整体呈现黑色的特点,对一定阈值内的像素做专门的处理以确定出夜景图像的噪声,再用原始夜景图像减去所述夜景图像的噪声,在保证图像整体效果不变,达到合理抑制夜景图像噪声的目的;本发明所述方案可应用于软件中,用户只需点击相应的按键,软件自身即可按照本发明所述方案在后台完成处理,省去了用户调整一系列复杂参数的过程,从而为用户节省了时间和费用,而且处理效果更加理想。As can be seen from the above-mentioned embodiments, the method for suppressing night scene image noise adopted in the present invention fully utilizes the characteristics that the overall lighting of the night scene image is less, and generally presents black as a whole, and performs special processing on the pixels within a certain threshold to determine the night scene. The noise of the image, and then subtract the noise of the night scene image from the original night scene image, so as to ensure that the overall effect of the image remains unchanged and achieve the purpose of reasonably suppressing the noise of the night scene image; the scheme of the present invention can be applied to software, and the user only needs to click Corresponding keys, the software itself can complete the processing in the background according to the scheme of the present invention, eliminating the need for the user to adjust a series of complex parameters, thereby saving time and cost for the user, and the processing effect is more ideal.
以上所述仅为本发明的较佳实施例而已,并不用以限制本发明,凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention shall be included in the scope of the present invention. within the scope of protection.
Claims (8)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200810168365XA CN101398929B (en) | 2008-10-28 | 2008-10-28 | Method and device for restraining night image noise |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200810168365XA CN101398929B (en) | 2008-10-28 | 2008-10-28 | Method and device for restraining night image noise |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101398929A CN101398929A (en) | 2009-04-01 |
CN101398929B true CN101398929B (en) | 2010-08-11 |
Family
ID=40517461
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN200810168365XA Active CN101398929B (en) | 2008-10-28 | 2008-10-28 | Method and device for restraining night image noise |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101398929B (en) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100289912A1 (en) * | 2009-05-14 | 2010-11-18 | Sony Ericsson Mobile Communications Ab | Camera arrangement with image modification |
CN104091317B (en) * | 2014-06-03 | 2017-05-17 | 天津大学 | Night scene image window mirror reflection effect removing method |
CN105141857B (en) * | 2015-09-21 | 2018-12-11 | 广东欧珀移动通信有限公司 | Image processing method and device |
CN107240081A (en) * | 2017-06-20 | 2017-10-10 | 长光卫星技术有限公司 | The denoising of night scene image and enhancing processing method |
CN110378863A (en) * | 2018-04-10 | 2019-10-25 | 深圳Tcl新技术有限公司 | A kind of uniformity detecting method of display screen, system and storage medium |
CN111369455B (en) * | 2020-02-27 | 2022-03-18 | 复旦大学 | Highlight object measuring method based on polarization image and machine learning |
-
2008
- 2008-10-28 CN CN200810168365XA patent/CN101398929B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN101398929A (en) | 2009-04-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4041687B2 (en) | Method and apparatus for removing flash artifacts | |
TWI704524B (en) | Method and device for image polishing | |
Moroney | Local color correction using non-linear masking | |
JP6395810B2 (en) | Reference image selection for motion ghost filtering | |
TWI464706B (en) | Dark portion exposure compensation method for simulating high dynamic range with single image and image processing device using the same | |
US20150170389A1 (en) | Automatic selection of optimum algorithms for high dynamic range image processing based on scene classification | |
TWI511559B (en) | Image processing method | |
Safonov et al. | Adaptive image processing algorithms for printing | |
CN101398929B (en) | Method and device for restraining night image noise | |
CN112734650A (en) | Virtual multi-exposure fusion based uneven illumination image enhancement method | |
CN101404728B (en) | Method and device for digital image exposure adjustment | |
CN101437169A (en) | Method and apparatus for implementing black and white of color image | |
CN109300101A (en) | A Multi-Exposure Image Fusion Method Based on Retinex Theory | |
CN106570838A (en) | Image brightness optimization method and device | |
Kao | High dynamic range imaging by fusing multiple raw images and tone reproduction | |
Liba et al. | Sky optimization: Semantically aware image processing of skies in low-light photography | |
CN110807735A (en) | Image processing method, image processing device, terminal equipment and computer readable storage medium | |
CN106550227A (en) | A kind of image saturation method of adjustment and device | |
CN106709888B (en) | A kind of high dynamic range images production method based on human vision model | |
CN101399898B (en) | An image processing method and device | |
CN101408974B (en) | An image processing method and device | |
CN107277369A (en) | Image processing method, device, computer-readable recording medium and computer equipment | |
Chung et al. | Under-exposed image enhancement using exposure compensation | |
CN118195976A (en) | A single underwater image enhancement method based on contrast stretching and fusion | |
Zhang et al. | Dualbln: Dual branch lut-aware network for real-time image retouching |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
C41 | Transfer of patent application or patent right or utility model | ||
TR01 | Transfer of patent right |
Effective date of registration: 20170221 Address after: A District No. 9018 building 518057 Guangdong Han innovation city of Shenzhen province Nanshan District high tech park, North Central Avenue, 4 floor 401 Patentee after: Shenzhen thunder network culture Co., Ltd. Address before: 518057 Guangdong, Shenzhen, Nanshan District science and technology in the road, Shenzhen, No. 11, software park, building 7, level 8, two Patentee before: Xunlei Network Technology Co., Ltd., Shenzhen |
|
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20180301 Address after: Nanshan District Guangdong streets of science and technology of Shenzhen city in Guangdong province 518057 two Road No. 11 Shenzhen Software Park Building 7, 8 floor Patentee after: Xunlei Network Technology Co., Ltd., Shenzhen Address before: A District No. 9018 Han innovation building 518057 Shenzhen city Nanshan District high tech park, North Central Avenue, 4 floor 401 Patentee before: Shenzhen thunder network culture Co., Ltd. |