CN108124141A - A kind of image processing method and device - Google Patents

A kind of image processing method and device Download PDF

Info

Publication number
CN108124141A
CN108124141A CN201711352453.0A CN201711352453A CN108124141A CN 108124141 A CN108124141 A CN 108124141A CN 201711352453 A CN201711352453 A CN 201711352453A CN 108124141 A CN108124141 A CN 108124141A
Authority
CN
China
Prior art keywords
pixel
channel values
value
area
passages
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.)
Granted
Application number
CN201711352453.0A
Other languages
Chinese (zh)
Other versions
CN108124141B (en
Inventor
凌晨
马鑫
方伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN201711352453.0A priority Critical patent/CN108124141B/en
Publication of CN108124141A publication Critical patent/CN108124141A/en
Priority to EP18868765.1A priority patent/EP3688981B1/en
Priority to PCT/CN2018/110341 priority patent/WO2019076278A1/en
Application granted granted Critical
Publication of CN108124141B publication Critical patent/CN108124141B/en
Priority to US16/852,575 priority patent/US11399167B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/10Cameras or camera modules comprising electronic image sensors; Control thereof for generating image signals from different wavelengths
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N9/00Details of colour television systems
    • H04N9/64Circuits for processing colour signals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N9/00Details of colour television systems
    • H04N9/64Circuits for processing colour signals
    • H04N9/646Circuits for processing colour signals for image enhancement, e.g. vertical detail restoration, cross-colour elimination, contour correction, chrominance trapping filters

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Color Television Image Signal Generators (AREA)
  • Color Image Communication Systems (AREA)

Abstract

This application discloses a kind of image processing method and device, including:Determine the first pixel pending in pending image and the first area centered on first pixel and second area, the first area is less than the second area;It determines the pixel for meeting first condition in the first area, according to the average value of the difference between the saturation infromation of the pixel for meeting first condition and predetermined threshold value, determines corresponding first weight in the first area;According to corresponding first weight in the first area, the corresponding U passages average value of U channel values and the first area to first pixel is weighted average, obtain the false colour precorrection value of the U passages of first pixel, the corresponding V passages average value of V channel values and the first area to first pixel is weighted averagely, obtains the false colour precorrection value of the V passages of first pixel.

Description

A kind of image processing method and device
Technical field
This application involves technical field of image processing more particularly to a kind of correction of false colour and chromatic noise suppressing method and dresses It puts.
Background technology
Human eye is that light, there are three kinds of different sensing units, different sensing units based on human eye to the identification of color There is the principle of different response curves to the light of different-waveband, the perception of color is obtained by the synthesis of brain.In general, Popular it can understand the decomposition of color and synthesis with red bluish-green trichromatic concept.
In camera imaging system, due to the relation of lens optical dispersion, lateral chromatic aberration and longitudinal chromatic aberration can be generated, this A little lateral chromatic aberrations and longitudinal chromatic aberration institute into the edge of image show as purple boundary, it is green while, Huang Bian, indigo plant while etc. false colours, cause image Distortion, it is therefore desirable to be corrected to false colour.
The content of the invention
The embodiment of the present application provides a kind of image processing method and device, to realize false colour correction and color noise suppression System.
To achieve these goals, the embodiment of the present application provides a kind of image processing method, including:
Determine the first pixel pending in pending image and the firstth area centered on first pixel Domain and second area, the first area are less than the second area.
The pixel for meeting first condition in the first area is determined, according to the pixel for meeting first condition The average value of difference between saturation infromation and predetermined threshold value determines corresponding first weight in the first area;Wherein, institute It states and meets the pixel that the pixel of first condition is less than the predetermined threshold value for saturation infromation, the saturation degree of a pixel Information is equal to the maximum among the absolute value of U passage saturation differences and the absolute value of V passage saturation differences, and the U leads to Road saturation difference subtracts U channel values when saturation degree is zero equal to U channel values, and the V passages saturation difference is equal to V passages Value subtracts V channel values when saturation degree is zero.
According to corresponding first weight in the first area, U channel values and firstth area to first pixel The corresponding U passages average value in domain is weighted averagely, the false colour precorrection value of the U passages of first pixel is obtained, to institute The corresponding V passages average value of V channel values and the first area for stating the first pixel is weighted averagely, obtains described first The false colour precorrection value of the V passages of pixel;Wherein, the corresponding U passages average value in the first area is the first area In meet first condition pixel U channel values average value, the corresponding V passages average value in the first area is described the Meet the average value of the V channel values of the pixel of first condition in one region.
According to corresponding first weight in the first area, U channel values and firstth area to first pixel U channel values after image median filter in domain are weighted the false colour correction for averagely, obtaining the first pixel U passages Value, is weighted the V channel values after the image median filter in the V channel values and the first area of first pixel It is average, obtain the false colour corrected value of the first pixel V passages;Wherein, the U channel values and V after described image medium filtering Channel value is worth to according to the false colour precorrection of the U passages and V passages of first pixel.
Pixel in the second area carries out color noise inhibition to first pixel, obtains described first U channel values and V channel values after the inhibition of pixel color noise.
According to the second weight, U channel values and U passage false colour corrected values after inhibiting to the first pixel color noise It is weighted averagely, the V channel values and V passage false colour corrected values after inhibiting to the first pixel color noise are weighted It is average, obtain U channel values and V channel values after the first pixel point calibration.
The image processing method that the embodiment of the present application provides further includes:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and described first when saturation degree is zero The U channel values of pixel subtract the obtained difference of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by institute The U channel values for stating the first pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by first pixel The U channel values of point are arranged to the value of U passages when saturation degree is zero.
If the V channel values after medium filtering subtract the obtained difference of V channel values and described first when saturation degree is zero The V channel values of pixel subtract the obtained difference of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by institute The V channel values for stating the first pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by first pixel The V channel values of point are arranged to the value of V passages when saturation degree is zero.
Optionally, according between the U passages saturation infromation of the pixel for meeting first condition and predetermined threshold value Between the V passages saturation infromation and the predetermined threshold value of the average value of difference and the pixel for meeting first condition The average value of difference determines corresponding first weight in the first area, specifically includes:
Determine the set for meeting the pixel of first condition in the first area.
Determine the tired of the difference value between the saturation infromation of all pixels point in the set and the predetermined threshold value It sums it up, the difference value between the saturation infromation and the predetermined threshold value subtracts saturation infromation equal to the predetermined threshold value and obtains The difference arrived.
According to it is described cumulative and and the set in pixel quantity, determine the first area corresponding first Weight.
Optionally, according to the following formula to the corresponding U passages of the U channel values of first pixel and the first area Average value is weighted average:
Mean_u_cor=(wt_global*cur_u+ (1-wt_global) * mean_u)
Wherein, mean_u_cor represents the false colour precorrection value of the U passages of first pixel, and wt_global is represented Corresponding first weight in the first area, cur_u represent the U channel values of first pixel, and mean_u represents described the The corresponding U passages average value in one region.
According to the following formula to the corresponding V passages average value of the V channel values of first pixel and the first area It is weighted average:
Mean_v_cor=(wt_global*cur_v+ (1-wt_global) * mean_v)
Wherein, mean_v_cor represents the false colour precorrection value of the V passages of first pixel, described in cur_v is represented The V channel values of first pixel, mean_v represent the corresponding V passages average value in the first area.
Optionally, according to the following formula in the image in the U channel values and the first area of first pixel U channel values after value filtering are weighted average:
Fcc_u=(wt_global*cur_u+ (total-wt_global) * med_u)/total
Wherein, fcc_u represents the false colour corrected value of the first pixel U passages, and cur_u represents first pixel U channel values, wt_global represents corresponding first weight in the first area, and med_u represents the figure in the first area As the U channel values after medium filtering.
According to the following formula to the image median filter in the V channel values and the first area of first pixel after V channel values be weighted it is average:
Fcc_v=(wt_global*cur_v+ (total-wt_global) * med_v)/total
Wherein, fcc_v represents the false colour corrected value of the first pixel V passages, and cur_v represents first pixel V channel values, med_v represents the V channel values after the image median filter in the first area.
Optionally, the pixel in the second area carries out color noise inhibition, tool to the pending pixel Body includes:
Pixel progress in the second area is image layered, obtains K tomographic images from low to high, K is Integer more than 1.
Following steps are performed since the image of low frequency:Color noise inhibition is carried out to image, after noise suppressed Image reconstruction obtains the image of higher frequency, and to the order of high frequency, each layer is filtered using a bilateral filtering realization.
Optionally, U channel values and U passage false colours after inhibiting according to the following formula to the first pixel color noise Corrected value is weighted average:
Output_u=alpha*cnr_u+ (1-alpha) * fcc_u
Wherein, output_u represents the U channel values after the first pixel point calibration, and alpha represents second weight, Cnr_u represents the U channel values after the first pixel color noise inhibition, and fcc_u represents U passage false colour corrected values.
V channel values and V passage false colour corrected values after inhibiting according to the following formula to the first pixel color noise It is weighted average:
Output_v=alpha*cnr_v+ (1-alpha) * fcc_v
Wherein, output_v represents the V channel values after the first pixel point calibration, and cnr_v represents first pixel V channel values after point color noise inhibition, fcc_v represent V passage false colour corrected values.
Optionally, first pixel determined in pending image, including:
Identification obtains the false colour region in the pending image.
The first pixel is selected in the false colour region identified.
Optionally, the first area is the block of pixels of M*M, and the second area is the block of pixels of N*N, and M and N are big In 1 odd number, M is less than N.
In above-described embodiment, false colour correction was not only realized but also had realized color noise inhibition, also carried in the embodiment of the present application It has supplied in a kind of image processing method, can also only carry out false colour correction, specific method can be herein not repeated with foregoing.
The embodiment of the present application provides a kind of image processing apparatus, including:
First pixel determining module, for determining the first pixel in pending image and with first pixel First area and second area centered on point, the first area are less than the second area.
Weight determination module for determining to meet the pixel of first condition in the first area, meets according to described The average value of difference between the saturation infromation and predetermined threshold value of the pixel of first condition determines that the first area corresponds to The first weight;Wherein, the pixel for meeting first condition is less than the pixel of the predetermined threshold value for saturation infromation, The saturation infromation of one pixel be equal to absolute value and the V passage saturation differences of U passage saturation differences absolute value it In maximum, the U passages saturation difference is equal to U channel values and subtracts U channel values when saturation degree is zero, the V passages Saturation difference subtracts V channel values when saturation degree is zero equal to V channel values.
False colour precorrection module, for according to corresponding first weight in the first area, to the U of first pixel The corresponding U passages average value of channel value and the first area is weighted averagely, obtains the U passages of first pixel False colour precorrection value, the corresponding V passages average value of V channel values and the first area to first pixel are weighted It is average, obtain the false colour precorrection value of the V passages of first pixel;Wherein, the corresponding U passages in the first area are averaged It is worth the average value for meeting the U channel values of the pixel of first condition in the first area, the corresponding V in the first area leads to Road average value is the average value of the V channel values for the pixel for meeting first condition in the first area.
False colour correction module, for according to corresponding first weight in the first area, leading to the U of first pixel U channel values after image median filter in road value and the first area are weighted averagely, obtain the first pixel U The false colour corrected value of passage, to the V after the image median filter in the V channel values and the first area of first pixel Channel value is weighted averagely, obtains the false colour corrected value of the first pixel V passages;Wherein, described image medium filtering U channel values and V channel values afterwards is worth to according to the false colour precorrection of the U passages and V passages of first pixel.
Color noise suppression module carries out color for the pixel in the second area to first pixel Noise suppressed obtains the U channel values after the first pixel color noise inhibits and V channel values.
Composed correction module, for according to the second weight, the U channel values after inhibiting to the first pixel color noise Average, V channel values and V passages after inhibiting to the first pixel color noise are weighted with U passage false colour corrected values False colour corrected value is weighted averagely, obtains U channel values and V channel values after the first pixel point calibration.
Image processing apparatus provided by the embodiments of the present application further includes overcorrect protection module, and overcorrect protection module is used In:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and described first when saturation degree is zero The U channel values of pixel subtract the obtained difference of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by institute The U channel values for stating the first pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by first pixel The U channel values of point are arranged to the value of U passages when saturation degree is zero.
If the V channel values after medium filtering subtract the obtained difference of V channel values and described first when saturation degree is zero The V channel values of pixel subtract the obtained difference of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by institute The V channel values for stating the first pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by first pixel The V channel values of point are arranged to the value of V passages when saturation degree is zero.
In another image processing apparatus provided by the embodiments of the present application, false colour correction can also be only carried out, it is specific to fill It puts and can herein be not repeated with foregoing.
In above-described embodiment of the application, can the first weight be determined according to the pending pixel in pending image, into And pending image U passages and the false colour precorrection value of V passages and false colour corrected value can be obtained, can also to second area into Row color noise inhibits, and finally mixes corrected value, more efficiently carries out image procossing, reduce logic redundancy.
Description of the drawings
Fig. 1 is the image processing method flow diagram that the embodiment of the present application is applicable in;
Fig. 2 is the image slide window schematic diagram being applicable in the embodiment of the present application;
Fig. 3 is a kind of color noise suppressing method flow diagram provided by the embodiments of the present application;
Fig. 4 is image processing apparatus schematic diagram provided by the embodiments of the present application.
Specific embodiment
Image processing method provided by the embodiments of the present application is handled image in YUV color spaces.In YUV colors In space, Y represents lightness (Luminance or Luma), that is, grayscale value;What U and V was represented is then colourity (Chrominance or Chroma) effect is to describe the color and saturation degree of image, for the color of specified pixel.YUV colors The luminance signal Y and carrier chrominance signal U, V in space are separated.
U signal component is represented using U passages in embodiment below the application, represents V signal component with V passages.
The embodiment of the present application is described in detail below in conjunction with the accompanying drawings.
Under normal circumstances, false colour is present in image border, this kind of high-frequency region of texture, and color noise, which is present in image, puts down False color in blocks is presented in smooth low frequency region and on image.Based on the feature, using different big in the embodiment of the present application Small region is handled respectively.
The flow that false colour correction and color noise inhibition are carried out to pending image is described in flow shown in FIG. 1.It should Flow can be performed by image processing apparatus, which by hardware realization by software can either be realized or passed through software and hardware The mode being combined is realized.As shown in the figure, this method may include:
Step 101:Determine the first pixel pending in pending image and centered on the first pixel One region and second area.
In the step, place can be also treated respectively using each pixel in pending image as pending pixel False colour region in reason image is identified, and pending pixel is selected in the false colour region identified.
Wherein, the first area can be the block of pixels of M*M, and the second area can be the block of pixels of N*N, M and N It is the integer more than 1, M is less than N.In order to preferably remove false colour, M and N can be using values as the odd number more than 1.If pass through Image slide window is operated, and causing the translation of certain distance on image with even number window, (image is moved integrally to a direction Certain distance), and odd number window is not in this phenomenon.
When it is implemented, the image slide window of M*M pixels can be set, by pending image to M/2 pixel of external expansion, such as Shown in Fig. 2.The pending abducent part shadow representation of image, most intermediate box represent to choose the image of M*M pixels Selectable pending pixel during sliding window.Specifically, the mode that pixel mirror picture can be used is extended, for example, in Fig. 2 The pixel A ' of expansion is mirror images of the pixel A along edge x in pending image.By the image slide window with a pixel To be slided in the image of step-length after expansion, several first areas can be so chosen, the pixel in the first area As pending pixel.
If carrying out false colour region recognition to pending image, false colour region is obtained, then can use image slide at this Pending pixel and the first area centered on the pending pixel and second area are chosen in false colour region.
Step 102:U channel values and V channel values based on the pixel in first area calculate first in first area Corresponding first weight of pixel.Specifically, it is determined that meet the pixel of first condition in first area, according to meeting first The average value of difference between the saturation infromation and predetermined threshold value of the pixel of part determines corresponding first power of the first pixel Weight.
Specifically, it is determined that meet the set of the pixel of first condition in the first area;For in the set Each pixel calculates the saturation infromation of the pixel, the difference between the saturation infromation and predetermined threshold value of all pixels point Value cumulative and, the difference value between the saturation infromation and the predetermined threshold value subtracts saturation degree equal to the predetermined threshold value The difference that information obtains;According to it is described cumulative and and the set in pixel quantity, determine that the first pixel corresponds to The first weight.
Wherein, the saturation infromation of a pixel can be used for characterizing between the saturation degree of the pixel and zero saturation degree Distance.The saturation infromation of one pixel can obtain in the following way:The absolute value of U passage saturation differences is taken to lead to V Maximum among the absolute value of road saturation difference, it is zero that the U passages saturation difference subtracts saturation degree equal to U channel values When U channel values, the V passages saturation difference is equal to V channel values and subtracts V channel values when saturation degree is zero.It is above-mentioned to determine Method can be represented with equation 1 below:
Diff=MAX (abs (inDataM*M (i, j) -128), abs (refDataM*M (i, j) -128)) ... 1
Wherein, DataM*M (i, j) denotation coordination is (i, j) pixel, and the pixel is in the first area of M*M sizes Centre coordinate point, inDataM*M (i, j) represents the U channel values of the pixel, and refDataM*M (i, j) represents the pixel V channel values, U channel values and V channel values when saturation degree is zero are respectively 128.MAX () expressions take higher value, and diff represents to sit It is designated as the saturation infromation of (i, j) pixel.
Wherein, the pixel that the pixel of first condition is less than predetermined threshold value for saturation infromation is met.The default threshold The value range of value is [0,128], and preferred predetermined threshold value is 10.
In the step, the first pixel (such as the regional center that can be directed in a first area or the first area The pixel of position) determine corresponding first weight, which can be used in follow-up false colour correction course using.First weight It can be calculated according to equation 2 below:
Wherein, wt_u represents corresponding first weight of the first pixel, and difference_sum represents to accord in first area Close first condition pixel (thr1-diff) value add up and, (thr1-diff) value of a pixel subtracts for predetermined threshold value Go the obtained difference of saturation infromation of the pixel;Num represents the number for meeting the pixel of first condition in first area Amount.
Step 103:According to corresponding first weight of the first pixel determined in step 102 and the first pixel Color Channel, to the first pixel carry out false colour precorrection.Specifically, it is right according to corresponding first weight of the first pixel The corresponding U passages average value of the U channel values of first pixel and first area is weighted averagely, obtains the U of the first pixel The false colour precorrection value of passage is weighted the corresponding V passages average value of the V channel values of the first pixel and first area flat , the false colour precorrection value of the V passages of the first pixel is obtained.
In the step, the U channel values to the first pixel and V channel values false colour precorrection can be carried out respectively.
For the U passages of the first pixel, procedure below can be used and carry out false colour precorrection:It is corresponding to calculate first area U passage average values, the value are the average value of the U channel values for the pixel for meeting first condition in first area;By to first The corresponding U passages average value of the U channel values of pixel and first area is weighted averagely, obtains the U passages of the first pixel False colour precorrection value, can specifically be calculated according to equation 3 below:
Mean_u_cor=(wt_global*cur_u+ (1-wt_global) * mean_u) ... formula 3
Wherein, mean_u_cor represents the false colour precorrection value of the U passages of the first pixel, and wt_global represents first Corresponding first weight of pixel, cur_u represent the U channel values of the first pixel, and mean_u represents that the corresponding U in first area leads to Road average value.
For the V passages of the first pixel, procedure below can be used and carry out false colour precorrection:It is corresponding to calculate first area V passage average values, the value are the average value of the V channel values for the pixel for meeting first condition in first area;By to first The corresponding V passages average value of the V channel values of pixel and first area is weighted averagely, obtains the V passages of the first pixel False colour precorrection value, can specifically be calculated according to equation 4 below:
Mean_v_cor=(wt_global*cur_v+ (1-wt_global) * mean_v) ... formula 4
Wherein, mean_v_cor represents the false colour precorrection value of the V passages of the first pixel, and cur_v represents the first pixel The V channel values of point, mean_v represent the corresponding V passages average value in the corresponding first area of the first pixel.
Step 104:According to corresponding first weight of the first pixel determined in step 102 and the first pixel Color Channel and median-filtered result, to the first pixel carry out false colour precorrection.Specifically, according to the first pixel pair The first weight answered adds the U channel values after the image median filter in the U channel values of the first pixel and first area Weight average obtains the false colour corrected value of the first pixel U passages, to the figure in the V channel values of the first pixel and first area It is averaged as the V channel values after medium filtering are weighted, obtains the false colour corrected value of the first pixel V passages.
Wherein, the U channel values after described image medium filtering and V channel values are led to according to the U passages and V of the first pixel What the false colour precorrection in road was worth to.
Specifically, the image intermediate value in the U channel values and the first area of the first pixel is filtered according to equation 5 below U channel values after ripple are weighted average:
Fcc_u=(wt_global*cur_u+ (total-wt_global) * med_u)/total ... formula 5
Wherein, fcc_u represents the false colour corrected value of the first pixel U passages, and cur_u represents the U passages of the first pixel Value, wt_global represents corresponding first weight of the first pixel, after med_u represents the image median filter in first area U channel values.
According to equation 6 below to the V passages after the image median filter in the V channel values of the first pixel and first area Value is weighted average:
Fcc_v=(wt_global*cur_v+ (total-wt_global) * med_v)/total ... formula 6
Wherein, fcc_v represents the false colour corrected value of the first pixel V passages, and cur_v represents the V passages of the first pixel Value, med_v represent the V channel values after the image median filter in first area.
Step 105:Pixel in second area carries out color noise inhibition to the first pixel, obtains the first picture U channel values and V channel values after the inhibition of vegetarian refreshments color noise.
Multiple color noise suppressing method can be used in the embodiment of the present application, and the embodiment of the present application is not restricted this.In order to Preferable color noise inhibition is obtained, a kind of color noise inhibition side used by the embodiment of the present application has been illustrated below Method:
The image in first area is layered using gaussian pyramid technology, is obtained from low frequency region to high-frequency region Multiple figure layers;According to the order from low frequency region to high-frequency region, color noise inhibition is carried out to a figure layer, and according to face Figure layer after coloured noise inhibits reconstructs to obtain the next stage figure layer of the figure layer, the figure layer of lowest frequency is obtained until reconstructing, according to this Reconstruct the Color Channel of pixel corresponding with the first vegetarian refreshments position in the figure layer of obtained lowest frequency, you can obtain first picture Color Channel after the inhibition of vegetarian refreshments color noise.One example of the above method can be as shown in Figure 3.
As shown in figure 3, the flow may include:
S301:Image in first area is layered, may include according to the order from high-frequency region to low frequency region First to N figure layers.
S302:It is 1 to set K values, is transferred to S303;
S303:Color noise filtering is carried out to k-th figure layer, the K+1 figure layer is reconstructed with filtered k-th figure layer, It is transferred to S304;
Wherein, the method that bilateral filtering can be used carries out color noise filtering to k-th figure layer.If for example, k-th figure The size of layer is L ﹡ L pixels, can calculate the intensity weight and object of each pixel and central pixel point in k-th figure layer respectively Distance weighting is managed, the U passages to k-th figure layer and the progress of V passages are bilateral respectively according to intensity weight and physical distance weight Filtering, wherein, carrying out bilateral filtering to U passages can carry out according to equation below 7, and the U channel layer colors for obtaining k-th figure layer are made an uproar Sound histamine result cnr_u_L*L:
W (k, l)=d (k, l) * r (k, l) ... formula 7
Wherein, σdAnd σrFor pre- calibrating parameters, σ can be set for different figure layers according to picture noise is horizontaldAnd σrTake Value.D (k, l) represents that coordinate is weighed for the physical distance of the central pixel point of the pixel and figure layer of (k, l) in k-th figure layer Heavy, coordinate is the central pixel point intensity weight of the pixel with the figure layer of (k, l) in r (k, l) expression k-th figure layers, InData_uL*L (L/2, L/2) represents that coordinate is the U channel values of the pixel of (L/2, L/2), inData_ in k-th figure layer UL*L (k, l) represents that coordinate is the U channel values of the pixel of (k, l) in k-th figure layer.
Bilateral filtering is carried out to U passages to carry out according to equation below 8, obtains the V channel layer color noises of k-th figure layer Histamine result cnr_v_L*L:
W (k, l)=d (k, l) * r (k, l) ... formula 8
Wherein, wherein, σdAnd σrFor pre- calibrating parameters, σ can be set for different figure layers according to picture noise is horizontaldAnd σr Value.D (k, l) represents that coordinate is the physical distance of the central pixel point of the pixel and figure layer of (k, l) in k-th figure layer Weight, r (k, l) represent the central pixel point intensity weight of coordinate in k-th figure layer for pixel and the figure layer of (k, l), InData_vL*L (L/2, L/2) represents that coordinate is the V channel values of the pixel of (L/2, L/2), inData_ in k-th figure layer VL*L (k, l) represents that coordinate is the V channel values of the pixel of (k, l) in k-th figure layer.
S304:The value of K is incremented by, judges whether the value of K reaches N, if not up to, being transferred to S303, otherwise, It is transferred to S305;
S305:To reconstruct in obtained n-th figure layer the U channel values of pixel corresponding with pending pixel position and V channel values, U channel values and V channel values after inhibiting as pending pixel color noise.
Step 106:According to the second weight, and based on the channel value and false colour corrected value after color noise inhibition, determine most Whole channel correcting value.Specifically, can be according to the second weight, U channel values and U after inhibiting to the first pixel color noise are led to Road false colour corrected value is weighted averagely, obtains the U channel values after the first pixel point calibration, and the first pixel color noise is pressed down V channel values and V passage false colour corrected values after system are weighted averagely, obtain the V channel values after the first pixel point calibration.
Wherein, the second weight can be pre-set.The value range of second weight can be (0~1).The value of second weight It is related to ambient brightness.
When it is implemented, the following formula, which can be used, calculates final U channel correcting values:
Output_u=alpha*cnr_u+ (1-alpha) * fcc_u ... formula 9
The following formula can be used and calculate final U channel correcting values:
Output_v=alpha*cnr_v+ (1-alpha) * fcc_v ... formula 10
Wherein, fcc_u represents the false colour corrected value of U passages, and fcc_v represents the false colour corrected value of V passages, and cnr_u is represented U channel values after color noise inhibition, cnr_v represent the V channel values after color noise inhibition, and alpha represents the second weight.
Based on above-mentioned formula 9 and formula 10, under normal circumstances, environment is darker, and noise is more serious, therefore can set alpha It is set to higher value;Conversely, environment is brighter, noise is smaller, then can alpha be arranged to smaller value.
Based on above-mentioned flow, each pixel that can be directed in pending image carries out false colour correction and color noise suppression System carries out false colour correction and color noise inhibition for each pixel in the false colour region in pending image.
After false colour correction and color noise inhibition being carried out by above-described embodiment, it is possible to produce be corrected the U of pixel People having a common goal's value or V channel values cross over the situation of 128 (saturation degrees 0), i.e., become another color from a kind of color, such as become from red Au bleu, such case are known as overcorrect.In order to avoid this overcorrect, the embodiment of the present application provides overcorrect protection side Case can be directed to the pixel that U passages or V passage overcorrects occurs, the value of its respective channel is corrected to 128.
Specifically, following steps can be performed after above-mentioned steps 106:
Step 107:For the first pixel after correction, the U channel values and V channel values for judging the first pixel respectively are U channel values if overcorrect occurs for U channel values, are corrected to 128, otherwise keep the value of the U passages not by no generation overcorrect Become, if overcorrect occurs for V channel values, V channel values are corrected to 128, the value for otherwise keeping the V passages is constant.
Wherein, it can judge that U of first pixel after above-mentioned correction process in first area leads in the following way Whether road value occurs overcorrect:If it is zero that the U channel values after the medium filtering of the pixel in the first area, which subtract saturation degree, When U channel values (128) obtained difference and the first pixel point calibration before U channel values subtract U when saturation degree is zero Channel value (i.e. 128) obtained difference, is all higher than zero or less than zero, then the U channel values after the first pixel point calibration are not sent out Raw overcorrect, otherwise the U channel values generation overcorrect after the first pixel point calibration.
Similarly, U of first pixel after above-mentioned correction process in first area can be also judged according to the method described above Whether channel value occurs overcorrect:If the V channel values after the medium filtering of the pixel in the first area subtract saturation degree and are It is zero that V channel values when zero before the obtained difference of V channel values (128) and the first pixel point calibration, which subtract saturation degree, When V channel values (128) obtained difference, be all higher than zero or less than zero, then the V channel values after the first pixel point calibration are not Generation overcorrect, otherwise the V channel values generation overcorrect after the first pixel point calibration.
In conclusion pending picture of the image processing method provided in the embodiment of the present application in pending image Vegetarian refreshments determines the first weight, and then can obtain false colour precorrection value and the false colour correction of pending image U passages and V passages Value can also carry out color noise inhibition to second area, finally mix corrected value, more efficiently carry out image procossing, Reduce logic redundancy.
In above-described embodiment, false colour correction was not only realized by step 101 to step 106 but also has realized color noise suppression System in a further embodiment, can also only carry out false colour correction, specific method can same previous embodiment, be not repeated herein.
Based on identical technical concept, the embodiment of the present application also provides a kind of device, which can perform above method reality Apply example.As shown in figure 4, the image processing apparatus includes:
First pixel determining module 401, for determining the first pixel in pending image and with described first First area and second area centered on pixel, the first area are less than the second area;
Weight determination module 402, for determining to meet the pixel of first condition in the first area, according to the symbol The average value of the difference between the saturation infromation of the pixel of first condition and predetermined threshold value is closed, determines the first area pair The first weight answered;Wherein, the pixel for meeting first condition is less than the pixel of the predetermined threshold value for saturation infromation Point, the saturation infromation of a pixel are equal to the absolute value of U passage saturation differences and the absolute value of V passage saturation differences Among maximum, the U passages saturation difference is equal to U channel values and subtracts U channel values when saturation degree is zero, and the V leads to Road saturation difference subtracts V channel values when saturation degree is zero equal to V channel values;
False colour precorrection module 403, for according to corresponding first weight in the first area, to first pixel The corresponding U passages average value of U channel values and the first area be weighted average, the U for obtaining first pixel leads to The false colour precorrection value in road, the corresponding V passages average value of V channel values and the first area to first pixel carry out Weighted average obtains the false colour precorrection value of the V passages of first pixel;Wherein, the corresponding U passages in the first area Average value is the average value of the U channel values for the pixel for meeting first condition in the first area, and the first area corresponds to V passages average value to meet the average value of the V channel values of the pixel of first condition in the first area;
False colour correction module 404, for according to corresponding first weight in the first area, to first pixel U channel values after image median filter in U channel values and the first area are weighted averagely, obtain first pixel The false colour corrected value of point U passages, after the image median filter in the V channel values and the first area of first pixel V channel values be weighted average, obtain the false colour corrected value of the first pixel V passages;Wherein, described image intermediate value is filtered U channel values and V channel values after ripple are worth to according to the false colour precorrection of the U passages and V passages of first pixel;
Color noise suppression module 405 carries out first pixel for the pixel in the second area Color noise inhibits, and obtains the U channel values after the first pixel color noise inhibits and V channel values;
Composed correction module 406, for according to the second weight, the U after inhibiting to the first pixel color noise to lead to Road value and U passage false colour corrected values are weighted average, V channel values and V after inhibiting to the first pixel color noise Passage false colour corrected value is weighted averagely, obtains U channel values and V channel values after the first pixel point calibration.
Image processing apparatus provided by the embodiments of the present application further includes overcorrect protection module, and overcorrect protection module is used In:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and described first when saturation degree is zero The U channel values of pixel subtract the obtained difference of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by institute The U channel values for stating the first pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by first pixel The U channel values of point are arranged to the value of U passages when saturation degree is zero;
If the V channel values after medium filtering subtract the obtained difference of V channel values and described first when saturation degree is zero The V channel values of pixel subtract the obtained difference of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by institute The V channel values for stating the first pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by first pixel The V channel values of point are arranged to the value of V passages when saturation degree is zero.
Wherein, weight determination module 402 is specifically used for:
Determine the set for meeting the pixel of first condition in the first area;
Determine the tired of the difference value between the saturation infromation of all pixels point in the set and the predetermined threshold value It sums it up, the difference value between the saturation infromation and the predetermined threshold value subtracts saturation infromation equal to the predetermined threshold value and obtains The difference arrived;
According to it is described cumulative and and the set in pixel quantity, determine the first area corresponding first Weight.
Wherein, color noise suppression module 405 is specifically used for:
Pixel progress in the second area is image layered, obtains K tomographic images from low to high, K is Integer more than 1;
Following steps are performed since the image of low frequency:Color noise inhibition is carried out to image, after noise suppressed Image reconstruction obtains the image of higher frequency, and to the order of high frequency, each layer is filtered using a bilateral filtering realization.
Wherein, the U after composed correction module 406 inhibits the first pixel color noise according to above-mentioned formula 9 leads to Road value and U passage false colour corrected values are weighted average.
V channel values and V passages false colour after inhibiting according to above-mentioned formula 10 to the first pixel color noise correct Value is weighted average.
In a further embodiment, can also only carry out false colour correction, specific device can same previous embodiment, herein no longer It repeats.
The application is with reference to the flow according to the method for the embodiment of the present application, equipment (system) and computer program product Figure and/or block diagram describe.It should be understood that it can be realized by computer program instructions every first-class in flowchart and/or the block diagram The combination of flow and/or box in journey and/or box and flowchart and/or the block diagram.These computer programs can be provided The processor of all-purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce A raw machine so that the instruction performed by computer or the processor of other programmable data processing devices is generated for real The device for the function of being specified in present one flow of flow chart or one box of multiple flows and/or block diagram or multiple boxes.
These computer program instructions, which may also be stored in, can guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works so that the instruction generation being stored in the computer-readable memory includes referring to Make the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one box of block diagram or The function of being specified in multiple boxes.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that counted Series of operation steps is performed on calculation machine or other programmable devices to generate computer implemented processing, so as in computer or The instruction offer performed on other programmable devices is used to implement in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in a box or multiple boxes.
Although the preferred embodiment of the application has been described, those skilled in the art once know basic creation Property concept, then can make these embodiments other change and modification.So appended claims be intended to be construed to include it is excellent It selects embodiment and falls into all change and modification of the application scope.
Obviously, those skilled in the art can carry out the application essence of the various modification and variations without departing from the application God and scope.In this way, if these modifications and variations of the application belong to the scope of the application claim and its equivalent technologies Within, then the application is also intended to comprising including these modification and variations.

Claims (24)

1. a kind of image processing method, which is characterized in that including:
Determine the first pixel pending in pending image and first area centered on first pixel and Second area, the first area are less than the second area;
The pixel for meeting first condition in the first area is determined, according to the saturation of the pixel for meeting first condition The average value of the difference between information and predetermined threshold value is spent, determines corresponding first weight in the first area;Wherein, the symbol Close the pixel that the pixel of first condition is less than the predetermined threshold value for saturation infromation, the saturation infromation of a pixel Equal to the maximum among the absolute value of U passage saturation differences and the absolute value of V passage saturation differences, the U passages are satisfied It is equal to U channel values with degree difference and subtracts U channel values when saturation degree is zero, the V passages saturation difference subtracts equal to V channel values V channel values when desaturation degree is zero;
According to corresponding first weight in the first area, U channel values and the first area pair to first pixel The U passage average values answered are weighted average, obtain the false colour precorrection value of the U passages of first pixel, to described the The corresponding V passages average value of the V channel values of one pixel and the first area is weighted averagely, obtains first pixel The false colour precorrection value of the V passages of point;Wherein, the corresponding U passages average value in the first area is to be accorded in the first area The average value of the U channel values of the pixel of first condition is closed, the corresponding V passages average value in the first area is firstth area Meet the average value of the V channel values of the pixel of first condition in domain;
According to corresponding first weight in the first area, in the U channel values and the first area of first pixel Image median filter after U channel values be weighted average, obtain the false colour corrected value of the first pixel U passages, it is right The V channel values after image median filter in the V channel values and the first area of first pixel are weighted averagely, Obtain the false colour corrected value of the first pixel V passages;Wherein, the U channel values and V channel values after described image medium filtering It is to be worth to according to the false colour precorrection of the U passages and V passages of first pixel;
Pixel in the second area carries out color noise inhibition to first pixel, obtains first pixel U channel values and V channel values after point color noise inhibition;
According to the second weight, U channel values and U passage false colours corrected value after inhibiting to the first pixel color noise carry out Weighted average, V channel values and V passage false colour corrected values after inhibiting to the first pixel color noise are weighted flat , U channel values and V channel values after the first pixel point calibration are obtained.
2. the method as described in claim 1, which is characterized in that further include:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and first pixel when saturation degree is zero The U channel values of point subtract the obtained differences of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The U channel values of one pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by the U of first pixel Channel value is arranged to the value of U passages when saturation degree is zero;
If the V channel values after medium filtering subtract the obtained difference of V channel values and first pixel when saturation degree is zero The V channel values of point subtract the obtained differences of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The V channel values of one pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by the V of first pixel Channel value is arranged to the value of V passages when saturation degree is zero.
3. the method as described in claim 1, which is characterized in that satisfied according to the U passages of the pixel for meeting first condition The average value of difference and the V passage saturation degrees of the pixel for meeting first condition between degree information and predetermined threshold value The average value of difference between information and the predetermined threshold value determines corresponding first weight in the first area, specifically includes:
Determine the set for meeting the pixel of first condition in the first area;
Determine the cumulative of the difference value between the saturation infromation of all pixels point in the set and the predetermined threshold value and, Difference value between the saturation infromation and the predetermined threshold value subtracts what saturation infromation obtained equal to the predetermined threshold value Difference;
According to it is described cumulative and and the set in pixel quantity, determine corresponding first power in the first area Weight.
4. the method as described in claim 1, which is characterized in that according to the following formula to the U channel values of first pixel U passage average values corresponding with the first area are weighted average:
Mean_u_cor=(wt_global*cur_u+ (1-wt_global) * mean_u)
Wherein, mean_u_cor represents the false colour precorrection value of the U passages of first pixel, described in wt_global is represented Corresponding first weight in first area, cur_u represent the U channel values of first pixel, and mean_u represents firstth area The corresponding U passages average value in domain;
The corresponding V passages average value of the V channel values of first pixel and the first area is carried out according to the following formula Weighted average:
Mean_v_cor=(wt_global*cur_v+ (1-wt_global) * mean_v)
Wherein, mean_v_cor represents the false colour precorrection value of the V passages of first pixel, and cur_v represents described first The V channel values of pixel, mean_v represent the corresponding V passages average value in the first area.
5. the method as described in claim 1, which is characterized in that according to the following formula to the U channel values of first pixel It is weighted with the U channel values after the image median filter in the first area average:
Fcc_u=(wt_global*cur_u+ (total-wt_global) * med_u)/total
Wherein, fcc_u represents the false colour corrected value of the first pixel U passages, and cur_u represents the U of first pixel Channel value, wt_global represent corresponding first weight in the first area, and med_u represents the image in the first area U channel values after medium filtering;
According to the following formula to the V after the image median filter in the V channel values and the first area of first pixel Channel value is weighted average:
Fcc_v=(wt_global*cur_v+ (total-wt_global) * med_v)/total
Wherein, fcc_v represents the false colour corrected value of the first pixel V passages, and cur_v represents the V of first pixel Channel value, med_v represent the V channel values after the image median filter in the first area.
6. the method as described in claim 1, which is characterized in that the pixel in the second area is to described pending Pixel carries out color noise inhibition, specifically includes:
Pixel progress in the second area is image layered, obtains K tomographic images from low to high, and K is more than 1 Integer;
Following steps are performed since the image of low frequency:Color noise inhibition is carried out to image, according to the image after noise suppressed Reconstruct obtains the image of higher frequency, and to the order of high frequency, each layer is filtered using a bilateral filtering realization.
7. the method as described in claim 1, which is characterized in that press down according to the following formula to the first pixel color noise U channel values and U passage false colour corrected values after system are weighted average:
Output_u=alpha*cnr_u+ (1-alpha) * fcc_u
Wherein, output_u represents the U channel values after the first pixel point calibration, and alpha represents second weight, cnr_ U represents the U channel values after the first pixel color noise inhibition, and fcc_u represents U passage false colour corrected values;
V channel values and V passage false colours corrected value after inhibiting according to the following formula to the first pixel color noise carry out Weighted average:
Output_v=alpha*cnr_v+ (1-alpha) * fcc_v
Wherein, output_v represents the V channel values after the first pixel point calibration, and cnr_v represents the first pixel face V channel values after coloured noise inhibition, fcc_v represent V passage false colour corrected values.
8. the method as described in claim 1, which is characterized in that first pixel determined in pending image, including:
Identification obtains the false colour region in the pending image;
The first pixel is selected in the false colour region identified.
9. such as method described in any item of the claim 1 to 8, which is characterized in that the first area is the block of pixels of M*M, The second area is the block of pixels of N*N, and M and N are the odd number more than 1, and M is less than N.
10. a kind of image processing method, which is characterized in that including:
Determine the first pixel in pending image and the first area centered on first pixel;
The pixel for meeting first condition in the first area is determined, according to the saturation of the pixel for meeting first condition The average value of the difference between information and predetermined threshold value is spent, determines corresponding first weight in the first area;Wherein, the symbol Close the pixel that the pixel of first condition is less than the predetermined threshold value for saturation infromation, the saturation infromation of a pixel Equal to the maximum among the absolute value of U passage saturation differences and the absolute value of V passage saturation differences, the U passages are satisfied It is equal to U channel values with degree difference and subtracts U channel values when saturation degree is zero, the V passages saturation difference subtracts equal to V channel values V channel values when desaturation degree is zero;
According to corresponding first weight in the first area, U channel values and the first area pair to first pixel The U passage average values answered are weighted average, obtain the false colour precorrection value of the U passages of first pixel, to described the The corresponding V passages average value of the V channel values of one pixel and the first area is weighted averagely, obtains first pixel The false colour precorrection value of the V passages of point;Wherein, the corresponding U passages average value in the first area is to be accorded in the first area The average value of the U channel values of the pixel of first condition is closed, the corresponding V passages average value in the first area is firstth area Meet the average value of the V channel values of the pixel of first condition in domain;
According to corresponding first weight in the first area, in the U channel values and the first area of first pixel Image median filter after U channel values be weighted average, obtain the false colour corrected value of the first pixel U passages, it is right The V channel values after image median filter in the V channel values and the first area of first pixel are weighted averagely, Obtain the false colour corrected value of the first pixel V passages;Wherein, the U channel values and V channel values after described image medium filtering It is to be worth to according to the false colour precorrection of the U passages and V passages of first pixel.
11. method as claimed in claim 10, which is characterized in that further include:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and first pixel when saturation degree is zero The U channel values of point subtract the obtained differences of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The U channel values of one pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by the U of first pixel Channel value is arranged to the value of U passages when saturation degree is zero;
If the V channel values after medium filtering subtract the obtained difference of V channel values and first pixel when saturation degree is zero The V channel values of point subtract the obtained differences of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The V channel values of one pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by the V of first pixel Channel value is arranged to the value of V passages when saturation degree is zero.
12. method as claimed in claim 10, which is characterized in that according to the U passages of the pixel for meeting first condition The V passage saturations of the average value of difference between saturation infromation and predetermined threshold value and the pixel for meeting first condition The average value of the difference between information and the predetermined threshold value is spent, determines corresponding first weight in the first area, it is specific to wrap It includes:
Determine the set for meeting the pixel of first condition in the first area;
Determine the cumulative of the difference value between the saturation infromation of all pixels point in the set and the predetermined threshold value and, Difference value between the saturation infromation and the predetermined threshold value subtracts what saturation infromation obtained equal to the predetermined threshold value Difference;
According to it is described cumulative and and the set in pixel quantity, determine corresponding first power in the first area Weight.
13. method as claimed in claim 10, which is characterized in that according to the following formula to the U passages of first pixel The corresponding U passages average value of value and the first area is weighted average:
Mean_u_cor=(wt_global*cur_u+ (1-wt_global) * mean_u)
Wherein, mean_u_cor represents the false colour precorrection value of the U passages of first pixel, described in wt_global is represented Corresponding first weight in first area, cur_u represent the U channel values of first pixel, and mean_u represents firstth area The corresponding U passages average value in domain;
The corresponding V passages average value of the V channel values of first pixel and the first area is carried out according to the following formula Weighted average:
Mean_v_cor=(wt_global*cur_v+ (1-wt_global) * mean_v)
Wherein, mean_v_cor represents the false colour precorrection value of the V passages of first pixel, and cur_v represents described first The V channel values of pixel, mean_v represent the corresponding V passages average value in the first area.
14. method as claimed in claim 10, which is characterized in that according to the following formula to the U passages of first pixel U channel values after image median filter in value and the first area are weighted average:
Fcc_u=(wt_global*cur_u+ (total-wt_global) * med_u)/total
Wherein, fcc_u represents the false colour corrected value of the first pixel U passages, and cur_u represents the U of first pixel Channel value, wt_global represent corresponding first weight in the first area, and med_u represents the image in the first area U channel values after medium filtering;
According to the following formula to the image median filter in the V channel values and the first area of the pending pixel after V channel values are weighted average:
Fcc_v=(wt_global*cur_v+ (total-wt_global) * med_v)/total
Wherein, fcc_v represents the false colour corrected value of the pending pixel V passages, and cur_v represents first pixel V channel values, med_v represent the V channel values after the image median filter in the first area.
15. a kind of image processing apparatus, which is characterized in that including:
First pixel determining module, for determine the first pixel in pending image and using first pixel as The first area at center and second area, the first area are less than the second area;
Weight determination module for determining to meet the pixel of first condition in the first area, meets first according to described The average value of difference between the saturation infromation and predetermined threshold value of the pixel of condition determines the first area corresponding One weight;Wherein, the pixel for meeting first condition for saturation infromation be less than the predetermined threshold value pixel, one The saturation infromation of pixel is equal among the absolute value of U passage saturation differences and the absolute value of V passage saturation differences Maximum, the U passages saturation difference subtract U channel values when saturation degree is zero, the V passages saturation equal to U channel values Degree difference subtracts V channel values when saturation degree is zero equal to V channel values;
False colour precorrection module, for according to corresponding first weight in the first area, to the U passages of first pixel The corresponding U passages average value of value and the first area is weighted averagely, obtains the false colour of the U passages of first pixel Precorrection value, the corresponding V passages average value of V channel values and the first area to first pixel are weighted flat , the false colour precorrection value of the V passages of first pixel is obtained;Wherein, the corresponding U passages average value in the first area To meet the average value of the U channel values of the pixel of first condition in the first area, the corresponding V passages in the first area Average value is the average value of the V channel values for the pixel for meeting first condition in the first area;
False colour correction module, for according to corresponding first weight in the first area, to the U channel values of first pixel It is weighted averagely with the U channel values after the image median filter in the first area, obtains the first pixel U passages False colour corrected value, to the V passages after the image median filter in the V channel values and the first area of first pixel Value is weighted averagely, obtains the false colour corrected value of the first pixel V passages;Wherein, the U after described image medium filtering Channel value and V channel values are worth to according to the false colour precorrection of the U passages and V passages of first pixel;
Color noise suppression module carries out color noise for the pixel in the second area to first pixel Inhibit, obtain the U channel values after the first pixel color noise inhibits and V channel values;
Composed correction module, for according to the second weight, U channel values and U after inhibiting to the first pixel color noise Passage false colour corrected value is weighted average, V channel values and V passage false colours after inhibiting to the first pixel color noise Corrected value is weighted averagely, obtains U channel values and V channel values after the first pixel point calibration.
16. device as claimed in claim 15, which is characterized in that further include overcorrect protection module, the overcorrect protection Module is used for:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and first pixel when saturation degree is zero The U channel values of point subtract the obtained differences of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The U channel values of one pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by the U of first pixel Channel value is arranged to the value of U passages when saturation degree is zero;
If the V channel values after medium filtering subtract the obtained difference of V channel values and first pixel when saturation degree is zero The V channel values of point subtract the obtained differences of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The V channel values of one pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by the V of first pixel Channel value is arranged to the value of V passages when saturation degree is zero.
17. device as claimed in claim 15, which is characterized in that the weight determination module is specifically used for:
Determine the set for meeting the pixel of first condition in the first area;
Determine the cumulative of the difference value between the saturation infromation of all pixels point in the set and the predetermined threshold value and, Difference value between the saturation infromation and the predetermined threshold value subtracts what saturation infromation obtained equal to the predetermined threshold value Difference;
According to it is described cumulative and and the set in pixel quantity, determine corresponding first power in the first area Weight.
18. device as claimed in claim 15, which is characterized in that the color noise suppression module is specifically used for:
Pixel progress in the second area is image layered, obtains K tomographic images from low to high, and K is more than 1 Integer;
Following steps are performed since the image of low frequency:Color noise inhibition is carried out to image, according to the image after noise suppressed Reconstruct obtains the image of higher frequency, and to the order of high frequency, each layer is filtered using a bilateral filtering realization.
19. device as claimed in claim 15, which is characterized in that the composed correction module is according to the following formula to described U channel values and U passage false colour corrected values after the inhibition of one pixel color noise are weighted average:
Output_u=alpha*cnr_u+ (1-alpha) * fcc_u
Wherein, output_u represents the U channel values after the first pixel point calibration, and alpha represents second weight, cnr_ U represents the U channel values after the first pixel color noise inhibition, and fcc_u represents U passage false colour corrected values;
V channel values and V passage false colours corrected value after inhibiting according to the following formula to the first pixel color noise carry out Weighted average:
Output_v=alpha*cnr_v+ (1-alpha) * fcc_v
Wherein, output_v represents the V channel values after the first pixel point calibration, and cnr_v represents the first pixel face V channel values after coloured noise inhibition, fcc_v represent V passage false colour corrected values.
20. a kind of image processing apparatus, which is characterized in that including:
First pixel determining module, for determine the first pixel in pending image and using first pixel as The first area at center;
Weight determination module for determining to meet the pixel of first condition in the first area, meets first according to described The average value of difference between the saturation infromation and predetermined threshold value of the pixel of condition determines the first area corresponding One weight;Wherein, the pixel for meeting first condition for saturation infromation be less than the predetermined threshold value pixel, one The saturation infromation of pixel is equal among the absolute value of U passage saturation differences and the absolute value of V passage saturation differences Maximum, the U passages saturation difference subtract U channel values when saturation degree is zero, the V passages saturation equal to U channel values Degree difference subtracts V channel values when saturation degree is zero equal to V channel values;
False colour precorrection module, for according to corresponding first weight in the first area, to the U passages of first pixel The corresponding U passages average value of value and the first area is weighted averagely, obtains the false colour of the U passages of first pixel Precorrection value, the corresponding V passages average value of V channel values and the first area to first pixel are weighted flat , the false colour precorrection value of the V passages of first pixel is obtained;Wherein, the corresponding U passages average value in the first area To meet the average value of the U channel values of the pixel of first condition in the first area, the corresponding V passages in the first area Average value is the average value of the V channel values for the pixel for meeting first condition in the first area;
False colour correction module, for according to corresponding first weight in the first area, to the U channel values of first pixel It is weighted averagely with the U channel values after the image median filter in the first area, obtains the first pixel U passages False colour corrected value, to the V passages after the image median filter in the V channel values and the first area of first pixel Value is weighted averagely, obtains the false colour corrected value of the first pixel V passages;Wherein, the U after described image medium filtering Channel value and V channel values are worth to according to the false colour precorrection of the U passages and V passages of first pixel.
21. device as claimed in claim 20, which is characterized in that further include overcorrect protection module, the overcorrect protection Module is used for:
After the U channel values after obtaining the first pixel point calibration and V channel values, perform:
If the U channel values after medium filtering subtract the obtained difference of U channel values and first pixel when saturation degree is zero The U channel values of point subtract the obtained differences of value of U passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The U channel values of one pixel are corrected to the U channel values after the first pixel point calibration, otherwise, by the U of first pixel Channel value is arranged to the value of U passages when saturation degree is zero;
If the V channel values after medium filtering subtract the obtained difference of V channel values and first pixel when saturation degree is zero The V channel values of point subtract the obtained differences of value of V passages when saturation degree is zero, are all higher than zero or less than zero, then by described the The V channel values of one pixel are corrected to the V channel values after the first pixel point calibration, otherwise, by the V of first pixel Channel value is arranged to the value of V passages when saturation degree is zero.
22. device as claimed in claim 20, which is characterized in that the weight determination module is specifically used for:
Determine the set for meeting the pixel of first condition in the first area;
Determine the cumulative of the difference value between the saturation infromation of all pixels point in the set and the predetermined threshold value and, Difference value between the saturation infromation and the predetermined threshold value subtracts what saturation infromation obtained equal to the predetermined threshold value Difference;
According to it is described cumulative and and the set in pixel quantity, determine corresponding first power in the first area Weight.
23. device as claimed in claim 20, which is characterized in that the false colour precorrection module is according to the following formula to described The corresponding U passages average value of the U channel values of first pixel and the first area is weighted average:
Mean_u_cor=(wt_global*cur_u+ (1-wt_global) * mean_u)
Wherein, mean_u_cor represents the false colour precorrection value of the U passages of first pixel, described in wt_global is represented Corresponding first weight in first area, cur_u represent the U channel values of first pixel, and mean_u represents firstth area The corresponding U passages average value in domain;
The corresponding V passages average value of the V channel values of first pixel and the first area is carried out according to the following formula Weighted average:
Mean_v_cor=(wt_global*cur_v+ (1-wt_global) * mean_v)
Wherein, mean_v_cor represents the false colour precorrection value of the V passages of first pixel, and cur_v represents described first The V channel values of pixel, mean_v represent the corresponding V passages average value in the first area.
24. device as claimed in claim 20, which is characterized in that the false colour correction module is according to the following formula to described The U channel values after image median filter in the U channel values and the first area of one pixel are weighted average:
Fcc_u=(wt_global*cur_u+ (total-wt_global) * med_u)/total
Wherein, fcc_u represents the false colour corrected value of the first pixel U passages, and cur_u represents the U of first pixel Channel value, wt_global represent corresponding first weight in the first area, and med_u represents the image in the first area U channel values after medium filtering;
According to the following formula to the V after the image median filter in the V channel values and the first area of first pixel Channel value is weighted average:
Fcc_v=(wt_global*cur_v+ (total-wt_global) * med_v)/total
Wherein, fcc_v represents the false colour corrected value of the first pixel V passages, and cur_v represents the V of first pixel Channel value, med_v represent the V channel values after the image median filter in the first area.
CN201711352453.0A 2017-10-19 2017-12-15 A kind of image processing method and device Active CN108124141B (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
CN201711352453.0A CN108124141B (en) 2017-12-15 2017-12-15 A kind of image processing method and device
EP18868765.1A EP3688981B1 (en) 2017-10-19 2018-10-16 Methods and devices for processing images
PCT/CN2018/110341 WO2019076278A1 (en) 2017-10-19 2018-10-16 Methods and devices for processing images
US16/852,575 US11399167B2 (en) 2017-10-19 2020-04-20 Methods and devices for processing images

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711352453.0A CN108124141B (en) 2017-12-15 2017-12-15 A kind of image processing method and device

Publications (2)

Publication Number Publication Date
CN108124141A true CN108124141A (en) 2018-06-05
CN108124141B CN108124141B (en) 2019-09-17

Family

ID=62229139

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711352453.0A Active CN108124141B (en) 2017-10-19 2017-12-15 A kind of image processing method and device

Country Status (1)

Country Link
CN (1) CN108124141B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109493307A (en) * 2018-10-16 2019-03-19 西安邮电大学 A kind of image Alpha mixed method based on floating-point pixel data
WO2019076278A1 (en) * 2017-10-19 2019-04-25 Zhejiang Dahua Technology Co., Ltd. Methods and devices for processing images
CN111340894A (en) * 2019-09-27 2020-06-26 杭州海康慧影科技有限公司 Image processing method and device and computer equipment

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02100494A (en) * 1988-10-07 1990-04-12 Fuji Photo Film Co Ltd Regenerative device for fm modulated video signal
CN101282485A (en) * 2007-04-05 2008-10-08 索尼株式会社 Image processing device
US20090136150A1 (en) * 2007-11-26 2009-05-28 Micron Technology, Inc. Method and apparatus for reducing image artifacts based on aperture-driven color kill with color saturation assessment
CN101478687A (en) * 2008-01-04 2009-07-08 华晶科技股份有限公司 Correcting method for pseudo color pixel in digital image
CN103202022A (en) * 2010-11-08 2013-07-10 佳能株式会社 Image processing apparatus and control method of the same
CN103747222A (en) * 2013-12-27 2014-04-23 上海富瀚微电子有限公司 Method and apparatus for suppressing color artifact of image
TWI524729B (en) * 2013-11-19 2016-03-01 瑞昱半導體股份有限公司 A real-time false color reduction system and method for color interpolation
CN105809644A (en) * 2016-03-15 2016-07-27 深圳英飞拓科技股份有限公司 Image edge false color inhabitation method and apparatus
CN106303483A (en) * 2015-05-20 2017-01-04 浙江大华技术股份有限公司 A kind of image processing method and device

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02100494A (en) * 1988-10-07 1990-04-12 Fuji Photo Film Co Ltd Regenerative device for fm modulated video signal
CN101282485A (en) * 2007-04-05 2008-10-08 索尼株式会社 Image processing device
US20090136150A1 (en) * 2007-11-26 2009-05-28 Micron Technology, Inc. Method and apparatus for reducing image artifacts based on aperture-driven color kill with color saturation assessment
CN101478687A (en) * 2008-01-04 2009-07-08 华晶科技股份有限公司 Correcting method for pseudo color pixel in digital image
CN103202022A (en) * 2010-11-08 2013-07-10 佳能株式会社 Image processing apparatus and control method of the same
TWI524729B (en) * 2013-11-19 2016-03-01 瑞昱半導體股份有限公司 A real-time false color reduction system and method for color interpolation
CN103747222A (en) * 2013-12-27 2014-04-23 上海富瀚微电子有限公司 Method and apparatus for suppressing color artifact of image
CN106303483A (en) * 2015-05-20 2017-01-04 浙江大华技术股份有限公司 A kind of image processing method and device
CN105809644A (en) * 2016-03-15 2016-07-27 深圳英飞拓科技股份有限公司 Image edge false color inhabitation method and apparatus

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019076278A1 (en) * 2017-10-19 2019-04-25 Zhejiang Dahua Technology Co., Ltd. Methods and devices for processing images
US11399167B2 (en) 2017-10-19 2022-07-26 Zhejiang Dahua Technology Co., Ltd. Methods and devices for processing images
CN109493307A (en) * 2018-10-16 2019-03-19 西安邮电大学 A kind of image Alpha mixed method based on floating-point pixel data
CN109493307B (en) * 2018-10-16 2021-10-15 西安邮电大学 Image Alpha mixing method based on floating point pixel data
CN111340894A (en) * 2019-09-27 2020-06-26 杭州海康慧影科技有限公司 Image processing method and device and computer equipment
CN111340894B (en) * 2019-09-27 2023-07-14 杭州海康慧影科技有限公司 Image processing method, device and computer equipment

Also Published As

Publication number Publication date
CN108124141B (en) 2019-09-17

Similar Documents

Publication Publication Date Title
US9569827B2 (en) Image processing apparatus and method, and program
US9143657B2 (en) Color enhancement technique using skin color detection
EP1400921B1 (en) Enhancing the tonal characteristics of digital images using inflection points in a tone scale function
Weeks et al. Histogram specification of 24-bit color images in the color difference (CY) color space
CN104809694B (en) Digital image processing method and device
CN108124141B (en) A kind of image processing method and device
US7649653B2 (en) Processing apparatus and method for enhancing image color
Jang et al. Adaptive color enhancement based on multi-scaled Retinex using local contrast of the input image
CN105915909A (en) High-dynamic-range image layered compression method
Chandrasekharan et al. Fuzzy transform for contrast enhancement of nonuniform illumination images
CN106485674A (en) A kind of low light image Enhancement Method based on integration technology
US6931152B2 (en) Method for improved automatic partial color constancy correction
Morel et al. Fast implementation of color constancy algorithms
KR100888429B1 (en) Image brightness controlling apparatus and method thereof
CN114037641A (en) Low-illumination image enhancement method, device, equipment and medium
Jang et al. Color correction by estimation of dominant chromaticity in multi-scaled retinex
Viswanath Enhancement of brain tumor images
Kim et al. Color saturation compensation in iCAM06 for high-chroma HDR imaging
CN116309146A (en) Retinex-based edge-preserving color low-illumination image enhancement method
Sun et al. Luminance based MSR for color image enhancement
CN107833256A (en) Method and device for the pseudo- coloring of digital picture
Kyung et al. Color enhancement for faded images based on multi-scale gray world algorithm
Chen et al. Improved visibility of single hazy images captured in inclement weather conditions
CN113256533A (en) Self-adaptive low-illumination image enhancement method and system based on MSRCR
US7557953B2 (en) Image processing device and image processing method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant