Summary of the invention
The present invention proposes a kind of evaluating method and device of picture quality, according to human visual system's loss of characteristic comprehensive evaluating spatial domain and frequency domain loss, has improved the consistency of objective evaluating and subjective evaluation result, has improved the accuracy of evaluation result.
Technical scheme of the present invention is achieved in that
A kind of evaluating method of picture quality comprises:
Calculating with respect to the loss of reference picture on spatial domain, is obtained described by the spatial domain loss result of altimetric image by altimetric image;
Calculate described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described by the frequency domain loss result of altimetric image;
Obtained described according to described by the described spatial domain loss result of altimetric image and described frequency domain loss result by the mass fraction of altimetric image.
Preferably, described calculating, is obtained described spatial domain loss result by altimetric image and comprises with respect to the loss of reference picture on spatial domain by altimetric image:
Calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image;
Calculate describedly, obtain described tested edge of image loss result by the edge penalty of altimetric image with respect to described reference picture;
Obtained described according to described by the described luminance loss result of altimetric image and described edge penalty result by the spatial domain loss result of altimetric image.
Preferably, describedly obtained described spatial domain loss result by the described luminance loss result of altimetric image and described edge penalty result and comprise by altimetric image according to described:
Give described by the described luminance loss result of altimetric image and the described edge penalty result ratio that assigns weight;
According to described by the described luminance loss result of altimetric image and weight thereof than and described edge penalty result and weight thereof more described than acquisition by the spatial domain loss result of altimetric image.
Preferably, described luminance loss result's weight is than the weight ratio greater than described edge penalty result.
Preferably, according to the PSNR method calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image.
Preferably, described calculating described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described frequency domain loss result and comprise by altimetric image:
With described reference picture with describedly changed to frequency domain from transform of spatial domain by altimetric image;
Calculate describedly, obtain described by the loss of contrast result of altimetric image by the loss of contrast of altimetric image with respect to described reference picture;
Obtain described by the frequency domain loss result of altimetric image according to described loss of contrast result.
Preferably, described in described calculating by the edge penalty of altimetric image with respect to described reference picture, obtain also to comprise before the described tested edge of image loss result:
Carried out rim detection to described by altimetric image and described reference picture.
Preferably, in described calculating by altimetric image with respect to the loss of reference picture on spatial domain, obtain describedly also to be comprised before the spatial domain loss result of altimetric image:
Whether by altimetric image and described reference picture be YUV color gamut, if then enter next step if judging described;
Otherwise be transformed into the YUV color gamut with described by altimetric image and described reference picture, and then enter next step.
Preferably, according to the dct transform method with described reference picture with describedly changed to frequency domain from transform of spatial domain by altimetric image.
Preferably, describedly obtained described mass fraction by the described spatial domain loss result of altimetric image and described frequency domain loss result and comprise by altimetric image according to described:
Give described by the described spatial domain loss result of altimetric image and the described frequency domain loss result ratio that assigns weight;
According to described by the described spatial domain loss result of altimetric image and weight thereof than and described frequency domain loss result and weight thereof more described than acquisition by the mass fraction of altimetric image.
A kind of evaluating apparatus of picture quality comprises:
First processing unit is used to calculate by altimetric image with respect to the loss of reference picture on spatial domain, obtains described by the spatial domain loss result of altimetric image;
Second processing unit, be used to calculate described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described by the frequency domain loss result of altimetric image;
The 3rd processing unit is used for being obtained described by the mass fraction of altimetric image according to described by the described spatial domain loss result of altimetric image and described frequency domain loss result.
Preferably, described first processing unit comprises:
Manages the unit everywhere, be used to calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image;
The 5th processing unit is used to calculate described by the edge penalty of altimetric image with respect to described reference picture, obtains described tested edge of image loss result;
The 6th processing unit is used for being obtained described by the spatial domain loss result of altimetric image according to described by the described luminance loss result of altimetric image and described edge penalty result.
Preferably, described first processing unit also comprises:
The first weight allocation unit is used for to described by the described luminance loss result of altimetric image and the described edge penalty result ratio that assigns weight;
Described the 6th processing unit according to described by the described luminance loss result of altimetric image and weight thereof than and described edge penalty result and weight thereof more described than acquisition by the spatial domain loss result of altimetric image.
Preferably, described luminance loss result's weight is than the weight ratio greater than described edge penalty result.
Preferably, described the 5th processing unit also comprises:
Edge detection unit is used for being carried out rim detection to described by altimetric image and described reference picture.
Preferably, described second processing unit comprises:
First converting unit is used for described reference picture and is describedly changed to frequency domain by altimetric image from transform of spatial domain;
The 7th processing unit is used to calculate described by the loss of contrast of altimetric image with respect to described reference picture, obtains described by the loss of contrast result of altimetric image;
The 8th processing unit is used for obtaining according to described loss of contrast result described by the frequency domain loss result of altimetric image.
Preferably, described image quality evaluating device also comprises:
Second converting unit is used for when not being the YUV color gamut by altimetric image and described reference picture, being transformed into the YUV color gamut with described by altimetric image and described reference picture when described.
Preferably, described image quality evaluating device also comprises:
The second weight allocation unit is used for to described by the described spatial domain loss result of altimetric image and the described frequency domain loss result ratio that assigns weight;
Described the 3rd processing unit according to described by the described spatial domain loss result of altimetric image and weight thereof than and described frequency domain loss result and weight thereof more described than acquisition by the mass fraction of altimetric image.
Technical solution of the present invention is according to human visual system's characteristic, comprehensive evaluating picture quality is in loss on the spatial domain and the loss on the frequency domain, quality according to spatial domain loss and frequency domain loss comprehensive evaluating image, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
Embodiment
For making the purpose, technical solutions and advantages of the present invention express clearlyer, the present invention is further described in more detail below in conjunction with drawings and the specific embodiments.
With reference to Fig. 1, show the flow chart of a kind of image quality evaluating method first embodiment of the present invention, comprise step:
Step 110, calculating with respect to the loss of reference picture on spatial domain, are obtained described by the spatial domain loss result of altimetric image by altimetric image.
Step 120, calculate described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described by the frequency domain loss result of altimetric image.
Step 130, obtained described by the described spatial domain loss result of altimetric image and described frequency domain loss result by the mass fraction of altimetric image according to described.
Described mass fraction can be the concrete numerical value of a reflection picture quality, also can be the evaluation of a picture quality.
Wherein, with reference to Fig. 2, described step 110 preferably includes following steps:
Step 210, calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image.
Human visual system (HVS, Human Visual System) is responsive more to the sensation comparison color of brightness.
Calculating is had much by the method for altimetric image with respect to the loss of reference picture on luminance component, the embodiment of the invention preferably according to the PSNR method calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image.Described PSNR method can be expressed as:
Wherein, the pixel quantity of M * N presentation video, the i.e. size of image, o
M, nBe the point in the reference picture (m, pixel value n); r
M, nFor (m, pixel value n), A are o by the point in the altimetric image
M, nIn maximum, get 255 usually.
Step 220, calculate describedly, obtain described tested edge of image loss result by the edge penalty of altimetric image with respect to described reference picture.
The human visual system is also very sensitive to the loss at edge, and regular meeting adds the edge enhancing in image processing process, increases the stereovision of image; The present invention can utilize edge detecting technology to detect edge of image earlier, calculates by the edge penalty of altimetric image with respect to described reference picture, obtains described tested edge of image loss result.Calculating is also had much by the method for altimetric image with respect to the reference picture edge penalty, as PSNR method etc.
In this step, can utilize evaluate parameters such as Sobel operator, Canny operator, Prewitt operator earlier, carry out edge extracting, compare both edges then, the comparative result that obtains quantizing to reference picture with by altimetric image.
Step 230, obtained described by the described luminance loss result of altimetric image and described edge penalty result by the spatial domain loss result of altimetric image according to described.
The embodiment of the invention is preferably described by the spatial domain loss result of altimetric image according to luminance loss result and the comprehensive acquisition of edge penalty result, it will be appreciated by those skilled in the art that, the factor that other calculate described tested image space territory loss result be can also increase, and described luminance loss and edge penalty not only only limited.
The embodiment of the invention is preferably: give described by the described luminance loss result of altimetric image and the described edge penalty result ratio that assigns weight, according to described by the described luminance loss result of altimetric image and weight thereof than and described edge penalty result and weight thereof more described than obtaining by the spatial domain loss result of altimetric image.
In order to meet human visual system's characteristic more, the embodiment of the invention preferably: described luminance loss result's weight is than the weight ratio greater than described edge penalty result.
Wherein, with reference to Fig. 3, described step 120 preferably includes following steps:
Step 310, with described reference picture with describedly changed to frequency domain from transform of spatial domain by altimetric image.
Described reference picture and the described method of being changed to frequency domain from transform of spatial domain by altimetric image are had a lot, as fourier transform method, dct transform method etc., the embodiment of the invention is the dct transform method preferably.
Step 320, calculate describedly, obtain described by the loss of contrast result of altimetric image by the loss of contrast of altimetric image with respect to described reference picture.
In the embodiment of the invention, with the factor of the loss of contrast as the territory loss of the described tested picture frequency of measurement, it will be appreciated by those skilled in the art that, can also be with other factors as the factor of weighing the loss of described tested picture frequency territory, it is described by the loss of the frequency domain of altimetric image also can to increase other combined factors evaluation and tests, and the present invention does not limit this.
Step 330, obtain according to described loss of contrast result described by the frequency domain loss result of altimetric image.
When having only this factor of contrast, then described loss of contrast result is described by the frequency domain loss result of altimetric image, when a plurality of factor, as as described in contrast factor and the evaluation and test of other combined factors during, then obtain described by the frequency domain loss result of altimetric image according to described loss of contrast result and other factor by the frequency domain loss result of image.
Objective evaluating of the prior art is is normally evaluated and tested on luminance component, and the evaluation and test factor is single, and therefore inconsistent with the subjectivity evaluation and test, evaluation result is inaccurate.The embodiment of the invention is according to human visual system's characteristic, comprehensive evaluating picture quality is in loss on the spatial domain and the loss on the frequency domain, quality according to spatial domain loss and frequency domain loss comprehensive evaluating image, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
Further, the spatial domain evaluation and test comprises evaluation and test and the edge evaluation and test on the luminance component again, the frequency domain evaluation and test comprises the contrast evaluation and test again, from multifactor comprehensive evaluating picture quality, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
With reference to Fig. 4, show the method flow diagram of a kind of image quality evaluating method second embodiment of the present invention, comprise step:
Step 410, will be transformed into the YUV color gamut from other color gamut by altimetric image and reference picture.
In the shades of colour territory of image, YUV (YCrCb, a kind of colour coding method that is adopted by the eurovision system) color gamut is the color gamut that relatively meets human visual system's characteristic, so the embodiment of the invention is preferably carried out the evaluation and test of picture quality on the YUV color gamut.
Judge at first whether by altimetric image and reference picture be the YUV color gamut, if not, then will be transformed into the YUV color gamut from other color gamut by altimetric image and reference picture, other color gamut comprises RGB (red, green, blue, Red Green Blue) color gamut etc.
Below being that example describes from the RGB color conversion to the YUV color gamut:
Y is brightness (Luminance/Luma) component of image, uses following formula to calculate, and is the weighted average of R, G, B component:
Y=kr?R+kg?G+kb?B
Wherein k is a weight factor.
Top formula has calculated monochrome information, also has colouring information in the YUV color gamut, uses aberration (Color difference/Chrominance or Chroma) expression, and wherein each color difference components is the difference of R, G, B value and brightness Y:
Cb=B-Y
Cr=R-Y
Cg=G-Y
Wherein, Cb+Cr+Cg is a constant (being that an expression about Y is shown in fact).Suggestion is when calculating Y, and weight is chosen as kr=0.299, kg=0.587, kb=0.114.So conversion formula is as follows:
Y=0.299R+0.587G+0.114B
Cb=0.564(B-Y)
Cr=0.713(R-Y)
R=Y+1.402Cr
G=Y-0.344Cb-0.714Cr
B=Y+1.772Cb
By above formula, image can be transformed into the YUV color gamut from the RGB color gamut.For other color gamut, corresponding conversion method is all arranged in the prior art, do not repeat them here.
Step 420, calculating with respect to the loss of reference picture on spatial domain, are obtained described by the spatial domain loss result of altimetric image by altimetric image.
Described calculating, is obtained described concrete steps and the principle that is comprised by the spatial domain loss result of altimetric image and describes in detail in embodiment one with respect to the loss of reference picture on spatial domain by altimetric image, does not repeat them here.
Step 430, calculate described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described by the frequency domain loss result of altimetric image.
Described calculating described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described concrete steps and the principle that is comprised by the frequency domain loss result of altimetric image and in embodiment one, describe in detail, do not repeat them here.
Step 440, give described by the described spatial domain loss result of altimetric image and the described frequency domain loss result ratio that assigns weight.
Step 450, according to described by the described spatial domain loss result of altimetric image and weight thereof than and described frequency domain loss result and weight thereof more described than obtaining by the mass fraction of altimetric image.
Described mass fraction can be the concrete numerical value of a reflection picture quality, also can be the evaluation of a picture quality.
Objective evaluating of the prior art being is normally is being evaluated and tested on evaluation and test or the luminance component on the RGB color gamut, and the evaluation and test factor is single, and therefore inconsistent with the subjectivity evaluation and test, evaluation result is inaccurate.The embodiment of the invention is according to human visual system's characteristic, comprehensive evaluating picture quality is in loss on the spatial domain and the loss on the frequency domain on more near the YUV color gamut of human visual system's characteristic, quality according to spatial domain loss and frequency domain loss comprehensive evaluating image, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
Further, the spatial domain evaluation and test comprises evaluation and test and the edge evaluation and test on the luminance component again, the frequency domain evaluation and test comprises the contrast evaluation and test again, from multifactor comprehensive evaluating picture quality, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
With reference to Fig. 5, show the composition structure chart of a kind of image quality evaluating device first embodiment of the present invention, described image quality evaluating device 500 comprises:
First processing unit 510, be used to calculate by altimetric image, obtain described by the spatial domain loss result of altimetric image with respect to the loss of reference picture on spatial domain.
Second processing unit 520, be used to calculate described by altimetric image with respect to the loss of described reference picture on frequency domain, obtain described by the frequency domain loss result of altimetric image.
The 3rd processing unit 530, be used for being obtained described by the described spatial domain loss result of altimetric image and described frequency domain loss result by the mass fraction of altimetric image according to described.
Wherein, with reference to Fig. 6, described first processing unit 510 comprises:
Manage unit 511 everywhere, be used to calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image.
Human visual system (HVS, Human Visual System) is responsive more to the sensation comparison color of brightness.
Described the manages unit 511 everywhere calculates and is had much by the method for altimetric image with respect to the loss of reference picture on luminance component, the embodiment of the invention preferably according to the PSNR method calculate described by altimetric image with respect to the loss of described reference picture on luminance component, obtain described by the luminance loss result of altimetric image.
The 5th processing unit 512, be used to calculate described, obtain described tested edge of image loss result by the edge penalty of altimetric image with respect to described reference picture.
The human visual system is also very sensitive to the loss at edge, and regular meeting adds the edge enhancing in image processing process, increases the stereovision of image.Therefore, the 5th processing unit 512 also comprises described in the embodiment of the invention: edge detection unit is used for being carried out rim detection to described by altimetric image and described reference picture.The present invention can utilize edge detecting technology to detect edge of image earlier, calculates by the edge penalty of altimetric image with respect to described reference picture, obtains described tested edge of image loss result.Described the 5th processing unit 512 calculates also to be had much by the method for altimetric image with respect to the reference picture edge penalty, as the PSNR method etc.
The 6th processing unit 513, be used for being obtained described by the described luminance loss result of altimetric image and described edge penalty result by the spatial domain loss result of altimetric image according to described.
Further, described first processing unit 510 also comprises:
The first weight allocation unit 514, be used for to described by the described luminance loss result of altimetric image and the described edge penalty result ratio that assigns weight;
Described the 6th processing unit 513 according to described by the described luminance loss result of altimetric image and weight thereof than and described edge penalty result and weight thereof more described than acquisition by the spatial domain loss result of altimetric image.
Near human visual system's feature, described luminance loss result's weight is than the weight ratio greater than described edge penalty result for more.
Wherein, with reference to Fig. 7, described second processing unit 520 comprises:
First converting unit 521, be used for described reference picture and describedly changed to frequency domain from transform of spatial domain by altimetric image.
Described first converting unit 521 has described reference picture and the described method of being changed to frequency domain from transform of spatial domain by altimetric image a lot, as fourier transform method, and dct transform method etc., the embodiment of the invention is the dct transform method preferably.
The 7th processing unit 522, be used to calculate described, obtain described by the loss of contrast result of altimetric image by the loss of contrast of altimetric image with respect to described reference picture.
In the embodiment of the invention, with the factor of the loss of contrast as the territory loss of the described tested picture frequency of measurement, it will be appreciated by those skilled in the art that, can also be with other factors as the factor of weighing the loss of described tested picture frequency territory, it is described by the loss of the frequency domain of altimetric image also can to increase other combined factors evaluation and tests, and the present invention does not limit this.
The 8th processing unit 523, be used for obtaining according to described loss of contrast result described by the frequency domain loss result of altimetric image.
When having only this factor of contrast, then described loss of contrast result is described by the frequency domain loss result of altimetric image, when a plurality of factor, as as described in contrast factor and the evaluation and test of other combined factors during, then obtain described by the frequency domain loss result of altimetric image according to described loss of contrast result and other factor by the frequency domain loss result of image.
Further, described image quality evaluating device 500 also comprises:
Second converting unit 540, be used for when not being the YUV color gamut, being transformed into the YUV color gamut by altimetric image and described reference picture with described by altimetric image and described reference picture when described.
In the shades of colour territory of image, YUV (YCrCb, a kind of colour coding method that is adopted by the eurovision system) color gamut is the color gamut that relatively meets human visual system's characteristic, so the embodiment of the invention is preferably carried out the evaluation and test of picture quality on the YUV color gamut.
The second weight allocation unit 550, be used for to described by the described spatial domain loss result of altimetric image and the described frequency domain loss result ratio that assigns weight.
Described the 3rd processing unit 530 according to described by the described spatial domain loss result of altimetric image and weight thereof than and described frequency domain loss result and weight thereof more described than acquisition by the mass fraction of altimetric image.
Objective evaluating of the prior art being is normally is being evaluated and tested on evaluation and test or the luminance component on the RGB color gamut, and the evaluation and test factor is single, and therefore inconsistent with the subjectivity evaluation and test, evaluation result is inaccurate.The embodiment of the invention is according to human visual system's characteristic, comprehensive evaluating picture quality is in loss on the spatial domain and the loss on the frequency domain on more near the YUV color gamut of human visual system's characteristic, quality according to spatial domain loss and frequency domain loss comprehensive evaluating image, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
Further, the spatial domain evaluation and test comprises evaluation and test and the edge evaluation and test on the luminance component again, the frequency domain evaluation and test comprises the contrast evaluation and test again, from multifactor comprehensive evaluating picture quality, thereby obtain the evaluation result of more close subjective evaluation and test, improve the consistency of objective evaluating and subjective evaluation result, improved the accuracy of evaluation result.
Described device embodiment is corresponding with described method embodiment, and therefore, the description of appropriate section gets final product in the part reference method embodiment that device embodiment part is not described in detail.
One of ordinary skill in the art will appreciate that, realize that all or part of step in the foregoing description method is to instruct relevant hardware to finish by program, described program can be stored in the computer read/write memory medium, this program is when carrying out, comprise step as above-mentioned method embodiment, described storage medium, as: ROM/RAM, magnetic disc, CD etc.In the inventive method embodiment, the priority sequence number of described step can not be used to limit the sequencing of each step.Each step can be carried out simultaneously or also can carry out with other order.
The above only is preferred embodiment of the present invention, and is in order to restriction the present invention, within the spirit and principles in the present invention not all, any modification of being done, is equal to replacement, improvement etc., all should be included within protection scope of the present invention.