Image weighting quantization processing method and device, computer device and storage medium
By calculating the perceptual threshold using the frequency domain representation of adjacent encoded or decoded blocks and modulating the quantization step size, image weighted quantization processing is achieved while ensuring image quality, thus improving compression ratio and reducing complexity.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-27
- Publication Date
- 2026-04-07
AI Technical Summary
Existing image coding techniques struggle to improve compression rates while maintaining image quality during quantization, and weighted quantization processing is both unavailable and complex in the absence of predictive information.
By calculating the perceptual threshold of the target frequency component using the frequency domain representation of the adjacent encoded or decoded blocks of the block to be processed, determining the weighting factor, and modulating the quantization step size, content-adaptive frequency component-level quantization is achieved.
It improves image compression ratio and subjective quality while reducing coding complexity and bit rate.
Smart Images

Figure CN116527902B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the field of multimedia compression, and particularly relates to an image weighted quantization processing method and device, computer equipment and a storage medium. BACKGROUND
[0002] The application background of weighted quantization is image encoding and compression. In image encoding, it is usually necessary to compress the pixels of an image in order to reduce the size of image data and reduce storage and transmission costs. In this process, quantization is an important step, which maps pixel values to discrete values to reduce the size of image data. However, if the quantization step is too large, the image quality will decrease, and if the quantization step is too small, the size of image data will increase, and the compression effect will be poor. Therefore, a weighted quantization matrix is used to adjust the quantization step in order to better preserve the quality and details of the image.
[0003] In image encoding, the weighted quantization matrix can be transmitted between the encoder and the decoder to ensure that the compressed image and the decompressed image have the same visual quality. The design of the weighted quantization matrix is usually based on the statistical characteristics of the image and the visual sensitivity model of the human eye in order to better match the visual characteristics of the image and the perception of the human eye to the image. The application of the weighted quantization matrix can greatly improve the compression effect and visual quality of the image, and is one of the indispensable technologies in modern image encoding standards. SUMMARY
[0004] The application provides an image weighted quantization processing method and device, which can improve the compression rate of the image while ensuring the quality of the image. In order to achieve the above purpose, the application adopts the following technical solutions:
[0005] In a first aspect, the present application provides an image weighted quantization processing method, comprising: obtaining a frequency domain expression of a reference block of a to-be-processed block in an image; determining a perceptual threshold of a target frequency component according to information of the target frequency component and information of the frequency domain expression of the reference block, the information of the target frequency component at least comprising a frequency of the target frequency component, and the perceptual threshold of the target frequency component at least comprising an above-threshold single-frequency perceptual sensitivity threshold of the target frequency component and / or an inter-frequency masking threshold of the target frequency component; determining a weighting factor of the target frequency component according to the perceptual threshold of the target frequency component; modulating an initial quantization step of the target frequency component according to the weighting factor to determine a weighted quantization step of the target frequency component; and performing quantization or dequantization processing on the to-be-processed block according to the weighted quantization step in one of the following methods: a) quantizing an amplitude value of the target frequency component of the to-be-processed block according to the weighted quantization step to obtain a quantized coefficient of the amplitude value of the target frequency component of the to-be-processed block; and b) dequantizing a quantized coefficient of the amplitude value of the target frequency component of the to-be-processed block according to the weighted quantization step to obtain a reconstructed amplitude value of the target frequency component of the to-be-processed block.
[0006] The present application uses the frequency domain expression (i.e. the frequency, amplitude value and direction of the frequency component) of the reference block of the to-be-processed block to calculate the perceptual threshold of the target frequency component of the to-be-processed block. The reference block of the to-be-processed block refers to the adjacent coded block of the to-be-processed block or the adjacent decoded block of the to-be-processed block. In the quantization process, the encoder can first obtain the frequency domain expression of the to-be-processed block, and therefore the most ideal case is to calculate the perceptual threshold of the target frequency component according to the frequency domain expression of the to-be-processed block, to determine the modulation factor of the target frequency component according to the perceptual threshold, and then to obtain the weighted quantization step according to the modulation factor for the quantization link. However, in the dequantization link, the encoder cannot first obtain the frequency domain expression of the to-be-processed block, and the frequency domain expression of the to-be-processed block is needed in the dequantization. Therefore, the present application selects the frequency domain expression of the reference block to calculate the perceptual threshold of the target frequency component of the to-be-processed block.
[0007] For video signals, there is strong spatial correlation between neighboring pixels within an image, and strong temporal correlation between adjacent images. Therefore, video coding often uses intra-frame prediction and inter-frame prediction to obtain prediction blocks, in order to remove spatial and temporal redundancy. Although the spectral distribution of the prediction block and the block to be processed has a high similarity, the method of calculating the perceptual threshold of the target frequency component using the information of the prediction block becomes unusable when prediction information is unavailable. Furthermore, the adjacent encoded blocks or adjacent decoded blocks of the block to be processed also have extremely high spatial correlation with the block to be processed. Therefore, using the information of the adjacent encoded blocks or adjacent decoded blocks of the block to be processed to calculate the perceptual threshold can achieve the same technical effect as using the information of the prediction block. This not only solves the usability problem of the image weighted quantization processing method in application scenarios without prediction information, but also further reduces the complexity of the image weighted quantization processing method by omitting the prediction step.
[0008] The perceptual threshold is calculated using information from adjacent encoded or decoded blocks of the block to be processed. Since the information from adjacent encoded or decoded blocks is highly similar to the information of the block to be processed, this perceptual threshold yields a weighting factor that adapts to the content of the block to be processed. This allows for more precise scaling of the weighted quantization step size and better utilization of local image variations. Furthermore, the acquisition of this weighting factor does not require additional coding overhead. Therefore, under the same subjective quality, the weighted quantization processing method of this invention has a lower bitrate, thereby improving the image compression ratio.
[0009] Furthermore, the frequency domain representation of the reference block is obtained through the frequency domain representation of the adjacent coded blocks or the adjacent decoded blocks of the block to be processed.
[0010] Furthermore, the above-threshold single-frequency sensing sensitivity threshold of the target frequency component is determined using at least one of the following methods:
[0011] a) Based on the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block, the threshold of the suprathreshold single-frequency sensing sensitivity is determined by the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function with frequency and amplitude as independent variables.
[0012] b) Using the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block as indexes, the above-threshold single-frequency sensing sensitivity threshold is determined through the above-threshold single-frequency sensing sensitivity threshold index table, which is a table with frequency and amplitude values as index parameters.
[0013] For the same target frequency component, when the amplitude of the reference block on that frequency component is different, the derived suprathreshold single-frequency sensing sensitivity threshold will also be different, indicating that the degree of deviation from the basic threshold is different, and therefore the derived sensitivity threshold will be different.
[0014] Furthermore, the inter-frequency masking threshold of the target frequency component includes at least one of the following methods for determination:
[0015] a) Determine the inter-frequency masking threshold based on the amplitude values of the reference frequency components in the frequency domain representation of the reference block and the amplitude values relative to the main signal in the frequency domain representation of the reference block.
[0016] b) Determine the inter-frequency masking threshold based on the frequency of the reference frequency component in the frequency domain representation of the reference block, and the amplitude and frequency of the frequency components relative to the main signal in the frequency domain representation of the reference block.
[0017] c) Determine the inter-frequency masking threshold based on the frequency and direction of the reference frequency component in the frequency domain representation of the reference block, and the amplitude, frequency, and direction of the frequency components relative to the main signal in the frequency domain representation of the reference block.
[0018] The reference frequency component refers to the frequency component in the frequency domain representation of the reference block that has the same frequency as the target frequency component, and the relative main signal refers to at least one frequency component among the other frequency components in the reference block besides the reference frequency component.
[0019] The inter-frequency masking threshold can be determined using an inter-frequency masking function. As the frequency difference and direction difference between the relative main signal and the target frequency component increase, the inter-frequency masking threshold of the target frequency component decreases accordingly; conversely, as the amplitude value relative to the main signal increases, the inter-frequency masking threshold of the target frequency component increases accordingly.
[0020] Secondly, the present invention also provides an image weighted quantization processing apparatus, the apparatus comprising a processing unit, the processing unit comprising: a frequency domain transformation module for acquiring the frequency domain representation of a reference block of a block to be processed in an image; a perception threshold calculation module for determining a perception threshold of a target frequency component based on information of a target frequency component of the block to be processed and information of the frequency domain representation of the reference block, wherein the information of the target frequency component includes at least the frequency of the target frequency component, and the perception threshold of the target frequency component includes at least an on-threshold single-frequency perception sensitivity threshold and / or an inter-frequency masking threshold of the target frequency component; and a weighting factor derivation module for deriving the weighting factor based on the perception threshold of the target frequency component. The system determines the weighting factor of the target frequency component; the weighted quantization step size modulation module modulates the initial quantization step size of the target frequency component according to the weighting factor, thereby determining the weighted quantization step size of the target frequency component; the quantization processing module performs quantization or dequantization processing according to the weighted quantization step size using one of the following methods: a) quantize the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the quantized coefficients of the amplitude value of the target frequency component of the block to be processed; b) dequantize the quantized coefficients of the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the reconstructed amplitude value of the target frequency component of the block to be processed.
[0021] Furthermore, the frequency domain representation of the reference block is obtained through the frequency domain representation of the adjacent coded blocks or the adjacent decoded blocks of the block to be processed.
[0022] Furthermore, the above-threshold single-frequency sensing sensitivity threshold of the target frequency component is determined using at least one of the following methods:
[0023] a) Based on the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block, the threshold of the suprathreshold single-frequency sensing sensitivity is determined by the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function with frequency and amplitude as independent variables.
[0024] b) Using the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block as indexes, the above-threshold single-frequency sensing sensitivity threshold is determined through the above-threshold single-frequency sensing sensitivity threshold index table, which is a table with frequency and amplitude values as index parameters.
[0025] For the same target frequency component, when the amplitude of the reference block on that frequency component is different, the derived suprathreshold single-frequency sensing sensitivity threshold will also be different, indicating that the degree of deviation from the basic threshold is different, and therefore the derived sensitivity threshold will be different.
[0026] Furthermore, the inter-frequency masking threshold of the target frequency component includes at least one of the following methods for determination:
[0027] a) Determine the inter-frequency masking threshold based on the amplitude values of the reference frequency components in the frequency domain representation of the reference block and the amplitude values relative to the main signal in the frequency domain representation of the reference block.
[0028] b) Determine the inter-frequency masking threshold based on the frequency of the reference frequency component in the frequency domain representation of the reference block, and the amplitude and frequency of the frequency components relative to the main signal in the frequency domain representation of the reference block.
[0029] c) Determine the inter-frequency masking threshold based on the frequency and direction of the reference frequency component in the frequency domain representation of the reference block, and the amplitude, frequency, and direction of the frequency components relative to the main signal in the frequency domain representation of the reference block.
[0030] The reference frequency component refers to the frequency component in the frequency domain representation of the reference block that has the same frequency as the target frequency component, and the relative main signal refers to at least one frequency component among the other frequency components in the reference block besides the reference frequency component.
[0031] The inter-frequency masking threshold can be determined using an inter-frequency masking function. As the frequency difference and direction difference between the relative main signal and the target frequency component increase, the inter-frequency masking threshold of the target frequency component decreases accordingly; conversely, as the amplitude value relative to the main signal increases, the inter-frequency masking threshold of the target frequency component increases accordingly.
[0032] Thirdly, the present invention also provides a computer, including a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to perform the image weighted quantization processing method as described in the first aspect above.
[0033] Fourthly, the present invention also provides a computer-readable storage medium comprising a stored program, wherein the computer-readable storage medium stores computer instructions for causing a computer to execute the image weighted quantization processing method as described in the first aspect above.
[0034] This invention provides a frequency component coefficient-level quantization step-size modulation method, rather than the traditional block-level quantization step-size modulation. The weighting factor used in the modulation process not only represents the frequency sensitivity of the target frequency component itself but is also affected by the amplitude value of the target frequency component. Furthermore, the weighting factor is also influenced by the frequency components surrounding the target frequency component. When the frequency difference and direction difference between the surrounding frequency components and the target frequency component are different, the weighting factor will also be different. Since the content of different blocks to be processed is different, the spectral information of the blocks to be processed is also different; therefore, the weighting factor changes with the content. In summary, the quantization method of this invention is a content-adaptive frequency component coefficient-level quantization step-size modulation method. Attached Figure Description
[0035] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0036] Figure 1 An exemplary schematic diagram of a reference block provided in an embodiment of the present invention;
[0037] Figure 2 A flowchart illustrating an image weighted quantization processing method provided in an embodiment of the present invention;
[0038] Figure 3 This is a schematic diagram of an image weighted quantization processing device provided in an embodiment of the present invention. Detailed Implementation
[0039] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0040] First, the terminology used in the embodiments of this invention will be explained.
[0041] Supra-threshold single-frequency sensing sensitivity threshold: Specifically in the field of image processing, when the amplitude of a certain frequency component increases from 0, the presence of the frequency component can only be detected when the increase reaches a certain threshold. When the amplitude of a certain frequency component increases or decreases from a non-zero amplitude, the change in the signal can only be detected when the increase or decrease reaches another certain threshold. The perceptible change amplitude value that occurs in the above two cases is called the supra-threshold single-frequency sensing sensitivity threshold.
[0042] Frequency domain masking threshold: Specifically in the field of image processing, there is a masking effect between different frequency components in the frequency domain. A large-amplitude frequency component signal will mask a small-amplitude frequency component signal in its vicinity, causing the viewer to be unable to fully perceive all the information expressed by the frequency component signal. The amplitude increment that the human eye can just see when masking exists is called the frequency masking threshold.
[0043] Just noticeable difference (JND): In visual perception, due to various masking effects of the human visual system (HVS), such as contrast masking and brightness masking, the human eye can only perceive changes in signal feature values (such as amplitude, frequency, phase, etc.) that exceed a certain threshold. This threshold is called the JND masking threshold of the signal feature value.
[0044] Target frequency component: Specifically refers to at least one frequency component in the frequency components of the block to be processed (transform block / inverse transform block).
[0045] The following embodiments are given with reference to the accompanying drawings. It should be noted that each step of each embodiment contains multiple implementation methods.
[0046] Example 1:
[0047] Please refer to Figure 2 , Figure 2 This is a flowchart illustrating an image weighted quantization processing method provided in an embodiment of the present invention. The weighted quantization processing method is described as a series of steps or operations. It should be understood that the weighted quantization processing method can be executed in various orders and / or occur simultaneously, and is not limited to... Figure 2 The execution order is shown. Regarding the expressions in the embodiments, it should be understood that "in one possible implementation" indicates a method of implementing this step, and "exemplarily" under the same "in one possible implementation" indicates different operations of that implementation method. For example... Figure 2 As shown, image weighted quantization processing methods may include:
[0048] S201. Obtain the frequency domain representation of the reference block of the block to be processed.
[0049] In a possible implementation form The frequency domain representation of the adjacent coded block is obtained as the frequency domain representation of the reference block.
[0050] For example, the frequency domain representation of the left adjacent coded block in the space to be processed is used as the frequency domain representation of the reference block.
[0051] For example, the frequency domain representation of the upper adjacent coded block in the space to be processed is used as the frequency domain representation of the reference block.
[0052] In a possible implementation form The frequency domain representation of the adjacent decoded block is obtained as the frequency domain representation of the reference block.
[0053] For example, the frequency domain representation of the left-side adjacent decoded block in the block space to be processed is used as the frequency domain representation of the reference block.
[0054] For example, the frequency domain representation of the upper adjacent decoded block in the above-mentioned block space to be processed is used as the frequency domain representation of the reference block.
[0055] In a possible implementation form The frequency domain representation of the reference block is obtained by performing a frequency domain transformation on adjacent coded or decoded blocks.
[0056] It should be noted that the specific method of change can be any method that can be conceived by those skilled in the art, and the present invention does not impose any specific limitations on it.
[0057] For example, the frequency domain representation of the reference block of the block to be processed can be obtained by performing a block-integer discrete cosine transform (DCT) on adjacent coded blocks or adjacent decoded blocks.
[0058] For example, taking a 32×32 transform size as an example, the frequency domain expression can be obtained through the following integer DCT transform formula:
[0059]
[0060] in, This is the transform coefficient matrix of the 32×32 integer DCT transform frequency components. It is a 32×32 integer DCT transformation matrix. It is a 32×32 matrix in the spatial domain. for The transpose of .
[0061] For example, the frequency domain representation of the reference block of the block to be processed can be obtained by performing a block-based discrete Fourier transform (DFT) on the reference block of an adjacent coded block or an adjacent decoded block.
[0062] For example, the frequency domain representation can be obtained through the following two-dimensional DFT transform formula:
[0063] Consider an N×N image f(x, y), the above two-dimensional DFT formula is:
[0064]
[0065] Where F(u, v) represents the frequency domain transform coefficients. In the transform domain, u and v represent the horizontal and vertical frequencies, respectively. The exponential terms in the above two-dimensional DFT are extended to the form of sine and cosine terms, where the variables u and v are used to determine their frequencies.
[0066] Even if f(x, y) is a real number, its transform is usually a complex number. A key intuitive method for analyzing a transform is to calculate its spectrum, i.e., the amplitude of F(u, v). Let R(u, v) and I(u, v) represent the real and imaginary parts of F(u, v), respectively. Then the Fourier spectrum is defined as:
[0067] For example, a frequency domain representation of a reference block of the block to be processed can be obtained by performing a DCT transform on adjacent coded blocks or adjacent decoded blocks.
[0068] For example, the frequency domain representation is obtained according to the type II two-dimensional DCT formula:
[0069] Consider an N×N image f(x, y), the formula for Class II 2D DCT is:
[0070]
[0071]
[0072] Where F(u, v) are frequency domain transformation coefficients, x, y are spatial domain discrete signal position indices, u, v are frequency domain discrete signal position indices, and u, v = 0, 1, ..., N-1.
[0073] For example, a discrete sine transform (DST) can be performed on adjacent coded blocks or adjacent decoded blocks to obtain the frequency domain representation of the reference block of the block to be processed.
[0074] For example, the frequency domain expression can be obtained from the two-dimensional DST formula:
[0075] Consider an N×N image f(x, y), the two-dimensional DST formula is:
[0076]
[0077] in,
[0078] S202. Determine the sensing threshold of the target frequency component based on the frequency domain expression.
[0079] In a possible implementation form The threshold of the target frequency component is determined by the suprathreshold single-frequency sensing sensitivity function based on the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block. The sensing threshold of the target frequency component is then determined by the suprathreshold single-frequency sensing sensitivity function.
[0080] For example, the suprathreshold single-frequency sensing sensitivity threshold is calculated using a suprathreshold single-frequency sensing sensitivity function as shown in the following formula:
[0081]
[0082] Among them, SPSF(F m A0) represents the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function, F m A represents the spatial frequency of the target frequency component. m This represents the amplitude value of the reference frequency component.
[0083] The perception threshold JND can be expressed as:
[0084] JND u,v =SPSF u,v
[0085] To better measure the human eye's perception of signal frequency in space, the signal frequency needs to be converted into spatial frequency, measured in cycles per degree. Spatial frequency refers to the number of periodic changes in brightness per unit length, reflecting the spatial variation of pixel grayscale in an image. Under constant viewing conditions, for a given frequency f... m A sinusoidal signal with a spatial frequency F m The value of is uniquely determined by the following formula:
[0086]
[0087] Where M represents the number of pixels in the vertical direction of the image, and L represents the viewing distance of the subject. In the example function provided, M = L = 1080.
[0088] In a possible implementation form The threshold of the target frequency component is determined by the suprathreshold single-frequency sensing sensitivity function based on the frequency of the target frequency component of the block to be processed, and the sensing threshold of the target frequency component is determined by the suprathreshold single-frequency sensing sensitivity function.
[0089] For example, the suprathreshold single-frequency sensing sensitivity threshold is calculated using a suprathreshold single-frequency sensing sensitivity function as shown in the following formula:
[0090]
[0091] Among them, SPSF(F m F is represented as the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function. m This represents the spatial frequency of the target frequency component. At this point, the suprathreshold single-frequency sensing sensitivity threshold of the target frequency component is only affected by the frequency of the target frequency component.
[0092] The perception threshold JND can be expressed as:
[0093] JND u,v =SPSF u,v
[0094] In a possible implementation form The threshold value of the target frequency component is determined by the above-threshold single-frequency sensing sensitivity function based on the amplitude value of the reference frequency component in the frequency domain expression of the reference block, and the sensing threshold of the target frequency component is determined by the above-threshold single-frequency sensing sensitivity function.
[0095] For example, the suprathreshold single-frequency sensing sensitivity threshold is calculated using a suprathreshold single-frequency sensing sensitivity function as shown in the following formula:
[0096]
[0097] Among them, SPSF(A) m A is represented as a suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function. m This represents the amplitude value of the reference frequency component. At this point, the suprathreshold single-frequency sensing sensitivity threshold of the target frequency component is only affected by the amplitude value of the reference frequency component.
[0098] The perception threshold JND can be expressed as:
[0099] JND u,v =SPSF u,v
[0100] In a possible implementation form The threshold for single-frequency sensing is determined by using the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain representation of the reference block as an index. The threshold for sensing the target frequency component is determined by using the threshold for single-frequency sensing sensitivity index table. The threshold for single-frequency sensing sensitivity index table is a table with frequency and amplitude values as index parameters.
[0101] The perception threshold JND can be expressed as:
[0102] JND u,v =SPSF u,v
[0103] In a possible implementation form The weighting factor is determined based on the inter-frequency masking threshold of the target frequency component.
[0104] For example, an inter-frequency masking threshold is determined based on the amplitude value of the reference block relative to the main signal in the frequency domain representation, the frequency of the reference block relative to the main signal in the frequency domain representation, the direction of the reference block relative to the main signal in the frequency domain representation, the frequency of the target frequency component, and the direction of the target frequency component. The perception threshold of the target frequency component is then determined using the inter-frequency masking threshold.
[0105]
[0106] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0107] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0108] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0109] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0110]
[0111] Among them, A s F represents the amplitude value relative to the main signal. s θ represents the frequency relative to the main signal. s Indicates the direction relative to the main signal, F m θ represents the frequency of the target frequency component. m This indicates the direction of the target frequency component. In the function of the inter-frequency masking characteristics generated relative to the main signal, as the frequency difference and direction difference between the relative main signal and the target frequency component increase, the inter-frequency masking threshold of the target frequency component decreases accordingly; as the amplitude value of the relative main signal increases, the inter-frequency masking threshold of the target frequency component increases accordingly.
[0112] The perception threshold JND can be expressed as:
[0113] JND u,v =IMCF u,v
[0114] For example, an inter-frequency masking threshold is determined based on the amplitude value of the reference block relative to the main signal in the frequency domain representation, the frequency of the reference block relative to the main signal in the frequency domain representation, and the frequency of the target frequency component. The perception threshold of the target frequency component is then determined using the inter-frequency masking threshold.
[0115]
[0116] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0117] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0118] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0119] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0120]
[0121] Among them, A s F represents the amplitude value relative to the main signal. s F represents the frequency relative to the main signal. m This represents the frequency of the target frequency component. In the function of the inter-frequency masking characteristics generated relative to the main signal, as the frequency difference between the main signal and the target frequency component increases, the inter-frequency masking threshold of the target frequency component decreases; conversely, as the amplitude of the main signal increases, the inter-frequency masking threshold of the target frequency component increases.
[0122] The perception threshold JND can be expressed as:
[0123] JND u,v =IMCF u,v
[0124] For example, an inter-frequency masking threshold is determined based on the amplitude value relative to the main signal in the frequency domain representation of the reference block, and the sensing threshold of the target frequency component is determined by the inter-frequency masking threshold.
[0125]
[0126] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0127] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0128] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0129] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0130] J(A s )=2×log(A s +1)
[0131] Among them, A s This represents the amplitude value relative to the main signal. In the function of the inter-frequency masking characteristics generated relative to the main signal, as the amplitude value of the relative main signal increases, the inter-frequency masking threshold of the target frequency component also increases.
[0132] The perception threshold JND can be expressed as:
[0133] JND u,v =IMCF u,v
[0134] For example, an inter-frequency masking threshold is determined based on the amplitude value of the relative main signal in the frequency domain representation of the reference block and the amplitude value of the reference frequency component in the frequency domain representation of the reference block, and the sensing threshold of the target frequency component is determined by the inter-frequency masking threshold.
[0135]
[0136] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0137] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0138] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0139] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0140]
[0141] Among them, A s A represents the amplitude value relative to the main signal. m This represents the amplitude value of the reference frequency component. In the function describing the inter-frequency masking characteristics of the target frequency component relative to the main signal, the inter-frequency masking threshold of the target frequency component increases as the amplitude value of the main signal increases.
[0142] The perception threshold JND can be expressed as:
[0143] JND u,v =IMCF u,v
[0144] In a possible implementation form The sensing threshold is determined based on the above-threshold single-frequency sensing sensitivity threshold and the inter-frequency masking threshold of the target frequency component.
[0145] Among them, SPSF u,v The IMCF represents the suprathreshold single-frequency sensing sensitivity threshold for the target frequency component. u,v The inter-frequency masking threshold, representing the target frequency component, and the sensing threshold JND, can be expressed as:
[0146] JND u,v =SPSF u,v +IMCF u,v
[0147] S203. Determine the weighting factor of the target frequency component based on the perception threshold.
[0148] In a possible implementation form The weighting factor is determined based on the sensing threshold of the target frequency component in S202:
[0149] w u,v =JND u,v
[0150] Where (u, v) represents the position index of the target frequency component.
[0151] S204. Obtain the weighted quantization step size based on the initial quantization step size of the target frequency component modulated by the weighting factor.
[0152] In a possible implementation form The weighted quantization step size is determined by correcting the initial quantization step size of the target frequency component based on the weighting factor.
[0153] For example, the above weighted quantization step size can satisfy:
[0154] AQ step (w u,v QP u,v ) = w u,v *Q step (QP u,v )
[0155] Among them, Q step (QP u,v ) represents the initial quantization step size for the target frequency component, AQ step (w u,v QP u,v) represents the corrected weighted quantization step size for the target frequency component.
[0156] For example, the above weighted quantization step size can satisfy:
[0157] AQ step (f u,v QP u,v ) = w u,v +Q step (QP u,v )
[0158] Among them, Q step (QP u,v ) represents the initial quantization step size for the target frequency component, AQ step (w u,v QP u,v ) represents the corrected weighted quantization step size for the target frequency component.
[0159] S205. Perform weighted quantization / weighted dequantization on the target frequency components according to the weighted quantization step size.
[0160] In a possible implementation form The amplitude value of the target frequency component of the block to be processed is quantized according to the weighted quantization step size to obtain the quantized coefficient of the amplitude value of the target frequency component of the block to be processed.
[0161] For example, the above weighted quantization formula can satisfy:
[0162]
[0163] Where, x u,v The amplitude value of the target frequency component of the block to be processed. The quantized coefficients of the target frequency component of the block to be processed. round(·) indicates rounding operation.
[0164] In a possible implementation form The quantized coefficients of the amplitude value of the target frequency component of the block to be processed are dequantized according to the weighted quantization step size to obtain the reconstructed amplitude value of the target frequency component of the block to be processed.
[0165] For example, the above weighted inverse quantization formula can satisfy:
[0166]
[0167] in, x′ is the quantized coefficient of the target frequency component of the block to be processed. u,v The reconstructed amplitude value of the target frequency component of the block to be processed.
[0168] Example 2:
[0169] Please refer to Figure 3 , Figure 3 This is a schematic diagram illustrating the functional module composition and connection of an image weighted quantization processing device according to an embodiment of the present invention. The weighted quantization processing device is described as a series of functional modules. It should be understood that the functional modules in the weighted quantization processing device can be connected and perform functions and / or perform functions synchronously in various orders, and are not limited to this. Figure 3 The connection method is shown. Regarding the expressions in the embodiments, it should be understood that "in one possible implementation" indicates the function of the module or the implementation method of the step, and "exemplarily" under the same "in one possible implementation" indicates different operations of implementing the module's function or method. Figure 3 As shown, the image weighted quantization processing device may include:
[0170] S301, Frequency domain transformation module of image weighted quantization processing device.
[0171] The main function of the frequency domain transformation module of the image weighted quantization processing device is to obtain the frequency domain representation of the reference block of the block to be processed in the image.
[0172] In a possible implementation form The frequency domain representation of the adjacent coded block is obtained as the frequency domain representation of the reference block.
[0173] For example, the frequency domain representation of the left adjacent coded block in the space to be processed is used as the frequency domain representation of the reference block.
[0174] For example, the frequency domain representation of the upper adjacent coded block in the space to be processed is used as the frequency domain representation of the reference block.
[0175] In a possible implementation form The frequency domain representation of the adjacent decoded block is obtained as the frequency domain representation of the reference block.
[0176] For example, the frequency domain representation of the left-side adjacent decoded block in the block space to be processed is used as the frequency domain representation of the reference block.
[0177] For example, the frequency domain representation of the upper adjacent decoded block in the above-mentioned block space to be processed is used as the frequency domain representation of the reference block.
[0178] In a possible implementation form The frequency domain representation of the reference block is obtained by performing a frequency domain transformation on adjacent coded or decoded blocks.
[0179] It should be noted that the specific method of change can be any method that can be conceived by those skilled in the art, and the present invention does not impose any specific limitations on it.
[0180] For example, the frequency domain representation of the reference block of the block to be processed can be obtained by performing a block-integer discrete cosine transform (DCT) on adjacent coded blocks or adjacent decoded blocks.
[0181] For example, taking a 32×32 transform size as an example, the frequency domain expression can be obtained through the following integer DCT transform formula:
[0182]
[0183] in, This is the transform coefficient matrix of the 32×32 integer DCT transform frequency components. It is a 32×32 integer DCT transformation matrix. It is a 32×32 matrix in the spatial domain. for The transpose of .
[0184] For example, the frequency domain representation of the reference block of the block to be processed can be obtained by performing a block-based discrete Fourier transform (DFT) on the reference block of an adjacent coded block or an adjacent decoded block.
[0185] For example, the frequency domain representation can be obtained through the following two-dimensional DFT transform formula:
[0186] Consider an N×N image f(x, y), the above two-dimensional DFT formula is:
[0187]
[0188] Where F(u, v) represents the frequency domain transform coefficients. In the transform domain, u and v represent the horizontal and vertical frequencies, respectively. The exponential terms in the above two-dimensional DFT are extended to the form of sine and cosine terms, where the variables u and v are used to determine their frequencies.
[0189] Even if f(x, y) is a real number, its transform is usually a complex number. A key intuitive method for analyzing a transform is to calculate its spectrum, i.e., the amplitude of F(u, v). Let R(u, v) and I(u, v) represent the real and imaginary parts of F(u, v), respectively. Then the Fourier spectrum is defined as:
[0190] For example, a frequency domain representation of a reference block of the block to be processed can be obtained by performing a DCT transform on adjacent coded blocks or adjacent decoded blocks.
[0191] For example, the frequency domain representation is obtained according to the type II two-dimensional DCT formula:
[0192] Consider an N×N image f(x, y), the formula for Class II 2D DCT is:
[0193]
[0194]
[0195] Where F(u, v) are frequency domain transformation coefficients, x, y are spatial domain discrete signal position indices, u, v are frequency domain discrete signal position indices, and u, v = 0, 1, ..., N-1.
[0196] For example, a discrete sine transform (DST) can be performed on adjacent coded blocks or adjacent decoded blocks to obtain the frequency domain representation of the reference block of the block to be processed.
[0197] For example, the frequency domain expression can be obtained from the two-dimensional DST formula:
[0198] Consider an N×N image f(x, y), the two-dimensional DST formula is:
[0199]
[0200] in,
[0201] S302, Perception threshold calculation module of image weighted quantization processing device.
[0202] The main function of the perception threshold calculation module of the image weighted quantization processing device is to determine the perception threshold of the target frequency component based on the information of the target frequency component of the block to be processed and the information of the frequency domain expression of the reference block. The information of the target frequency component includes at least the frequency of the target frequency component, and the perception threshold of the target frequency component includes at least the suprathreshold single-frequency perception sensitivity threshold of the target frequency component.
[0203] In a possible implementation form The threshold of the target frequency component is determined by the suprathreshold single-frequency sensing sensitivity function based on the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block. The sensing threshold of the target frequency component is then determined by the suprathreshold single-frequency sensing sensitivity function.
[0204] For example, the suprathreshold single-frequency sensing sensitivity threshold is calculated using a suprathreshold single-frequency sensing sensitivity function as shown in the following formula:
[0205]
[0206] Among them, SPSF(F mA0) represents the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function, F m A represents the spatial frequency of the target frequency component. m This represents the amplitude value of the reference frequency component.
[0207] The perception threshold JND can be expressed as:
[0208] JND u,v =SPSF u,v
[0209] To better measure the human eye's perception of signal frequency in space, the signal frequency needs to be converted into spatial frequency, measured in cycles per degree. Spatial frequency refers to the number of periodic changes in brightness per unit length, reflecting the spatial variation of pixel grayscale in an image. Under constant viewing conditions, for a given frequency f... m A sinusoidal signal with a spatial frequency F m The value of is uniquely determined by the following formula:
[0210]
[0211] Where M represents the number of pixels in the vertical direction of the image, and L represents the viewing distance of the subject. In the example function provided, M = L = 1080.
[0212] In a possible implementation form The threshold of the target frequency component is determined by the suprathreshold single-frequency sensing sensitivity function based on the frequency of the target frequency component of the block to be processed, and the sensing threshold of the target frequency component is determined by the suprathreshold single-frequency sensing sensitivity function.
[0213] For example, the suprathreshold single-frequency sensing sensitivity threshold is calculated using a suprathreshold single-frequency sensing sensitivity function as shown in the following formula:
[0214]
[0215] Among them, SPSF(F m F is represented as the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function. m This represents the spatial frequency of the target frequency component. At this point, the suprathreshold single-frequency sensing sensitivity threshold of the target frequency component is only affected by the frequency of the target frequency component.
[0216] The perception threshold JND can be expressed as:
[0217] JND u,v =SPSF u,v
[0218] In a possible implementation formThe threshold value of the target frequency component is determined by the above-threshold single-frequency sensing sensitivity function based on the amplitude value of the reference frequency component in the frequency domain expression of the reference block, and the sensing threshold of the target frequency component is determined by the above-threshold single-frequency sensing sensitivity function.
[0219] For example, the suprathreshold single-frequency sensing sensitivity threshold is calculated using a suprathreshold single-frequency sensing sensitivity function as shown in the following formula:
[0220]
[0221] Among them, SPSF(A) m A is represented as a suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function. m This represents the amplitude value of the reference frequency component. At this point, the suprathreshold single-frequency sensing sensitivity threshold of the target frequency component is only affected by the amplitude value of the reference frequency component.
[0222] The perception threshold JND can be expressed as:
[0223] JND u,v =SPSF u,v
[0224] In a possible implementation form The threshold for single-frequency sensing is determined by using the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain representation of the reference block as an index. The threshold for sensing the target frequency component is determined by using the threshold for single-frequency sensing sensitivity index table. The threshold for single-frequency sensing sensitivity index table is a table with frequency and amplitude values as index parameters.
[0225] The perception threshold JND can be expressed as:
[0226] JND u,v =SPSF u,v
[0227] In a possible implementation form The weighting factor is determined based on the inter-frequency masking threshold of the target frequency component.
[0228] For example, an inter-frequency masking threshold is determined based on the amplitude value of the reference block relative to the main signal in the frequency domain representation, the frequency of the reference block relative to the main signal in the frequency domain representation, the direction of the reference block relative to the main signal in the frequency domain representation, the frequency of the target frequency component, and the direction of the target frequency component. The perception threshold of the target frequency component is then determined using the inter-frequency masking threshold.
[0229]
[0230] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0231] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0232] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0233] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0234]
[0235] Among them, A s F represents the amplitude value relative to the main signal. s θ represents the frequency relative to the main signal. s Indicates the direction relative to the main signal, F m θ represents the frequency of the target frequency component. m This indicates the direction of the target frequency component. In the function of the inter-frequency masking characteristics generated relative to the main signal, as the frequency difference and direction difference between the relative main signal and the target frequency component increase, the inter-frequency masking threshold of the target frequency component decreases accordingly; as the amplitude value of the relative main signal increases, the inter-frequency masking threshold of the target frequency component increases accordingly.
[0236] The perception threshold JND can be expressed as:
[0237] JND u,v =IMCF u,v
[0238] For example, an inter-frequency masking threshold is determined based on the amplitude value of the reference block relative to the main signal in the frequency domain representation, the frequency of the reference block relative to the main signal in the frequency domain representation, and the frequency of the target frequency component. The perception threshold of the target frequency component is then determined using the inter-frequency masking threshold.
[0239]
[0240] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0241] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0242] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0243] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0244]
[0245] Among them, A s F represents the amplitude value relative to the main signal. s F represents the frequency relative to the main signal. m This represents the frequency of the target frequency component. In the function of the inter-frequency masking characteristics generated relative to the main signal, as the frequency difference between the main signal and the target frequency component increases, the inter-frequency masking threshold of the target frequency component decreases; conversely, as the amplitude of the main signal increases, the inter-frequency masking threshold of the target frequency component increases.
[0246] The perception threshold JND can be expressed as:
[0247] JND u,v =IMCF u,v
[0248] For example, an inter-frequency masking threshold is determined based on the amplitude value relative to the main signal in the frequency domain representation of the reference block, and the sensing threshold of the target frequency component is determined by the inter-frequency masking threshold.
[0249]
[0250] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0251] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0252] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0253] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0254] J(A s )=2×log(A s +1)
[0255] Among them, A s This represents the amplitude value relative to the main signal. In the function of the inter-frequency masking characteristics generated relative to the main signal, as the amplitude value of the relative main signal increases, the inter-frequency masking threshold of the target frequency component also increases.
[0256] The perception threshold JND can be expressed as:
[0257] JND u,v =IMCF u,v
[0258] For example, an inter-frequency masking threshold is determined based on the amplitude value of the relative main signal in the frequency domain representation of the reference block and the amplitude value of the reference frequency component in the frequency domain representation of the reference block, and the sensing threshold of the target frequency component is determined by the inter-frequency masking threshold.
[0259]
[0260] Where K represents the number of relative main signals, K is at least 1 and at most does not exceed the total number of frequency components in the block to be processed.
[0261] The relative main signal can be any frequency component whose amplitude value in the frequency domain representation of the reference block is greater than the amplitude value of the reference frequency component in the frequency domain representation of the reference block.
[0262] The relative main signal can be the two frequency components that are closest to the target frequency component.
[0263] The function representing the inter-frequency masking characteristics of the target frequency component relative to the main signal can be expressed as:
[0264]
[0265] Among them, A s A represents the amplitude value relative to the main signal. m This represents the amplitude value of the reference frequency component. In the function describing the inter-frequency masking characteristics of the target frequency component relative to the main signal, the inter-frequency masking threshold of the target frequency component increases as the amplitude value of the main signal increases.
[0266] The perception threshold JND can be expressed as:
[0267] JND u,v =IMCF u,v
[0268] In a possible implementation form The sensing threshold is determined based on the above-threshold single-frequency sensing sensitivity threshold and the inter-frequency masking threshold of the target frequency component.
[0269] Among them, SPSF u,v The IMCF represents the suprathreshold single-frequency sensing sensitivity threshold for the target frequency component. u,v The inter-frequency masking threshold, representing the target frequency component, and the sensing threshold JND, can be expressed as:
[0270] JND u,v =SPSF u,v +IMCF u,v
[0271] S303, Weighting factor export module of image weighted quantization processing device.
[0272] The main function of the weighting factor derivation module of the image weighted quantization processing device is to determine the weighting factor of the target frequency component based on the perception threshold of the target frequency component.
[0273] In a possible implementation form The weighting factor is determined based on the sensing threshold of the target frequency component in S202:
[0274] w u,v =JND u,v
[0275] Where (u, v) represents the position index of the target frequency component.
[0276] S304, Weighted quantization step size modulation module of image weighted quantization processing device.
[0277] The main function of the weighted quantization step size modulation module of the image weighted quantization processing device is to determine the weighted quantization step size of the target frequency component by modulating the initial quantization step size of the target frequency component according to the weighting factor.
[0278] In a possible implementation form The weighted quantization step size is determined by correcting the initial quantization step size of the target frequency component based on the weighting factor.
[0279] For example, the above weighted quantization step size can satisfy:
[0280] AQ step (w u,v QP u,v ) = w u,v *Q step (QP u,v )
[0281] Among them, Q step (QP u,v ) represents the initial quantization step size for the target frequency component, AQ step (w u,v QP u,v ) represents the corrected weighted quantization step size for the target frequency component.
[0282] For example, the above weighted quantization step size can satisfy:
[0283] AQ step (f u,v QP u,v ) = w u,v +Q step (QP u,v )
[0284] Among them, Q step (QP u,v ) represents the initial quantization step size for the target frequency component, AQ step (w u,v QP u,v ) represents the corrected weighted quantization step size for the target frequency component.
[0285] S305, Quantization processing module of image weighted quantization processing device.
[0286] The main function of the quantization processing module of the image weighted quantization processing device is to perform quantization or dequantization processing according to the weighted quantization step size using one of the following methods: a) quantizing the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the quantized coefficients of the amplitude value of the target frequency component of the block to be processed; b) dequantizing the quantized coefficients of the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the reconstructed amplitude value of the target frequency component of the block to be processed.
[0287] In a possible implementation form The amplitude value of the target frequency component of the block to be processed is quantized according to the weighted quantization step size to obtain the quantized coefficient of the amplitude value of the target frequency component of the block to be processed.
[0288] For example, the above weighted quantization formula can satisfy:
[0289]
[0290] Where, x u,v The amplitude value of the target frequency component of the block to be processed. The quantized coefficients of the target frequency component of the block to be processed. round(·) indicates rounding operation.
[0291] In a possible implementation form The quantized coefficients of the amplitude value of the target frequency component of the block to be processed are dequantized according to the weighted quantization step size to obtain the reconstructed amplitude value of the target frequency component of the block to be processed.
[0292] For example, the above weighted inverse quantization formula can satisfy:
[0293]
[0294] in, x′ is the quantized coefficient of the target frequency component of the block to be processed. u,v The reconstructed amplitude value of the target frequency component of the block to be processed.
[0295] Example 3
[0296] Embodiments of the present invention also provide a computer, including a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to perform the image weighted quantization method shown in the present invention and the foregoing embodiments.
[0297] Example 4
[0298] Embodiments of the present invention also provide a computer-readable storage medium comprising a stored program, wherein the computer-readable storage medium stores computer instructions for causing a computer to execute the present invention and the image weighted quantization method shown in the foregoing embodiments.
[0299] It will be apparent to those skilled in the art that the modules or steps of this invention can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. Optionally, they can be implemented using computer-executable program code, thereby storing them in a storage device for execution by a computing device. In some cases, the steps shown or described can be performed in a different order than those presented herein, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, this invention is not limited to any particular hardware and software combination.
[0300] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. An image weighted quantization processing method, characterized in that, include: Obtain the frequency domain representation of the reference block of the block to be processed in the image; The perception threshold of the target frequency component is determined based on the information of the target frequency component of the block to be processed and the information of the frequency domain expression of the reference block. The information of the target frequency component includes at least the frequency of the target frequency component, and the perception threshold of the target frequency component includes at least the suprathreshold single-frequency perception sensitivity threshold and / or the inter-frequency masking threshold of the target frequency component. The above-threshold single-frequency sensing sensitivity threshold refers to the increase in amplitude of the target frequency component from 0 to the point where the frequency component can be detected, or the increase or decrease in amplitude of the target frequency component from a non-zero value to the point where the signal change can be detected; the inter-frequency masking threshold refers to the increase in amplitude of the target frequency component that the human eye can just see due to the masking effect between different frequency components. The weighting factor of the target frequency component is determined based on the sensing threshold of the target frequency component. The weighted quantization step size of the target frequency component is determined based on the initial quantization step size of the target frequency component modulated by the weighting factor. Based on the weighted quantization step size, process according to one of the following methods: a) Quantize the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the quantized coefficient of the amplitude value of the target frequency component of the block to be processed. b) Perform inverse quantization on the quantized coefficients of the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the reconstructed amplitude value of the target frequency component of the block to be processed.
2. The image weighted quantization processing method as described in claim 1, characterized in that, The frequency domain representation of the reference block is obtained by the frequency domain representation of the adjacent coded blocks or the adjacent decoded blocks of the block to be processed.
3. The image weighted quantization processing method as described in claim 1, characterized in that, The method for determining the suprathreshold single-frequency sensing sensitivity threshold of the target frequency component includes at least one of the following: a) Based on the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block, the threshold of the suprathreshold single-frequency sensing sensitivity is determined by the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function with frequency and amplitude as independent variables. b) Using the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block as indexes, the above-threshold single-frequency sensing sensitivity threshold is determined through the above-threshold single-frequency sensing sensitivity threshold index table, which is a table with frequency and amplitude values as index parameters.
4. The image weighted quantization processing method as described in claim 1, characterized in that, The method for determining the inter-frequency masking threshold of the target frequency component includes at least one of the following: a) Determine the inter-frequency masking threshold based on the amplitude value of the reference frequency component in the frequency domain representation of the reference block and the amplitude value relative to the main signal in the frequency domain representation of the reference block; b) Determine the inter-frequency masking threshold based on the frequency of the reference frequency component in the frequency domain representation of the reference block, and the amplitude and frequency of the frequency components relative to the main signal in the frequency domain representation of the reference block. c) Determine the inter-frequency masking threshold based on the frequency and direction of the reference frequency component in the frequency domain representation of the reference block, and the amplitude, frequency, and direction of the frequency components relative to the main signal in the frequency domain representation of the reference block. The reference frequency component refers to the frequency component in the frequency domain representation of the reference block that has the same frequency as the target frequency component, and the relative main signal refers to at least one frequency component among the other frequency components in the reference block besides the reference frequency component.
5. An image weighted quantization processing device, characterized in that, Includes the following processing modules: Frequency domain transformation module: Obtains the frequency domain representation of the reference block of the block to be processed in the image; Perception threshold calculation module: Determines the perception threshold of the target frequency component based on the information of the target frequency component of the block to be processed and the information of the frequency domain expression of the reference block. The information of the target frequency component includes at least the frequency of the target frequency component, and the perception threshold of the target frequency component includes at least the suprathreshold single-frequency perception sensitivity threshold and / or the inter-frequency masking threshold of the target frequency component. The above-threshold single-frequency sensing sensitivity threshold refers to the increase in amplitude of the target frequency component from 0 to the point where the frequency component can be detected, or the increase or decrease in amplitude of the target frequency component from a non-zero value to the point where the signal change can be detected; the inter-frequency masking threshold refers to the increase in amplitude of the target frequency component that the human eye can just see due to the masking effect between different frequency components. Weighting factor derivation module: Determines the weighting factor of the target frequency component based on the sensing threshold of the target frequency component; Weighted quantization step size modulation module: determines the weighted quantization step size of the target frequency component based on the initial quantization step size of the target frequency component modulated by the weighting factor; Quantization processing module: Based on the weighted quantization step size, process the data using one of the following methods: a) Quantize the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the quantized coefficient of the amplitude value of the target frequency component of the block to be processed. b) Perform inverse quantization on the quantized coefficients of the amplitude value of the target frequency component of the block to be processed according to the weighted quantization step size to obtain the reconstructed amplitude value of the target frequency component of the block to be processed.
6. The image weighted quantization processing apparatus as described in claim 5, characterized in that, The frequency domain representation of the reference block is obtained by the frequency domain representation of the adjacent coded blocks or the adjacent decoded blocks of the block to be processed.
7. The image weighted quantization processing apparatus as described in claim 5, characterized in that, The method for determining the suprathreshold single-frequency sensing sensitivity threshold of the target frequency component includes at least one of the following: a) Based on the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block, the threshold of the suprathreshold single-frequency sensing sensitivity is determined by the suprathreshold single-frequency sensing sensitivity function, which is a monotonically non-decreasing function with frequency and amplitude as independent variables. b) Using the frequency of the target frequency component of the block to be processed and the amplitude value of the reference frequency component in the frequency domain expression of the reference block as indexes, the above-threshold single-frequency sensing sensitivity threshold is determined through the above-threshold single-frequency sensing sensitivity threshold index table, which is a table with frequency and amplitude values as index parameters.
8. The image weighted quantization processing apparatus as described in claim 5, characterized in that, The method for determining the inter-frequency masking threshold of the target frequency component includes at least one of the following: a) Determine the inter-frequency masking threshold based on the amplitude value of the reference frequency component in the frequency domain representation of the reference block and the amplitude value relative to the main signal in the frequency domain representation of the reference block; b) Determine the inter-frequency masking threshold based on the frequency of the reference frequency component in the frequency domain representation of the reference block, and the amplitude and frequency of the frequency components relative to the main signal in the frequency domain representation of the reference block. c) Determine the inter-frequency masking threshold based on the frequency and direction of the reference frequency component in the frequency domain representation of the reference block, and the amplitude, frequency, and direction of the frequency components relative to the main signal in the frequency domain representation of the reference block. The reference frequency component refers to the frequency component in the frequency domain representation of the reference block that has the same frequency as the target frequency component, and the relative main signal refers to at least one frequency component among the other frequency components in the reference block besides the reference frequency component.
9. A computer, comprising a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the computer instructions to perform the image weighted quantization processing method as described in any one of claims 1-4.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that are used to cause a computer to perform the method as described in any one of claims 1-4.