CN113365060B - Image filtering method, device, equipment and storage medium - Google Patents

Image filtering method, device, equipment and storage medium Download PDF

Info

Publication number
CN113365060B
CN113365060B CN202110559418.6A CN202110559418A CN113365060B CN 113365060 B CN113365060 B CN 113365060B CN 202110559418 A CN202110559418 A CN 202110559418A CN 113365060 B CN113365060 B CN 113365060B
Authority
CN
China
Prior art keywords
parameter
filtering
image
distortion value
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110559418.6A
Other languages
Chinese (zh)
Other versions
CN113365060A (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.)
Beijing QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and 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 Beijing QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN202110559418.6A priority Critical patent/CN113365060B/en
Publication of CN113365060A publication Critical patent/CN113365060A/en
Application granted granted Critical
Publication of CN113365060B publication Critical patent/CN113365060B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/117Filters, e.g. for pre-processing or post-processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/80Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation
    • H04N19/82Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation involving filtering within a prediction loop

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The embodiment of the invention provides an image filtering method, an image filtering device, image filtering equipment and a storage medium, wherein the image filtering method comprises the following steps: grouping pre-acquired filtering parameters according to values of the first filtering radius and the second filtering radius; selecting a filtering parameter of a reference coefficient in a preset sequence in a group to which the reference coefficient belongs as a candidate parameter of the group; filtering the preset images by using the candidate parameters respectively, calculating distortion values between the filtered images corresponding to the candidate parameters and the original images, and taking the group of the candidate parameters corresponding to the filtered images with the lowest distortion values as a target group; and filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering image with the lowest distortion value as a filtering result of the preset image. In this way, the time consumed for determining the target parameters required for filtering the preset image and for filtering the preset image can be reduced.

Description

Image filtering method, device, equipment and storage medium
Technical Field
The present invention relates to the field of video coding technologies, and in particular, to an image filtering system, method, apparatus, device, and storage medium.
Background
Video coding refers to a technology for converting a file in an original video format into a file in another video format by a compression technology, and loop filtering is an important process in video coding. AV1 is the first generation video coding standard developed by AOM (Alliance for Open Media), and a new Self-Guided filtering (Self-Guided Filter) technology was introduced in the loop filtering process in AV 1.
The guided filtering is an image filtering technique adopted in the AV1 standard, and performs filtering processing on an input image P through a guide map G to obtain an output image Q. The guiding filtering can realize the edge smoothness of bilateral filtering, has good performance near the detected edge, and can be applied to scenes such as image enhancement, image matting, image defogging and the like. When the guide map G is identical to the input image P, the guided filtering may be referred to as an auto-guided filtering, which is a filtering operation that preserves edges and may be used for image reconstruction.
The result of the self-directed filtering is determined by 6 parameters r1,e1,r2,e2α, β, and the values of these parameters are different, the filtering results obtained will also be different, wherein r1 representsThe first filtering radius, e1 represents the regularization coefficient corresponding to r1, r2 represents the second filtering radius, e2 represents the regularization coefficient corresponding to r2, α represents the scale transformation factor, β represents the offset added to the scaled value, and α and β are parameters carried in the video stream.
In the AV1 standard, { r1,e1,r2,e216 combinations exist, when the self-guided filtering is performed on the image to be processed, 16 combinations need to be traversed to respectively obtain corresponding filtering results, and then a filtering parameter with the lowest distortion degree with the image to be processed is selected from the filtering results and used as an optimal solution for the self-guided filtering performed on the image to be processed, so that a large amount of time and computing resources are consumed in the self-guided filtering process, and the efficiency is low.
Disclosure of Invention
An object of embodiments of the present invention is to provide an image filtering method, apparatus, device and storage medium, so as to reduce time required for determining a self-guided filtering parameter and filtering an image to be processed. The specific technical scheme is as follows:
in a first aspect of the present invention, there is provided an image filtering method, including:
grouping pre-acquired filter parameters according to values of a first filter radius and a second filter radius to obtain a grouping result, wherein each filter parameter comprises the first filter radius, a first regularization coefficient corresponding to the first filter radius, the second filter radius and a second regularization coefficient corresponding to the second filter radius, the first filter radius of the filter parameters in the first group is 0, the second filter radius of the filter parameters in the second group is 0, and the first filter radius and the second filter radius of the filter parameters in the third group are not 0;
selecting a filter parameter with a reference coefficient located in a preset sequence in the group to which the reference coefficient belongs as a candidate parameter of the group, wherein the preset sequence is an integer closest to one-half of the number of the filter parameters in the group to which the reference coefficient belongs, the reference coefficient is the second regularization coefficient in the first group, the first regularization coefficient in the second group, and the first regularization coefficient or the second regularization coefficient in the third group;
respectively filtering the preset images by using the candidate parameters, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, and taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group, wherein the original image is the image of the preset image before video coding;
and filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering image with the lowest distortion value as a filtering result of the preset image.
Optionally, the step of filtering the preset image by using other filtering parameters in the target packet, calculating a distortion value between the original image and the filtered image corresponding to each filtering parameter in the target packet, and taking the filtered image with the lowest distortion value as a filtering result of the preset image includes:
filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as a target parameter;
and filtering the video to be processed by utilizing the target parameters to obtain a filtering result of the video to be processed.
Optionally, the filtering the preset image by using other filtering parameters in the target packet, calculating a distortion value between the filtered image corresponding to each filtering parameter in the target packet and the original image, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter includes:
taking the candidate parameter of the target packet as a first parameter, and selecting a filtering parameter which is ordered at the next bit of the first parameter in the target packet as a second parameter;
filtering the preset image by using the second parameter, and calculating a distortion value between the filtered image corresponding to the second parameter and the original image;
if the distortion value corresponding to the second parameter is lower than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced after the second parameter in the target grouping, comparing the obtained distortion value of the filtered image with the distortion value of the filtered image corresponding to the second parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter;
if the distortion value corresponding to the second parameter is higher than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced in the target group before the first parameter, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter.
Optionally, the filtering the preset image by using the filtering parameters sequenced after the second parameter in the target packet, comparing the distortion value of the obtained filtered image with the distortion value of the filtered image corresponding to the second parameter, and using the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter includes:
and taking the second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the next bit of the first parameter in the target grouping as the second parameter, and taking the first parameter as the target parameter until the distortion value of the filtering image corresponding to the first parameter is lower than the distortion value of the filtering image corresponding to the second parameter or no new second parameter exists.
Optionally, the filtering the preset image by using the filtering parameter sequenced before the first parameter in the target packet, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and using the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter includes:
selecting a filtering parameter which is sequenced one bit before the first parameter in the target grouping as a new second parameter;
filtering the preset image by using the new second parameter, and comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter;
and if the distortion value of the filtered image corresponding to the new second parameter is lower than the distortion value of the filtered image corresponding to the first parameter, taking the new second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the front position of the first parameter in the target group and is used as a new second parameter, and taking the first parameter as the target parameter until the distortion value of the filtered image corresponding to the first parameter is lower than the distortion value of the filtered image corresponding to the new second parameter or no new second parameter exists.
In a second aspect of the present invention, there is also provided an image filtering apparatus, comprising:
the grouping module is used for grouping pre-acquired filter parameters according to values of a first filter radius and a second filter radius to obtain a grouping result, wherein each filter parameter comprises the first filter radius, a first regularization coefficient corresponding to the first filter radius, a second regularization coefficient corresponding to the second filter radius and a second regularization coefficient corresponding to the second filter radius, the value of the first filter radius of the filter parameters in the first group is 0, the value of the second filter radius of the filter parameters in the second group is 0, and the values of the first filter radius and the second filter radius of the filter parameters in the third group are not 0;
a selection module, configured to select, as a candidate parameter of the group, a filter parameter of which a reference coefficient is located in a preset ordering in the group to which the reference coefficient belongs, where the preset ordering is an integer closest to one-half of the number of filter parameters in the group to which the reference coefficient belongs, the reference coefficient is the second regularization coefficient in the first group, the reference coefficient is the first regularization coefficient in the second group, and the reference coefficient is the first regularization coefficient or the second regularization coefficient in the third group;
the comparison module is used for filtering the preset image by using the candidate parameters respectively, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, and taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group, wherein the original image is an image of the preset image before video coding;
and the determining module is used for filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtered image corresponding to each filtering parameter in the target group and the original image, and taking the filtered image with the lowest distortion value as a filtering result of the preset image.
Optionally, the preset image is an image in a video to be processed, and the determining module is specifically configured to:
filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as a target parameter;
and filtering the video to be processed by utilizing the target parameters to obtain a filtering result of the video to be processed.
Optionally, the determining module is configured to:
taking the candidate parameter of the target packet as a first parameter, and selecting a filtering parameter which is ordered at the next bit of the first parameter in the target packet as a second parameter;
filtering the preset image by using the second parameter, and calculating a distortion value between the filtered image corresponding to the second parameter and the original image;
if the distortion value corresponding to the second parameter is lower than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced after the second parameter in the target grouping, comparing the obtained distortion value of the filtered image with the distortion value of the filtered image corresponding to the second parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter;
if the distortion value corresponding to the second parameter is higher than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced in the target group before the first parameter, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter.
Optionally, the determining module is configured to:
and taking the second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the next bit of the first parameter in the target grouping as the second parameter, and taking the first parameter as the target parameter until the distortion value of the filtering image corresponding to the first parameter is lower than the distortion value of the filtering image corresponding to the second parameter or no new second parameter exists.
Optionally, the determining module is configured to:
selecting a filtering parameter which is sequenced one bit before the first parameter in the target grouping as a new second parameter;
filtering the preset image by using the new second parameter, and comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter;
and if the distortion value of the filtered image corresponding to the new second parameter is lower than the distortion value of the filtered image corresponding to the first parameter, taking the new second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the front position of the first parameter in the target group and is used as a new second parameter, and taking the first parameter as the target parameter until the distortion value of the filtered image corresponding to the first parameter is lower than the distortion value of the filtered image corresponding to the new second parameter or no new second parameter exists.
In another aspect of the present invention, there is also provided an electronic device, including a processor, a communication interface, a memory and a communication bus, where the processor, the communication interface, and the memory complete communication with each other through the communication bus;
a memory for storing a computer program;
and a processor for implementing any of the image filtering methods described above when executing the program stored in the memory.
In yet another aspect of the present invention, there is also provided a computer-readable storage medium having stored therein instructions, which when run on a computer, cause the computer to perform any of the image filtering or image filtering methods described above.
In yet another aspect of the present invention, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to perform any of the image filtering or image filtering methods described above.
In the image filtering method, the image filtering device, the image filtering apparatus and the storage medium provided by the embodiment of the present invention, the pre-obtained filtering parameters are grouped according to values of the first filtering radius and the second filtering radius; selecting a filter parameter of which the reference coefficient is positioned in a preset sequence in the group to which the reference coefficient belongs as a candidate parameter of the group, wherein the preset sequence is an integer which is closest to one-half of the number of the filter parameters in the group to which the reference coefficient belongs, the reference coefficient is a second regularization coefficient in the first group, is a first regularization coefficient in the second group, and is a first regularization coefficient or a second regularization coefficient in the third group; respectively filtering the preset image by using the candidate parameters, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group, wherein the original image is the image of the preset image before video coding; and filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering image with the lowest distortion value as a filtering result of the preset image. Therefore, by grouping the filtering parameters, the target group where the solution which can meet the filtering requirement is located is determined first, and then the filtering parameters which can meet the filtering requirement are determined from the target group.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below.
Fig. 1 is a schematic flowchart of an image filtering method according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a scheme of an image filtering method according to an embodiment of the present invention;
fig. 3 is a schematic structural diagram of an image filtering apparatus according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be described below with reference to the drawings in the embodiments of the present invention.
In the related art, when performing the self-guided filtering, 16 combinations of filtering parameters need to be traversed, and then the filtering parameter with the lowest distortion degree with the image to be processed is selected from the combinations as the optimal solution for performing the self-guided filtering on the image to be processed, so that the process of the self-guided filtering needs to consume a large amount of time and computing resources, and the efficiency is low.
In order to solve the above problem, embodiments of the present invention provide an image filtering method, an apparatus, a device, and a storage medium, and the following generally describes the image filtering method provided by the embodiments of the present invention, where the method includes:
grouping pre-acquired filter parameters according to values of a first filter radius and a second filter radius to obtain a grouping result, wherein each filter parameter comprises the first filter radius, a first regularization coefficient corresponding to the first filter radius, the second filter radius and a second regularization coefficient corresponding to the second filter radius, the first filter radius of the filter parameters in the first group is 0, the second filter radius of the filter parameters in the second group is 0, and the first filter radius and the second filter radius of the filter parameters in the third group are not 0;
selecting a filter parameter of which the reference coefficient is positioned in a preset sequence in the group to which the reference coefficient belongs as a candidate parameter of the group, wherein the preset sequence is an integer which is closest to one-half of the number of the filter parameters in the group to which the reference coefficient belongs, the reference coefficient is a second regularization coefficient in the first group, is a first regularization coefficient in the second group, and is a first regularization coefficient or a second regularization coefficient in the third group;
filtering a preset image in a video to be processed by using the candidate parameters respectively, calculating a distortion value between a filtered image corresponding to each candidate parameter and an original image, and taking a group in which the candidate parameter corresponding to the filtered image with the lowest distortion value is located as a target group, wherein the original image is an image of the preset image before video coding;
filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as a target parameter;
and filtering the video to be processed by utilizing the target parameters to obtain a filtering result of the video to be processed.
As can be seen from the above, in the scheme provided in the embodiment of the present invention, the filtering parameters are grouped, the target group in which the solution that can meet the filtering requirement is located is determined first, and then the filtering parameters that can meet the filtering requirement are determined from the target group.
The image filtering system provided by the embodiment of the present invention will be described in detail by specific embodiments.
As shown in fig. 1, which is a schematic flow chart of an image filtering method according to an embodiment of the present invention, the method includes the following steps:
s101: and grouping the pre-acquired filtering parameters according to the values of the first filtering radius and the second filtering radius to obtain a grouping result.
Guided filtering is an image filtering technique adopted in the AV1 standard, and performs filtering processing on an input image through a guide map to obtain a filtered image, and when the guide map is the same as the input image, the guided filtering may be referred to as self-guided filtering, which is a filtering operation that preserves edges and can be used for image reconstruction.
In the embodiment of the present invention, each filtering parameter includes a first filtering radius, a first regularization coefficient corresponding to the first filtering radius, a second filtering radius, and a second regularization coefficient corresponding to the second filtering radius, where the first filtering radius may be represented as r1The first regularization coefficient may be denoted as e1The second filter radius may be denoted as r2The second regularization coefficient may be denoted as e2I.e. the filter parameter is r1,e1,r2,e2}. The filtering parameters may be specified in a preset image processing standard, such as 16 combinations of filtering parameters defined in the AV1 standard, or may be input by the user according to the user's own needs. The pre-acquired filtering parameters are multiple, so that when different images are filtered, the filtering parameter with the best filtering effect can be selected to obtain a better filtering result.
In this step, the pre-obtained filtering parameters may be grouped according to values of the first filtering radius and the second filtering radius to obtain a grouping result, where the grouping result may include three groups, which are a first group, a second group, and a third group, respectively, where a value of the first filtering radius of the filtering parameters in the first group is 0, a value of the second filtering radius of the filtering parameters in the second group is 0, and values of the first filtering radius and the second filtering radius of the filtering parameters in the third group are not both 0.
In the self-guided filtering, the filtering may be performed using the following equation:
Xr=X+α(X1-X)+β(X2-X)
wherein X represents an input image, XrRepresenting the filtered image, X, of the filtered output1For X adopt r1And e1Filtering result obtained by filtering, X2For X adopt r2And e2Filtering result obtained by filtering, X1X may be referred to as A diagram, X2-X may be referred to as B-map.
With X1For example, the specific filtering process is as follows: first, the surrounding of each pixel in X is calculated (2 r)1+1)*(2r1+1) mean μ and variance σ of each pixel within the filtering window2Then, the coefficients a and b corresponding to each pixel are calculated using the following formula:
Figure BDA0003078376520000091
b=(1-a)μ
further, an average value of coefficients a and B of each pixel in a window of 3 × 3 around each pixel is calculated as coefficients a and B of the pixel, and X is filtered to obtain X1. Namely X1=AX+B。
It will be appreciated that in the first packet, r1A value of 0, X1Has a filter window radius of 0, then X1Is equal to X, X1X is 0, that is, the input image is filtered only according to the B-map, in this case, the filtering direction may be called B-direction, and the filtering formula may be simplified as:
Xr=X+β(X2-X)
in the second packet, r2A value of 0, X2Has a filter window radius of 0, then X2Is equal to X, X2X is 0, that is, the input image is filtered only according to the a-map, in this case, the filtering direction may be called the a-direction, and the filtering formula may be simplified as:
Xr=X+α(X1-X)
in the third grouping, r1And r2Values are not all 0, and meanwhile, filtering is carried out on the input image according to the A image and the B image, and at the moment, the filtering direction can be called bidirectional.
S102: and selecting the filter parameters of which the reference coefficients are positioned in a preset sequence in the group to which the reference coefficients belong as candidate parameters of the group, wherein the preset sequence is an integer closest to one-half of the number of the filter parameters in the group to which the reference coefficients belong, the reference coefficients are second regularization coefficients in the first group, are first regularization coefficients in the second group, and are first regularization coefficients or second regularization coefficients in the third group.
For example, may be in accordance with e1Or e2The order of the values of (a) determines a preset ordering, typically, e1Or e2Is proportional, that is, e1The higher the value of (A), the corresponding e2The higher the value of (a). In some cases, when r1When the value is 0, the corresponding e1The value is also likely to be 0, and similarly, when r is2When the value is 0, the corresponding e2The value is also likely to be 0, in this case, for the first group, the preset ordering may be determined in the order from small to large of the second regularization coefficient, for the second group, the preset ordering may be determined in the order from small to large of the first regularization coefficient, and for the third group, the preset ordering may be determined in the order from small to large of the first regularization coefficient or the second regularization coefficient.
For example, if the filtering parameters include m0, m2, … … and m15 in descending order, where m0 to m9 are bidirectional, r is1And r2All values are not 0, namely, in the third group, m 10-m 13 are in the B direction and r is in the r direction1Take a value of 0, i.e. the secondOne grouping, m 14-m 15 are A directions, r2Taking the value of 0, i.e., the second grouping, three grouping results can be obtained, wherein for the third grouping, the preset ordering is an integer closest to one-half of 10, i.e., 5, and then the candidate parameter of the grouping is m 4. Similarly, the preset sequence of the first packet is an integer closest to one-half of 4, that is, 2, the candidate parameter of the packet is m11, the preset sequence of the second packet is an integer closest to one-half of 2, and the candidate parameter of the packet may be m14 or m15, which is not limited in detail.
S103: and respectively filtering the preset images by using the candidate parameters, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, and taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group.
In this step, after determining the candidate parameters, the preset image may be filtered by using the candidate parameters, so as to obtain a filtered image corresponding to each candidate parameter.
After the filtered image corresponding to each candidate parameter is obtained, a distortion value between the filtered image corresponding to each candidate parameter and an original image can be calculated, a group in which the candidate parameter corresponding to the filtered image with the lowest distortion value is located is taken as a target group, and the original image is an image before a preset image is subjected to video coding.
It can be understood that during the encoding process of the video, some noise is generated, which causes some errors in the encoded image of the video compared with the original image, i.e. image distortion occurs, and the image filtering is used to reduce the noise in the image, so that the filtered image is closer to the effect of the original image. The distortion value may represent a distortion degree between the filtered image and the original image, for example, the quality of the filtering result may be a sum of squares of differences between the filtered image and the original image, and the lower the distortion value, the smaller a difference between the filtered image and the original image is, i.e., the better the filtering effect is.
In the embodiment of the present invention, if the candidate parameter used for filtering the preset image in the video to be processed is not an optimal solution, the distortion value between the obtained filtered image and the original image is not the lowest, in other words, under the condition that the optimal candidate parameter is not selected, the definition of the filtered image is sacrificed to a certain extent, but if the speed of filtering the preset image in the video to be processed is rapidly increased under the condition of sacrificing fewer filtered images, the performance of filtering the preset image in the video to be processed may be considered to be very good, and the obtained filtered image at this time may be considered to be sufficiently clear. That is to say, in this step, the group in which the candidate parameter corresponding to the filtered image with the lowest distortion value is located is taken as the target group, and the target group may not include the optimal solution of all the filtering parameters, but only the optimal solution of the filtering parameters in the target group needs to be further determined, so that the filtering parameters meeting the requirement can be obtained, and the effect of reducing the time for determining the optimal filtering parameters and further reducing the time consumed for filtering the video is achieved.
S104: and filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering image with the lowest distortion value as a filtering result of the preset image.
Therefore, the optimal solution is selected from one of the groups, and the filter parameters of other groups are not required to be traversed.
Further, filtering the preset image by using other filtering parameters in the target group, comparing the quality of each filtering result corresponding to the target group, and taking the filtering parameter with the highest quality as the target parameter, may include the following steps:
the first step is to take the candidate parameter of the target grouping as a first parameter, and select the filtering parameter of the next bit of the first parameter in the target grouping as a second parameter. For example, if m0-m 9 are included in the target group in the order of small to large, the target candidate parameter is m4, and the second parameter is the next bit of the target candidate parameter, i.e., m 5.
And secondly, filtering the preset image by using the second parameter, and calculating a distortion value between the filtered image corresponding to the second parameter and the original image. And if the distortion value corresponding to the second parameter is lower than the distortion value corresponding to the first parameter, executing the third step, otherwise, executing the fourth step.
And thirdly, filtering the preset image by using the filtering parameters sequenced after the second parameter in the target group, comparing the obtained distortion value of the filtering image with the distortion value of the filtering image corresponding to the second parameter, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as the target parameter.
That is, if the filtering result of m5 is better than m4, the preset image may be further filtered by m6 to m9 to obtain filtering results, and the filtering results of m6 to m9 and m5 are compared to obtain the highest quality filtering parameter as the target parameter. It will be appreciated that if the filtering result of m5 is better than m4, it can be considered that the smaller e1Or e2Presumably, where a smaller e can be tried1Or e2I.e. m6-m9, even if the optimal solution among all parameters is not found, the most appropriate filtering parameter can be found as soon as possible on the premise of sacrificing small definition, thereby improving the filtering speed.
The second parameter may be used as a new first parameter, and the step of selecting the filtering parameter that is ordered next to the first parameter in the target packet as the second parameter is returned, until the distortion value of the filtered image corresponding to the first parameter is lower than the distortion value of the filtered image corresponding to the second parameter, or no new second parameter exists, and then the first parameter is used as the target parameter.
For example, m5 may be used as a new target candidate parameter, m6 as a new second parameter, the filtering results of m5 and m6 are compared, if the filtering result of m6 is better than m5, m6 may be used as a new target candidate parameter, m7 as a new second parameter, the filtering results of m6 and m7 are compared, and so on until the quality of the filtering result corresponding to the target candidate parameter is higher than the quality of the filtering result corresponding to the second parameter, or the new target candidate parameter has no next filtering parameter, and the target candidate parameter is used as the target parameter.
And fourthly, filtering the preset image by using the filtering parameters which are sequenced in the target group before the first parameter, comparing the distortion value of the obtained filtering image with the distortion value corresponding to the first parameter, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as the target parameter.
That is, if the filtering result of m4 is better than m5, the preset image may be further filtered by m0 to m3 to obtain filtering results, and the filtering results of m0 to m3 and m4 are compared to obtain the highest quality filtering parameter as the target parameter.
Wherein, the filter parameter that is ordered one bit before the first parameter in the target packet can be selected as a new second parameter; filtering the preset image by using the new second parameter, and comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter; and if the distortion value of the filtered image corresponding to the new second parameter is lower than the distortion value of the filtered image corresponding to the first parameter, taking the new second parameter as the new first parameter, returning to the step of selecting the filtering parameter which is arranged at the front position of the first parameter in the target group as the new second parameter, and taking the first parameter as the target parameter until the distortion value of the filtered image corresponding to the first parameter is lower than the distortion value of the filtered image corresponding to the new second parameter or no new second parameter exists.
For example, m3 may be used as a new second parameter, the filtering results of m3 and m4 are compared, if the filtering result of m3 is better than m4, m3 may be used as a new target candidate parameter, m2 is used as a new second parameter, the filtering results of m3 and m2 are compared, and so on until the quality of the filtering result corresponding to the target candidate parameter is higher than that of the filtering result corresponding to the second parameter, or a previous filtering parameter does not exist in the new target candidate parameter, and the target candidate parameter is used as the target parameter.
In an implementation manner, the preset image is an image in a to-be-processed video, for example, the preset image may be a first frame in the to-be-processed video, or may also be a first key frame in the to-be-processed video, or may also be a certain frame randomly selected from the to-be-processed images with a preset time length, which is not limited specifically. The preset image and most of the video frames in the video to be processed have similar image characteristics, in other words, the filtering result of the filtering parameter on the preset image and the overall filtering result of the filtering parameter on the video to be processed are similar and have certain referential. Then, after filtering the preset image by using other filtering parameters in the target packet and calculating a distortion value between the filtered image corresponding to each filtering parameter in the target packet and the original image, the filtering parameter corresponding to the filtered image with the lowest distortion value may be used as the target parameter, and then, the target parameter is used to filter the video to be processed, so as to obtain a filtering result of the video to be processed. Therefore, a better filtering effect can be obtained, and compared with a mode of traversing each filtering parameter, the filtering speed is higher.
For example, as shown in fig. 2, a schematic diagram of a scheme for performing filtering by using image filtering according to an embodiment of the present invention in an implementation manner is shown, where the filtering parameters include m0, m2, … …, and m15, which are sorted from small to large, where m0 to m9 are third groups, m10 to m13 are first groups, m14 to m15 are second groups, the grouped candidate parameters are m4, m11, and m14, and distortion values corresponding to m4, m11, and m14 are compared first.
If the distortion value corresponding to m4 is the lowest, namely m4 is the optimal, m4 and m5 are compared, if the distortion value corresponding to m4 is the lowest, namely m4 is the optimal, then the distortion value corresponding to m0-m3 is calculated, and the target parameters are determined from m0-m 3; otherwise, if the distortion value corresponding to m5 is the lowest, namely m5 is the optimal, the distortion values corresponding to m6-m9 are calculated, and the target parameters are determined from m6-m 9.
If m11 is optimal, calculating the distortion value of m12, if m11 is optimal, calculating the distortion value of m10, and determining target parameters from m11 and m 10; otherwise, a distortion value of m13 is calculated, and target parameters are determined from m12 and m 13.
If m14 is optimal, then the distortion value of m15 is calculated, and the target parameters are determined from m14 and m 15.
As can be seen from the above, in the image filtering method provided in the embodiment of the present invention, by grouping the filtering parameters, the target group in which the solution that can satisfy the filtering requirement is located is determined first, and then the filtering parameters that can satisfy the filtering requirement are determined from the target group.
As shown in fig. 3, an embodiment of the present invention further provides a schematic structural diagram of an image filtering apparatus, where the apparatus includes:
the grouping module 201 is configured to group pre-obtained filtering parameters according to values of a first filtering radius and a second filtering radius to obtain a grouping result, where each filtering parameter includes the first filtering radius, a first regularization coefficient corresponding to the first filtering radius, a second filtering radius, and a second regularization coefficient corresponding to the second filtering radius, a value of the first filtering radius of the filtering parameter in the first grouping is 0, a value of the second filtering radius of the filtering parameter in the second grouping is 0, and values of the first filtering radius and the second filtering radius of the filtering parameter in the third grouping are both not 0;
a selecting module 202, configured to select, as a candidate parameter of the group, a filter parameter of which the reference coefficient is located in a preset order in the group to which the reference coefficient belongs, where the preset order is an integer closest to one-half of the number of the filter parameters in the group to which the reference coefficient belongs, the reference coefficient is a second regularization coefficient in the first group, a first regularization coefficient in the second group, and a first regularization coefficient or a second regularization coefficient in the third group;
a comparing module 203, configured to filter the preset image by using the candidate parameters, calculate a distortion value between the filtered image corresponding to each candidate parameter and an original image, and use a group in which the candidate parameter corresponding to the filtered image with the lowest distortion value is located as a target group, where the original image is an image of the preset image before video encoding;
a determining module 204, configured to filter the preset image by using other filtering parameters in the target group, calculate a distortion value between the filtered image corresponding to each filtering parameter in the target group and the original image, and use the filtered image with the lowest distortion value as a filtering result of the preset image.
In an implementation manner, the preset image is an image in a video to be processed, and the determining module 204 is specifically configured to:
filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as a target parameter;
and filtering the video to be processed by utilizing the target parameters to obtain a filtering result of the video to be processed.
In one implementation, the determining module 204 is configured to:
taking the candidate parameter of the target packet as a first parameter, and selecting a filtering parameter which is ordered at the next bit of the first parameter in the target packet as a second parameter;
filtering the preset image by using the second parameter, and calculating a distortion value between the filtered image corresponding to the second parameter and the original image;
if the distortion value corresponding to the second parameter is lower than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced after the second parameter in the target grouping, comparing the obtained distortion value of the filtered image with the distortion value of the filtered image corresponding to the second parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter;
if the distortion value corresponding to the second parameter is higher than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced in the target group before the first parameter, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter.
In one implementation, the determining module 204 is configured to:
and taking the second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the next bit of the first parameter in the target grouping as the second parameter, and taking the first parameter as the target parameter until the distortion value of the filtering image corresponding to the first parameter is lower than the distortion value of the filtering image corresponding to the second parameter or no new second parameter exists.
In one implementation, the determining module 204 is configured to:
selecting a filtering parameter which is sequenced one bit before the first parameter in the target grouping as a new second parameter;
filtering the preset image by using the new second parameter, and comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter;
and if the distortion value of the filtered image corresponding to the new second parameter is lower than the distortion value of the filtered image corresponding to the first parameter, taking the new second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the front position of the first parameter in the target group and is used as a new second parameter, and taking the first parameter as the target parameter until the distortion value of the filtered image corresponding to the first parameter is lower than the distortion value of the filtered image corresponding to the new second parameter or no new second parameter exists.
As can be seen from the above, in the image filtering device provided in the embodiment of the present invention, by grouping the filtering parameters, the target group where the solution that can satisfy the filtering requirement is located is determined first, and then the filtering parameters that can satisfy the filtering requirement are determined from the target group.
An embodiment of the present invention further provides an electronic device, as shown in fig. 4, including a processor 401, a communication interface 402, a memory 403, and a communication bus 404, where the processor 401, the communication interface 402, and the memory 403 complete mutual communication through the communication bus 404,
a memory 403 for storing a computer program;
the processor 401, when executing the program stored in the memory 403, implements the following steps:
grouping pre-acquired filter parameters according to values of a first filter radius and a second filter radius to obtain a grouping result, wherein each filter parameter comprises the first filter radius, a first regularization coefficient corresponding to the first filter radius, the second filter radius and a second regularization coefficient corresponding to the second filter radius, the first filter radius of the filter parameters in the first group is 0, the second filter radius of the filter parameters in the second group is 0, and the first filter radius and the second filter radius of the filter parameters in the third group are not 0;
selecting a filter parameter of which the reference coefficient is positioned in a preset sequence in the group to which the reference coefficient belongs as a candidate parameter of the group, wherein the preset sequence is an integer which is closest to one-half of the number of the filter parameters in the group to which the reference coefficient belongs, the reference coefficient is a second regularization coefficient in the first group, is a first regularization coefficient in the second group, and is a first regularization coefficient or a second regularization coefficient in the third group;
respectively filtering the preset images by using the candidate parameters, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, and taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group, wherein the original image is the image of the preset image before video coding;
and filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering image with the lowest distortion value as a filtering result of the preset image.
The communication bus mentioned in the above terminal may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the terminal and other equipment.
The Memory may include a Random Access Memory (RAM) or a non-volatile Memory (non-volatile Memory), such as at least one disk Memory. Optionally, the memory may also be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; the Integrated Circuit may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, a discrete Gate or transistor logic device, or a discrete hardware component.
In yet another embodiment of the present invention, a computer-readable storage medium is further provided, which has instructions stored therein, which when run on a computer, cause the computer to perform the image filtering method described in any of the above embodiments.
In a further embodiment of the present invention, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to perform the image filtering method of any of the above embodiments.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the invention to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (10)

1. A method of filtering an image, the method comprising:
grouping pre-acquired filter parameters according to values of a first filter radius and a second filter radius to obtain a grouping result, wherein each filter parameter comprises the first filter radius, a first regularization coefficient corresponding to the first filter radius, the second filter radius and a second regularization coefficient corresponding to the second filter radius, the first filter radius of the filter parameters in the first group is 0, the second filter radius of the filter parameters in the second group is 0, and the first filter radius and the second filter radius of the filter parameters in the third group are not 0;
selecting a filter parameter with a reference coefficient located in a preset sequence in the group to which the reference coefficient belongs as a candidate parameter of the group, wherein the preset sequence is an integer closest to one-half of the number of the filter parameters in the group to which the reference coefficient belongs, the reference coefficient is the second regularization coefficient in the first group, the first regularization coefficient in the second group, and the first regularization coefficient or the second regularization coefficient in the third group;
respectively filtering the preset images by using the candidate parameters, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, and taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group, wherein the original image is the image of the preset image before video coding;
and filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering image with the lowest distortion value as a filtering result of the preset image.
2. The method according to claim 1, wherein the preset image is an image in a video to be processed, the filtering the preset image using other filtering parameters in the target group, calculating a distortion value between the original image and the filtered image corresponding to each filtering parameter in the target group, and using the filtered image with the lowest distortion value as the filtering result of the preset image comprises:
filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtering image corresponding to each filtering parameter in the target group and the original image, and taking the filtering parameter corresponding to the filtering image with the lowest distortion value as a target parameter;
and filtering the video to be processed by utilizing the target parameters to obtain a filtering result of the video to be processed.
3. The method according to claim 1, wherein the filtering the preset image by using other filtering parameters in the target packet, calculating a distortion value between the original image and the filtered image corresponding to each filtering parameter in the target packet, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter comprises:
taking the candidate parameter of the target packet as a first parameter, and selecting a filtering parameter which is ordered at the next bit of the first parameter in the target packet as a second parameter;
filtering the preset image by using the second parameter, and calculating a distortion value between the filtered image corresponding to the second parameter and the original image;
if the distortion value corresponding to the second parameter is lower than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced after the second parameter in the target grouping, comparing the obtained distortion value of the filtered image with the distortion value of the filtered image corresponding to the second parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter;
if the distortion value corresponding to the second parameter is higher than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced in the target group before the first parameter, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter.
4. The method according to claim 3, wherein the filtering the preset image by using the filtering parameters ordered after the second parameter in the target packet, comparing the distortion value of the obtained filtered image with the distortion value of the filtered image corresponding to the second parameter, and using the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter, comprises:
and taking the second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the next bit of the first parameter in the target grouping as the second parameter, and taking the first parameter as the target parameter until the distortion value of the filtering image corresponding to the first parameter is lower than the distortion value of the filtering image corresponding to the second parameter or no new second parameter exists.
5. The method according to claim 3, wherein the filtering the preset image by using the filtering parameter ordered before the first parameter in the target packet, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and using the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter comprises:
selecting a filtering parameter which is sequenced one bit before the first parameter in the target grouping as a new second parameter;
filtering the preset image by using the new second parameter, and comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter;
and if the distortion value of the filtered image corresponding to the new second parameter is lower than the distortion value of the filtered image corresponding to the first parameter, taking the new second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the front position of the first parameter in the target group and is used as a new second parameter, and taking the first parameter as the target parameter until the distortion value of the filtered image corresponding to the first parameter is lower than the distortion value of the filtered image corresponding to the new second parameter or no new second parameter exists.
6. An image filtering apparatus, characterized in that the apparatus comprises:
the grouping module is used for grouping pre-acquired filter parameters according to values of a first filter radius and a second filter radius to obtain a grouping result, wherein each filter parameter comprises the first filter radius, a first regularization coefficient corresponding to the first filter radius, a second regularization coefficient corresponding to the second filter radius and a second regularization coefficient corresponding to the second filter radius, the value of the first filter radius of the filter parameters in the first group is 0, the value of the second filter radius of the filter parameters in the second group is 0, and the values of the first filter radius and the second filter radius of the filter parameters in the third group are not 0;
a selection module, configured to select, as a candidate parameter of the group, a filter parameter of which a reference coefficient is located in a preset ordering in the group to which the reference coefficient belongs, where the preset ordering is an integer closest to one-half of the number of filter parameters in the group to which the reference coefficient belongs, the reference coefficient is the second regularization coefficient in the first group, the reference coefficient is the first regularization coefficient in the second group, and the reference coefficient is the first regularization coefficient or the second regularization coefficient in the third group;
the comparison module is used for filtering the preset image by using the candidate parameters respectively, calculating a distortion value between the filtered image corresponding to each candidate parameter and the original image, and taking the group of the candidate parameter corresponding to the filtered image with the lowest distortion value as a target group, wherein the original image is an image of the preset image before video coding;
and the determining module is used for filtering the preset image by using other filtering parameters in the target group, calculating a distortion value between the filtered image corresponding to each filtering parameter in the target group and the original image, and taking the filtered image with the lowest distortion value as a filtering result of the preset image.
7. The apparatus of claim 6, wherein the determining module is configured to:
taking the candidate parameter of the target packet as a first parameter, and selecting a filtering parameter which is ordered at the next bit of the first parameter in the target packet as a second parameter;
filtering the preset image by using the second parameter, and calculating a distortion value between the filtered image corresponding to the second parameter and the original image;
if the distortion value corresponding to the second parameter is lower than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced after the second parameter in the target grouping, comparing the obtained distortion value of the filtered image with the distortion value of the filtered image corresponding to the second parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter;
if the distortion value corresponding to the second parameter is higher than the distortion value corresponding to the first parameter, filtering the preset image by using the filtering parameters sequenced in the target group before the first parameter, comparing the distortion value of the obtained filtered image with the distortion value corresponding to the first parameter, and taking the filtering parameter corresponding to the filtered image with the lowest distortion value as the target parameter.
8. The apparatus of claim 7, wherein the determining module is configured to:
and taking the second parameter as a new first parameter, returning to the step of selecting the filtering parameter which is arranged at the next bit of the first parameter in the target grouping as the second parameter, and taking the first parameter as the target parameter until the distortion value of the filtering image corresponding to the first parameter is lower than the distortion value of the filtering image corresponding to the second parameter or no new second parameter exists.
9. An electronic device is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor and the communication interface are used for realizing mutual communication by the memory through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any one of claims 1 to 5 when executing a program stored in the memory.
10. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method of any one of claims 1 to 5.
CN202110559418.6A 2021-05-21 2021-05-21 Image filtering method, device, equipment and storage medium Active CN113365060B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110559418.6A CN113365060B (en) 2021-05-21 2021-05-21 Image filtering method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110559418.6A CN113365060B (en) 2021-05-21 2021-05-21 Image filtering method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113365060A CN113365060A (en) 2021-09-07
CN113365060B true CN113365060B (en) 2022-04-26

Family

ID=77527169

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110559418.6A Active CN113365060B (en) 2021-05-21 2021-05-21 Image filtering method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113365060B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114025160B (en) * 2021-11-26 2023-06-02 成都爱奇艺智能创新科技有限公司 Video filtering method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106548176A (en) * 2016-11-18 2017-03-29 安徽大学 Finger vein image enhancement method based on self adaptation guiding filtering
CN109741287A (en) * 2018-12-27 2019-05-10 湖南国科微电子股份有限公司 Image orientation filtering method and device
CN109840892A (en) * 2019-01-14 2019-06-04 苏州长风航空电子有限公司 A kind of infrared video Enhancement Method based on High Level Synthesis
JP2019113474A (en) * 2017-12-26 2019-07-11 浜松ホトニクス株式会社 Image processing device and image processing method
CN111314711A (en) * 2020-03-31 2020-06-19 电子科技大学 Loop filtering method based on self-adaptive self-guided filtering

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106548176A (en) * 2016-11-18 2017-03-29 安徽大学 Finger vein image enhancement method based on self adaptation guiding filtering
JP2019113474A (en) * 2017-12-26 2019-07-11 浜松ホトニクス株式会社 Image processing device and image processing method
CN109741287A (en) * 2018-12-27 2019-05-10 湖南国科微电子股份有限公司 Image orientation filtering method and device
CN109840892A (en) * 2019-01-14 2019-06-04 苏州长风航空电子有限公司 A kind of infrared video Enhancement Method based on High Level Synthesis
CN111314711A (en) * 2020-03-31 2020-06-19 电子科技大学 Loop filtering method based on self-adaptive self-guided filtering

Also Published As

Publication number Publication date
CN113365060A (en) 2021-09-07

Similar Documents

Publication Publication Date Title
CN112188198B (en) Image data compression and decompression method and system
US11949868B2 (en) Method and device for selecting context model of quantization coefficient end flag bit
CN106170093B (en) Intra-frame prediction performance improving coding method
CN109688407B (en) Reference block selection method and device for coding unit, electronic equipment and storage medium
CN113365060B (en) Image filtering method, device, equipment and storage medium
JP2008504749A (en) Discrete universal denoising by reliability information
CN110909663A (en) Human body key point identification method and device and electronic equipment
CN107508775A (en) Interpretation method and device in a kind of Sparse Code multiple access system
WO2023051776A1 (en) Encoding method and apparatus, decoding method and apparatus, device, and readable storage medium
WO2024077767A1 (en) Learning model-oriented coding decision processing method and apparatus, and device
JPH0622143A (en) Transmission of image signal and encoding system for enhancement of reduction efficiency of data in storage
CN113422956B (en) Image coding method and device, electronic equipment and storage medium
CN113709483B (en) Interpolation filter coefficient self-adaptive generation method and device
CN114418882A (en) Processing method, training method, device, electronic equipment and medium
CN115588125A (en) Image set construction method for inserting multiple images
CN110944211B (en) Interpolation filtering method, device, medium and electronic device for intra-frame prediction
CN109561315B (en) Motion estimation method and device, electronic equipment and storage medium
CN113763225A (en) Image perception hashing method, system and equipment and information data processing terminal
CN112954454A (en) Video frame generation method and device
CN109995962B (en) Method and system for controlling upper limit of picture coding size
CN105872538A (en) Time-domain filtering method and time-domain filtering device
CN110809158A (en) Image loop filtering processing method and device
CN112929729B (en) Barrage data adjustment method, device, equipment and storage medium
CN113497886B (en) Video processing method, terminal device and computer-readable storage medium
CN111080550B (en) Image processing method, image processing device, electronic equipment and computer readable storage medium

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