CN109462758B - Intra-frame prediction mode determination method, electronic device, system and storage medium - Google Patents

Intra-frame prediction mode determination method, electronic device, system and storage medium Download PDF

Info

Publication number
CN109462758B
CN109462758B CN201811174297.8A CN201811174297A CN109462758B CN 109462758 B CN109462758 B CN 109462758B CN 201811174297 A CN201811174297 A CN 201811174297A CN 109462758 B CN109462758 B CN 109462758B
Authority
CN
China
Prior art keywords
intra
target
prediction mode
frame prediction
determining
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
CN201811174297.8A
Other languages
Chinese (zh)
Other versions
CN109462758A (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.)
Shenzhen Onething Technology Co Ltd
Original Assignee
Shenzhen Onething 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 Shenzhen Onething Technology Co Ltd filed Critical Shenzhen Onething Technology Co Ltd
Priority to CN201811174297.8A priority Critical patent/CN109462758B/en
Publication of CN109462758A publication Critical patent/CN109462758A/en
Application granted granted Critical
Publication of CN109462758B publication Critical patent/CN109462758B/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/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/157Assigned coding mode, i.e. the coding mode being predefined or preselected to be further used for selection of another element or parameter
    • H04N19/159Prediction type, e.g. intra-frame, inter-frame or bidirectional frame prediction
    • 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/12Selection from among a plurality of transforms or standards, e.g. selection between discrete cosine transform [DCT] and sub-band transform or selection between H.263 and H.264
    • H04N19/122Selection of transform size, e.g. 8x8 or 2x4x8 DCT; Selection of sub-band transforms of varying structure or type
    • 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/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock

Landscapes

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

Abstract

The invention discloses an intra-frame prediction mode determining method, electronic equipment, a system and a storage medium, wherein the method comprises the following steps: acquiring angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes; normalizing the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode; determining a target macro block in an intra-frame prediction area; calculating a target gradient of the target macro block; calculating a target difference value between the target gradient and each target angle information; determining M undetermined intra-frame prediction modes from all the intra-frame prediction modes according to the target difference value; predicting by adopting the M undetermined intra-frame prediction modes to obtain M cost values; and according to the M cost values, determining a target intra-frame prediction mode of the target macro block from the M undetermined intra-frame prediction modes, so that the target intra-frame prediction mode can be quickly determined, and the prediction efficiency is improved.

Description

Intra-frame prediction mode determination method, electronic device, system and storage medium
Technical Field
The present invention relates to the field of intra prediction, and in particular, to an intra prediction mode determination method, an electronic device, a system, and a storage medium.
Background
The intra-frame prediction is one of core technologies of the h.264 video coding standard, and means that the correlation of a video spatial domain is utilized, and a current pixel is predicted by using a pixel coded by a current image, so as to achieve the purpose of removing video spatial redundancy. The intra 4x4 prediction modes for each Macroblock (MB) of h.264 are up to 9, including DC mode and 8 angle-dependent modes. Therefore, in the h.264 encoding process, it is necessary to traverse the 9 intra prediction modes, which requires a large amount of computation.
Disclosure of Invention
The invention mainly aims to provide an intra-frame prediction mode determination method, electronic equipment, a system and a storage medium, and aims to solve the technical problem that a large amount of calculation is consumed when 9 intra-frame prediction modes are traversed in an intra-frame prediction process.
To achieve the above object, the present invention provides an intra prediction mode determining method, comprising:
acquiring angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes;
normalizing the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode;
determining a target macro block in an intra-frame prediction area;
calculating a target gradient of the target macro block;
calculating a target difference value between the target gradient and each target angle information;
determining M undetermined intra-frame prediction modes from all the intra-frame prediction modes according to the target difference value;
predicting by adopting the M undetermined intra-frame prediction modes to obtain M cost values;
determining a target intra-prediction mode for the target macroblock from the M pending intra-prediction modes according to the M cost values.
Preferably, M is greater than 0 and M is less than 8, and the normalizing the angle information corresponding to each intra prediction mode includes:
the angle information corresponding to each intra prediction mode is normalized with reference to the intra prediction mode 8 of h.264.
Preferably, the determining the target macro block in the intra prediction region includes:
acquiring all macro blocks in an intra-frame prediction area;
calculating the gradient of each macro block in all the macro blocks;
when the gradient of a macro block is greater than or equal to 0 degree and less than or equal to a preset value, determining that the macro block is effective;
determining a valid macroblock as the target macroblock.
Preferably, the calculating the target gradient of the target macroblock comprises:
determining the difference value between every two adjacent pixels in the target macro block;
calculating the average value of all the difference values;
determining the target gradient from the average.
Preferably, the determining M pending intra prediction modes from among the all intra prediction modes according to the difference value comprises:
sequencing the target difference values in a descending order;
acquiring (M-1) intra-frame prediction modes corresponding to the target difference value of the previous (M-1) bits;
determining the (M-1) intra-frame prediction modes and the direct current coefficient DC intra-frame prediction mode as the M pending intra-frame prediction modes.
Preferably, the determining, according to the M cost values, a target intra-prediction mode of the target macroblock from the M pending intra-prediction modes comprises:
obtaining a minimum target cost value from the M cost values;
and determining the intra-frame prediction mode corresponding to the target cost value as the target intra-frame prediction mode.
To achieve the above object, the present invention further provides an electronic device including a memory and a processor, the memory having stored thereon an intra prediction mode determination program executable on the processor, the intra prediction mode determination program implementing the intra prediction mode determination method when executed by the processor.
Preferably, the electronic device is a node constituting a content distribution network or a blockchain network.
To achieve the above object, the present invention further provides an intra prediction mode determination system, comprising:
the device comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes;
the normalization unit is used for performing normalization processing on the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode;
a determination unit configured to determine a target macroblock within an intra prediction region;
a calculation unit for calculating a target gradient of the target macro block;
the calculation unit is further used for calculating a target difference value between the target gradient and each kind of target angle information;
the determining unit is further configured to determine M pending intra prediction modes from the all intra prediction modes according to the target difference;
the prediction unit is used for predicting by adopting the M undetermined intra-frame prediction modes to obtain M cost values;
the determining unit is further configured to determine a target intra-prediction mode of the target macroblock from the M pending intra-prediction modes according to the M cost values.
Preferably, M is greater than 0 and M is less than 8, and the normalization unit is specifically configured to:
the angle information corresponding to each intra prediction mode is normalized with reference to the intra prediction mode 8 of h.264.
Preferably, the determining unit determining the target macroblock within the intra prediction region includes:
acquiring all macro blocks in an intra-frame prediction area;
calculating the gradient of each macro block in all the macro blocks;
when the gradient of a macro block is greater than or equal to 0 degree and less than or equal to a preset value, determining that the macro block is effective;
determining a valid macroblock as the target macroblock.
Preferably, the calculating unit calculating the target gradient of the target macroblock includes:
determining the difference value between every two adjacent pixels in the target macro block;
calculating the average value of all the difference values;
determining the target gradient from the average.
Preferably, the determining unit determines M pending intra prediction modes from the all intra prediction modes according to the difference value, including:
sequencing the target difference values in a descending order;
acquiring (M-1) intra-frame prediction modes corresponding to the target difference value of the previous (M-1) bits;
determining the (M-1) intra-frame prediction modes and the direct current coefficient DC intra-frame prediction mode as the M pending intra-frame prediction modes.
Preferably, the determining unit determines the target intra prediction mode of the target macroblock from the M pending intra prediction modes according to the M cost values by:
obtaining a minimum target cost value from the M cost values;
and determining the intra-frame prediction mode corresponding to the target cost value as the target intra-frame prediction mode.
To achieve the above object, the present invention further provides a computer-readable storage medium having an intra prediction mode determination program stored thereon, the intra prediction mode determination program being executable by one or more processors to implement the intra prediction mode determination method.
To achieve the above object, the present invention further provides a computer program product comprising computer instructions which, when run on a computer, make the computer execute the intra prediction mode determination method.
To sum up, the present invention obtains angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes, performs normalization processing on the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode, associates the intra-frame prediction modes with the angle information to determine a target macro block in an intra-frame prediction region to eliminate interference of other macro blocks and avoid redundant calculation, thereby purposefully determining, calculating a target gradient of the target macro block, and calculating a target difference between the target gradient and each target angle information, according to the target difference, determining M undetermined intra-frame prediction modes from all intra-frame prediction modes, and performing prediction by using the M undetermined intra-frame prediction modes to obtain M cost values, thereby avoiding traversing all intra-frame prediction modes, and the traversal efficiency is improved, and a target intra-frame prediction mode of the target macro block is determined from the M undetermined intra-frame prediction modes according to the M cost values, so that the target intra-frame prediction mode is determined quickly and accurately.
Drawings
FIG. 1 is a schematic flow chart of an embodiment of the present invention;
fig. 2 is a schematic diagram of an internal structure of an electronic device according to an embodiment of the disclosure;
FIG. 3 is a functional block diagram of the intra prediction mode determination process of FIG. 2;
the implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims of the present application and in the drawings described above, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced otherwise than as specifically illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
It should be noted that the description relating to "first", "second", etc. in the present invention is for descriptive purposes only and is not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In addition, technical solutions between various embodiments may be combined with each other, but must be realized by a person skilled in the art, and when the technical solutions are contradictory or cannot be realized, such a combination should not be considered to exist, and is not within the protection scope of the present invention.
The invention provides an intra prediction mode determination method.
Referring to fig. 1, fig. 1 is a schematic flow chart according to an embodiment of the invention. The order of the steps in the flow diagram can be changed and some steps can be omitted according to different requirements.
The intra-frame prediction mode determination method is applied to one or more electronic devices, which are devices capable of automatically performing numerical calculation and/or information processing according to preset or stored instructions, and the hardware thereof includes, but is not limited to, a microprocessor, an Application Specific Integrated Circuit (ASIC), a Programmable Gate Array (FPGA), a Digital Signal Processor (DSP), an embedded device, and the like.
The electronic device may be any electronic product capable of performing human-computer interaction with a user, for example, a Personal computer, a tablet computer, a smart phone, a Personal Digital Assistant (PDA), a game machine, an interactive Internet Protocol Television (IPTV), an intelligent wearable device, and the like.
The electronic device may also include a network device and/or a user device. The network device includes, but is not limited to, a single network server, a server group consisting of a plurality of network servers, or a Cloud Computing (Cloud Computing) based Cloud consisting of a large number of hosts or network servers.
The Network where the electronic device is located includes, but is not limited to, the internet, a wide area Network, a metropolitan area Network, a local area Network, a Virtual Private Network (VPN), and the like.
In one embodiment, the method comprises:
s10, the electronic device obtains angle information corresponding to each intra prediction mode among all intra prediction modes.
In at least one embodiment of the present invention, h.264 is a highly compressed digital video codec standard proposed by the joint video team consisting of the video coding experts group and the moving picture experts group jointly, and has 9 intra prediction modes, i.e. all intra prediction modes include: DC (Direct coefficient) intra prediction mode, intra prediction mode 0 (vertical intra prediction mode), intra prediction mode 1 (horizontal intra prediction mode), intra prediction mode 3 (lower left diagonal intra prediction mode), intra prediction mode 4 (lower right diagonal intra prediction mode), intra prediction mode 5 (right vertical intra prediction mode), intra prediction mode 6 (lower horizontal intra prediction mode), intra prediction mode 7 (left vertical intra prediction mode), and intra prediction mode 8 (upper horizontal intra prediction mode).
Preferably, among all the intra prediction modes, other intra prediction modes except the DC intra prediction mode are related to the angle information.
Preferably, the angle information corresponding to the intra-frame prediction mode 0 is a vertical direction, the angle information corresponding to the intra-frame prediction mode 1 is a horizontal direction, the angle information corresponding to the intra-frame prediction mode 3 is a direction vertically deviated from the left 45 degrees, the angle information corresponding to the intra-frame prediction mode 4 is a direction vertically deviated from the right 45 degrees, the angle information corresponding to the intra-frame prediction mode 5 is a direction vertically deviated from the right 26.6 degrees, the angle information corresponding to the intra-frame prediction mode 6 is a direction horizontally deviated from the lower 26.6 degrees, the angle information corresponding to the intra-frame prediction mode 7 is a direction vertically deviated from the left 26.6 degrees, and the angle information corresponding to the intra-frame prediction mode 7 is a direction horizontally deviated from the upper 26.6 degrees.
And S11, the electronic equipment normalizes the angle information corresponding to each intra-frame prediction mode to obtain the target angle information corresponding to each intra-frame prediction mode.
In at least one embodiment of the present invention, in order to facilitate the subsequent matching of the angle information corresponding to each intra-frame prediction mode with the gradient, the electronic device performs normalization processing on the angle information corresponding to each intra-frame prediction mode, so as to compare the angle information corresponding to each intra-frame prediction mode with the gradient divided into the same dimension.
Preferably, M is greater than 0 and M is less than 8, and the electronic device normalizing the angle information corresponding to each intra-frame prediction mode includes:
the electronic device normalizes the angle information corresponding to each intra-frame prediction mode with the intra-frame prediction mode 8 of the h.264 as a reference.
Furthermore, 8 intra-prediction modes in h.264 are angle-dependent, an angle range of 135 degrees +26.6 degrees-161.6 degrees is formed from the intra-prediction mode 0 to the intra-prediction mode 8, and the electronic device normalizes the angle information corresponding to each intra-prediction mode with the intra-prediction mode 8 as a reference, including:
for the intra-frame prediction mode 8, the original angle information is 26.6 degrees above the horizontal, and the electronic device calculates that 26.6-26.6 degrees are 0 degree, so that the corresponding target angle information after normalization of the intra-frame prediction mode 8 is 0 degree;
for the intra-frame prediction mode 1, the original angle information is in the horizontal direction, and the electronic device calculates that the angle is 0 degree +26.6 degrees to 26.6 degrees, so that the corresponding target angle information after normalization of the intra-frame prediction mode 1 is obtained to be 26.6 degrees;
for the intra-frame prediction mode 6, the original angle information is 26.6 degrees below the horizontal, and the electronic device calculates that 26.6 degrees +26.6 degrees is 53.2 degrees, so that the corresponding target angle information after normalization of the intra-frame prediction mode 6 is 53.2 degrees;
for the intra-frame prediction mode 4, the original angle information is vertically deviated from the right by 45 degrees, and the electronic device calculates that the angle of 45 degrees +26.6 degrees is 71.6 degrees, so that the corresponding target angle information after normalization of the intra-frame prediction mode 4 is 71.6 degrees;
for the intra-frame prediction mode 5, the original angle information is 26.6 degrees vertically deviated from the right, and the electronic device calculates that (45 degrees-26.6 degrees) +45 degrees +26.6 degrees is 90 degrees, so that the corresponding target angle information after normalization of the intra-frame prediction mode 5 is 90 degrees;
for the intra-frame prediction mode 0, the original angle information is vertical, and the electronic device calculates 90 degrees +26.6 degrees to 116.6 degrees, so that the corresponding target angle information after normalization of the intra-frame prediction mode 0 is 116.6 degrees;
for the intra-frame prediction mode 7, the original angle information is 26.6 degrees which is vertically deviated from the left, and the electronic device calculates 116.6 degrees +26.6 degrees to 142.6 degrees, so that the corresponding target angle information after normalization of the intra-frame prediction mode 7 is 142.6 degrees;
for the intra-frame prediction mode 3, the original angle information is vertically deviated from the left by 45 degrees, and the electronic device calculates 116.6 degrees +45 degrees as 161.6 degrees, so as to obtain 161.6 degrees of corresponding target angle information after normalization of the intra-frame prediction mode 3.
S12, the electronic device determines a target macroblock within the intra-predicted region.
In at least one embodiment of the present invention, the electronic device determining a target macroblock within an intra-predicted region comprises:
the electronic equipment acquires all macro blocks in an intra-frame prediction area, calculates the gradient of each macro block in all the macro blocks, and determines that the macro blocks are effective when the gradient of the macro blocks is greater than or equal to 0 degree and less than or equal to a preset value, and determines the effective macro blocks as the target macro blocks.
For example: the preset value may include, but is not limited to, 161.6 degrees.
It can be understood that, since the normalized angles of the intra prediction mode form an angle range of 161.6 degrees, and the gradient of each macroblock is in one dimension with the angle information corresponding to the intra prediction mode, the electronic device will perform intra prediction using a conventional intra prediction algorithm for macroblocks with gradients outside the angle range of (0-161.6 degrees).
Preferably, for the macro block with the gradient greater than or equal to 0 degree and less than or equal to 161.6 degrees, the normalized intra prediction mode angular range is satisfied, and the electronic device may perform further processing to simplify the flow of intra prediction mode determination.
S13, the electronic device calculates a target gradient of the target macroblock.
In at least one embodiment of the present invention, the electronic device calculating the target gradient of the target macroblock comprises:
and the electronic equipment determines the difference value between every two adjacent pixels in the target macro block and calculates the average value of all the difference values, and the electronic equipment determines the target gradient according to the average value.
Preferably, the gradient of the image function f (x, y) at the point (x, y) is a vector having a magnitude and a direction, set as GxAnd GyThe gradient in the x direction and the y direction is expressed sequentially, and the vector of the gradient can be expressed as:
Figure BDA0001823321070000101
the magnitude of this vector is:
Figure BDA0001823321070000102
the direction angle is:
Figure BDA0001823321070000103
for digital images, this is equivalent to graduating a two-dimensional discrete function, as follows:
Gx=f(x,y)-f(x-1,y) (4)
Gy=f(x,y)-f(x,y-1) (5)
the gradient direction is the direction in which the function f (x, y) changes most rapidly, when an edge exists in the image, a larger gradient value is certain, and conversely, when a smoother part exists in the image, the gray value change is smaller, and the corresponding gradient is also smaller.
For a two-dimensional digital image f (x, y), differentiation in both x and y directions needs to be performed, and the formula is as follows:
Figure BDA0001823321070000104
partial differential of the two directions x and y is respectively solved to finally obtain gradient
Figure BDA0001823321070000105
For discrete images, the mathematical expression of the first order differential corresponds to the difference between two adjacent pixels, and the effect may be different, but the basic principle is not changed, depending on the chosen gradient operator. The most common operator is the Roberts operator, other common operators also include Sobel, Prewitt, and others.
Taking the Roberts operator as an example, the gradient calculation results in the x and y directions are as follows:
Figure BDA0001823321070000111
the electronic device can determine the target gradient by covering the whole target macro block with the calculation mode.
S14, the electronic equipment calculates the target difference value of the target gradient and each target angle information.
In at least one embodiment of the present invention, the electronic device calculates a target difference value between the target gradient and each target angle information to determine a target intra prediction mode according to the target difference value, which will be described in the following steps.
S15, the electronic device determines M pending intra prediction modes from all the intra prediction modes according to the target difference.
In at least one embodiment of the present invention, the electronic device determining, according to the target difference value, M pending intra prediction modes from among the all intra prediction modes includes:
and the electronic equipment sorts the target difference values according to a configuration sequence, acquires (M-1) intra-frame prediction modes corresponding to the target difference values arranged at preset positions, and determines the (M-1) intra-frame prediction modes and the direct current coefficient DC intra-frame prediction mode as the M undetermined intra-frame prediction modes.
Preferably, the configuration sequence may be custom configured by the electronic device, for example, the configuration sequence may include, but is not limited to: the order from large to small, the order from small to large, etc.
Further, the preset positions will be different corresponding to different configuration modes of the configuration sequence.
For example: when the electronic equipment sorts the target difference values in descending order, the electronic equipment acquires (M-1) intra-frame prediction modes corresponding to the target difference values arranged at the back (M-1) position, and determines the (M-1) intra-frame prediction modes and the direct current coefficient DC intra-frame prediction mode as the M undetermined intra-frame prediction modes.
Or, when the electronic device sorts the target difference values in an order from small to large, the electronic device obtains (M-1) intra-frame prediction modes corresponding to the target difference values arranged at the front (M-1) positions, and determines the (M-1) intra-frame prediction modes and the direct current coefficient DC intra-frame prediction mode as the M pending intra-frame prediction modes.
In at least one embodiment of the present invention, since the h.264 intra prediction modes include 9 types, and 8 types are related to angle information, in the process of intra prediction mode determination, the DC intra prediction mode is needed to be traversed since it is not related to angle information, i.e. M is greater than 0 and M is less than 8.
According to the practical situation, the value of M can be configured in a self-defined manner, and in general, in order to ensure the accuracy and the high efficiency of the determination of the target intra-frame prediction mode, the value of M can be 3, so that the electronic device can determine the target intra-frame prediction mode in the intra-frame prediction mode closest to the target gradient, the intra-frame prediction time is saved, and the intra-frame prediction efficiency can be effectively improved.
And S16, the electronic equipment adopts the M undetermined intra-frame prediction modes to carry out prediction, and M cost values are obtained.
In at least one embodiment of the present invention, the electronic device performs prediction by using the M pending intra prediction modes to obtain M cost values.
Preferably, the cost value can indicate the goodness of intra-prediction.
Preferably, the electronic device performs prediction by using a standard algorithm of each intra-frame prediction mode, and since the standard algorithm of each intra-frame prediction mode is already a mature technology, the detailed description is omitted in this scheme.
S17, the electronic device determines a target intra-prediction mode of the target macroblock from the M pending intra-prediction modes according to the M cost values.
In at least one embodiment of the present invention, the electronic device determining, according to the M cost values, a target intra-prediction mode for the target macroblock from the M pending intra-prediction modes comprises:
and the electronic equipment acquires the minimum target cost value from the M cost values and determines the intra-frame prediction mode corresponding to the target cost value as the target intra-frame prediction mode.
Preferably, the higher the cost value is, the worse the effect of the corresponding intra prediction mode is, and the lower the cost value is, the better the effect of the corresponding intra prediction mode is.
Therefore, the electronic device determines the smallest cost value as the target cost value.
Further, the electronic device determines an intra-prediction mode corresponding to the target cost value as the target intra-prediction mode.
Through the implementation mode, the electronic equipment can determine the target intra-frame prediction mode of the target macro block from the M undetermined intra-frame prediction modes, so that the same prediction effect can be achieved without traversing all intra-frame prediction modes, the prediction efficiency is higher, the calculation amount of the electronic equipment is effectively saved, the operation effect of the electronic equipment is improved, and the user experience is better.
To sum up, in this embodiment, angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes is obtained, normalization processing is performed on the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode, so as to associate the intra-frame prediction modes with the angle information, determine a target macroblock in an intra-frame prediction region, eliminate interference of other macroblocks, avoid redundant calculation, purposefully determine, calculate a target gradient of the target macroblock, calculate a target difference between the target gradient and each target angle information, determine M undetermined intra-frame prediction modes from all intra-frame prediction modes according to the target difference, perform prediction by using the M undetermined intra-frame prediction modes to obtain M cost values, so that all intra-frame prediction modes do not need to be traversed, and the traversal efficiency is improved, and a target intra-frame prediction mode of the target macro block is determined from the M undetermined intra-frame prediction modes according to the M cost values, so that the target intra-frame prediction mode is determined quickly and accurately.
In this embodiment, the electronic device 1 may be a PC (Personal Computer), a smart phone, a tablet Computer, a palm Computer, a portable Computer, an intelligent router, an ore machine, and a network storage device terminal device.
The electronic device 1 may be a node constituting a content distribution network or a blockchain network.
The electronic device 1 may include a memory 12, a processor 13, and a bus 14.
The memory 12 includes at least one type of readable storage medium including a flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, and the like. The memory 12 may in some embodiments be an internal storage unit of the electronic device 1, for example a hard disk of the electronic device 1. The memory 12 may also be an external storage device of the electronic device 1 in other embodiments, such as a plug-in hard disk provided on the electronic device 1, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and so on. Further, the memory 12 may also include both an internal storage unit and an external storage device of the electronic device 1. The memory 12 may be used not only to store application software installed in the electronic apparatus 1 and various types of data, such as the code of the intra prediction mode determination program 01, but also to temporarily store data that has been output or is to be output.
The processor 13 may be a Central Processing Unit (CPU), controller, microcontroller, microprocessor or other data Processing chip in some embodiments, and is used for executing program codes stored in the memory 12 or Processing data, such as executing the intra prediction mode determining program 01.
The bus 14 may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one arrow is shown in FIG. 2, but this does not indicate only one bus or one type of bus.
Further, the electronic device may further include a network interface 15, and the network interface 15 may optionally include a wired interface and/or a wireless interface (such as a WI-FI interface, a bluetooth interface, etc.), which are generally used to establish a communication connection between the electronic device 1 and other electronic devices.
Optionally, the electronic device 1 may further comprise a user interface, the user interface may comprise a Display (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface may further comprise a standard wired interface, a wireless interface. Alternatively, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display, which may also be referred to as a display screen or display unit, is suitable for displaying information processed in the electronic device 1 and for displaying a visualized user interface, among other things.
Fig. 2 only shows the electronic device 1 with the components 12-13 and the intra prediction mode determination program 01, and it will be understood by those skilled in the art that the structure shown in fig. 1 does not constitute a limitation of the electronic device 1, and may comprise fewer or more components than shown, or may combine certain components, or a different arrangement of components.
Referring to fig. 3, a functional block diagram of the intra prediction mode determination procedure in fig. 2 is shown. The intra prediction mode determination program 11 includes an acquisition unit 110, a normalization unit 111, a determination unit 112, a calculation unit 113, and a prediction unit 114. The module/unit referred to in the present invention refers to a series of computer program segments that can be executed by the processor 13 and that can perform a fixed function, and that are stored in the memory 12. In the present embodiment, the functions of the modules/units will be described in detail in the following embodiments.
The acquisition unit 110 acquires angle information corresponding to each of all intra prediction modes.
In at least one embodiment of the present invention, h.264 is a highly compressed digital video codec standard proposed by the joint video team consisting of the video coding experts group and the moving picture experts group jointly, and has 9 intra prediction modes, i.e. all intra prediction modes include: DC (Direct coefficient) intra prediction mode, intra prediction mode 0 (vertical intra prediction mode), intra prediction mode 1 (horizontal intra prediction mode), intra prediction mode 3 (lower left diagonal intra prediction mode), intra prediction mode 4 (lower right diagonal intra prediction mode), intra prediction mode 5 (right vertical intra prediction mode), intra prediction mode 6 (lower horizontal intra prediction mode), intra prediction mode 7 (left vertical intra prediction mode), and intra prediction mode 8 (upper horizontal intra prediction mode).
Preferably, among all the intra prediction modes, other intra prediction modes except the DC intra prediction mode are related to the angle information.
Preferably, the angle information corresponding to the intra-frame prediction mode 0 is a vertical direction, the angle information corresponding to the intra-frame prediction mode 1 is a horizontal direction, the angle information corresponding to the intra-frame prediction mode 3 is a direction vertically deviated from the left 45 degrees, the angle information corresponding to the intra-frame prediction mode 4 is a direction vertically deviated from the right 45 degrees, the angle information corresponding to the intra-frame prediction mode 5 is a direction vertically deviated from the right 26.6 degrees, the angle information corresponding to the intra-frame prediction mode 6 is a direction horizontally deviated from the lower 26.6 degrees, the angle information corresponding to the intra-frame prediction mode 7 is a direction vertically deviated from the left 26.6 degrees, and the angle information corresponding to the intra-frame prediction mode 7 is a direction horizontally deviated from the upper 26.6 degrees.
The normalization unit 111 performs normalization processing on the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode.
In at least one embodiment of the present invention, in order to facilitate the subsequent matching of the angle information corresponding to each intra-prediction mode with the gradient, the normalization unit 111 performs normalization processing on the angle information corresponding to each intra-prediction mode, so as to compare the angle information corresponding to each intra-prediction mode with the gradient divided into the same dimension.
Preferably, M is greater than 0 and M is less than 8, and the normalizing unit 111 normalizes the angle information corresponding to each intra prediction mode, including:
the normalization unit 111 normalizes the angle information corresponding to each intra prediction mode with reference to the intra prediction mode 8 of h.264.
Furthermore, 8 intra-prediction modes in h.264 are angle-dependent, an angle range of 135 degrees +26.6 degrees to 161.6 degrees is formed from the intra-prediction mode 0 to the intra-prediction mode 8, and the normalization unit 111 normalizes the angle information corresponding to each intra-prediction mode with the intra-prediction mode 8 as a reference, including:
for the intra-frame prediction mode 8, the original angle information is 26.6 degrees above the horizontal, and the normalization unit 111 calculates that 26.6 degrees to 26.6 degrees are 0 degree, so as to obtain that the corresponding target angle information after normalization of the intra-frame prediction mode 8 is 0 degree;
for the intra-frame prediction mode 1, the original angle information is in the horizontal direction, and the normalization unit 111 calculates that 0 degree +26.6 degrees is 26.6 degrees, so as to obtain that the corresponding target angle information after normalization of the intra-frame prediction mode 1 is 26.6 degrees;
for the intra-frame prediction mode 6, the original angle information is 26.6 degrees below the horizontal, and the normalization unit 111 calculates that 26.6 degrees +26.6 degrees is 53.2 degrees, so as to obtain 53.2 degrees of corresponding target angle information after normalization of the intra-frame prediction mode 6;
for the intra-frame prediction mode 4, the original angle information is 45 degrees vertically deviated from the right, and the normalization unit 111 calculates that 45 degrees +26.6 degrees is 71.6 degrees, so as to obtain that the corresponding target angle information after normalization of the intra-frame prediction mode 4 is 71.6 degrees;
for the intra-frame prediction mode 5, the original angle information is 26.6 degrees vertically to the right, and the normalization unit 111 calculates that (45 degrees-26.6 degrees) +45 degrees +26.6 degrees is 90 degrees, so as to obtain that the corresponding target angle information after normalization of the intra-frame prediction mode 5 is 90 degrees;
for the intra-frame prediction mode 0, the original angle information is vertical, and the normalization unit 111 calculates 90 degrees +26.6 degrees to 116.6 degrees, so as to obtain that the corresponding target angle information after normalization of the intra-frame prediction mode 0 is 116.6 degrees;
for the intra-frame prediction mode 7, the original angle information is 26.6 degrees that is vertically deviated from left, and the normalization unit 111 calculates 116.6 degrees +26.6 degrees as 142.6 degrees, so as to obtain 142.6 degrees of corresponding target angle information after normalization of the intra-frame prediction mode 7;
for the intra-frame prediction mode 3, the original angle information is vertically deviated from the left by 45 degrees, and the normalization unit 111 calculates 116.6 degrees +45 degrees to 161.6 degrees, so as to obtain 161.6 degrees of target angle information corresponding to the normalized intra-frame prediction mode 3.
The determination unit 112 determines a target macroblock within the intra prediction area.
In at least one embodiment of the present invention, the determining unit 112 determines the target macroblock within the intra prediction region includes:
the determining unit 112 obtains all macroblocks in the intra-frame prediction region, calculates a gradient of each macroblock in all macroblocks, and when the gradient of a macroblock is greater than or equal to 0 degree and less than or equal to a preset value, the determining unit 112 determines that the macroblock is valid, and the determining unit 112 determines the valid macroblock as the target macroblock.
For example: the preset value may include, but is not limited to, 161.6 degrees.
It can be understood that, since the normalized intra prediction mode angle forms an angle range of 161.6 degrees, and the gradient of each macroblock and the angle information corresponding to the intra prediction mode are in one dimension, the determining unit 112 will perform intra prediction using a conventional intra prediction algorithm for macroblocks with gradients outside the angle range of (0-161.6 degrees).
Preferably, for the macro block with the gradient greater than or equal to 0 degree and less than or equal to 161.6 degrees, the normalized intra prediction mode angular range is satisfied, and the electronic device may perform further processing to simplify the flow of intra prediction mode determination.
The calculation unit 113 calculates a target gradient of the target macroblock.
In at least one embodiment of the present invention, the calculating unit 113 calculates the target gradient of the target macroblock includes:
the calculating unit 113 determines a difference value between every two adjacent pixels in the target macroblock, and calculates an average value of all the difference values, and the calculating unit 113 determines the target gradient according to the average value.
Preferably, the gradient of the image function f (x, y) at the point (x, y) is a vector having a magnitude and a direction, set as GxAnd GyThe gradient in the x direction and the y direction is expressed sequentially, and the vector of the gradient can be expressed as:
Figure BDA0001823321070000181
the magnitude of this vector is:
Figure BDA0001823321070000182
the direction angle is:
Figure BDA0001823321070000183
for digital images, this is equivalent to graduating a two-dimensional discrete function, as follows:
Gx=f(x,y)-f(x-1,y) (4)
Gy=f(x,y)-f(x,y-1) (5)
the gradient direction is the direction in which the function f (x, y) changes most rapidly, when an edge exists in the image, a larger gradient value is certain, and conversely, when a smoother part exists in the image, the gray value change is smaller, and the corresponding gradient is also smaller.
For a two-dimensional digital image f (x, y), differentiation in both x and y directions needs to be performed, and the formula is as follows:
Figure BDA0001823321070000191
partial differential of the two directions x and y is respectively solved to finally obtain gradient
Figure BDA0001823321070000192
For discrete images, the mathematical expression of the first order differential corresponds to the difference between two adjacent pixels, and the effect may be different, but the basic principle is not changed, depending on the chosen gradient operator. The most common operator is the Roberts operator, other common operators also include Sobel, Prewitt, and others.
Taking the Roberts operator as an example, the gradient calculation results in the x and y directions are as follows:
Figure BDA0001823321070000193
by covering the entire target macroblock with the above calculation method, the calculation unit 113 can determine the target gradient.
The calculation unit 113 calculates a target difference value of the target gradient and each kind of target angle information.
In at least one embodiment of the present invention, the calculating unit 113 calculates a target difference value between the target gradient and each target angle information, so as to determine a target intra prediction mode according to the target difference value, which will be described in the following steps.
The determining unit 112 determines M pending intra prediction modes from the all intra prediction modes according to the target difference.
In at least one embodiment of the present invention, the determining unit 112 determines M pending intra prediction modes from the all intra prediction modes according to the target difference value, including:
the determining unit 112 sorts the target difference values according to a configuration order, and the determining unit 112 obtains (M-1) intra-frame prediction modes corresponding to the target difference values arranged at preset positions, and determines the (M-1) intra-frame prediction modes and the DC intra-frame prediction mode as the M pending intra-frame prediction modes.
Preferably, the configuration sequence may be custom configured by the electronic device, for example, the configuration sequence may include, but is not limited to: the order from large to small, the order from small to large, etc.
Further, the preset positions will be different corresponding to different configuration modes of the configuration sequence.
For example: when the determining unit 112 sorts the target difference values in descending order, the determining unit 112 obtains (M-1) intra-frame prediction modes corresponding to the target difference value arranged at the next (M-1) position, and determines the (M-1) intra-frame prediction modes and the DC intra-frame prediction mode as the M pending intra-frame prediction modes.
Or, when the determining unit 112 sorts the target difference values in an order from small to large, the determining unit 112 obtains (M-1) intra-frame prediction modes corresponding to the target difference value ranked at the top (M-1) position, and determines the (M-1) intra-frame prediction modes and the DC intra-frame prediction mode as the M pending intra-frame prediction modes.
In at least one embodiment of the present invention, since the h.264 intra prediction modes include 9 types, and 8 types are related to angle information, in the process of intra prediction mode determination, the DC intra prediction mode is needed to be traversed since it is not related to angle information, i.e. M is greater than 0 and M is less than 8.
According to an actual situation, the value of M may be configured by a user-defined method, and in general, in order to ensure the accuracy and efficiency of determining the target intra-frame prediction mode, the value of M may be 3, so that the determining unit 112 may determine the target intra-frame prediction mode in the intra-frame prediction mode closest to the target gradient, which not only saves intra-frame prediction time, but also can effectively improve intra-frame prediction efficiency.
The prediction unit 114 performs prediction by using the M pending intra prediction modes to obtain M cost values.
In at least one embodiment of the present invention, the prediction unit 114 performs prediction by using the M pending intra prediction modes to obtain M cost values.
Preferably, the cost value can indicate the goodness of intra-prediction.
Preferably, the prediction unit 114 performs prediction by using a standard algorithm of each intra-frame prediction mode, and since the standard algorithm of each intra-frame prediction mode is already a mature technology, the detailed description of the present solution will not be repeated.
The determining unit 112 determines a target intra prediction mode of the target macroblock from the M pending intra prediction modes according to the M cost values.
In at least one embodiment of the present invention, the determining unit 112 determines the target intra prediction mode of the target macroblock from the M pending intra prediction modes according to the M cost values by:
the determining unit 112 obtains a minimum target cost value from the M cost values, and determines an intra prediction mode corresponding to the target cost value as the target intra prediction mode.
Preferably, the higher the cost value is, the worse the effect of the corresponding intra prediction mode is, and the lower the cost value is, the better the effect of the corresponding intra prediction mode is.
Therefore, the determining unit 112 determines the smallest cost value as the target cost value.
Further, the determining unit 112 determines the intra-prediction mode corresponding to the target cost value as the target intra-prediction mode.
Through the above embodiment, the determining unit 112 may determine the target intra-frame prediction mode of the target macroblock from the M pending intra-frame prediction modes, so that the same prediction effect can be achieved without traversing all intra-frame prediction modes, the prediction efficiency is higher, the calculation amount of the electronic device is effectively saved, the operation effect of the electronic device is improved, and the user experience is better.
To sum up, in this embodiment, angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes is obtained, normalization processing is performed on the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode, so as to associate the intra-frame prediction modes with the angle information, determine a target macroblock in an intra-frame prediction region, eliminate interference of other macroblocks, avoid redundant calculation, purposefully determine, calculate a target gradient of the target macroblock, calculate a target difference between the target gradient and each target angle information, determine M undetermined intra-frame prediction modes from all intra-frame prediction modes according to the target difference, perform prediction by using the M undetermined intra-frame prediction modes to obtain M cost values, so that all intra-frame prediction modes do not need to be traversed, and the traversal efficiency is improved, and a target intra-frame prediction mode of the target macro block is determined from the M undetermined intra-frame prediction modes according to the M cost values, so that the target intra-frame prediction mode is determined quickly and accurately.
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 a computer can store or a data storage device, such as a server, a data center, etc., that is integrated with one or more 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 clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It should be noted that the above-mentioned numbers of the embodiments of the present invention are merely for description, and do not represent the merits of the embodiments. And the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, apparatus, article, or method 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, apparatus, article, or method. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, apparatus, article, or method that includes the element.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (10)

1. A method for intra prediction mode determination, the method comprising:
acquiring angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes;
normalizing the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode;
determining a target macroblock within an intra-predicted region, comprising: acquiring all macro blocks in the intra-frame prediction area, calculating the gradient of each macro block in all the macro blocks, determining that the macro block is effective when the gradient of the macro block is greater than or equal to 0 degree and less than or equal to a preset value, and determining the effective macro block as the target macro block;
calculating a gradient angle value of the target macro block as a target gradient;
calculating a target difference value between the target gradient and each target angle information;
determining M undetermined intra-frame prediction modes from all the intra-frame prediction modes according to the target difference value;
predicting by adopting the M undetermined intra-frame prediction modes to obtain M cost values;
determining a target intra-prediction mode for the target macroblock from the M pending intra-prediction modes according to the M cost values.
2. The method of claim 1, wherein M is greater than 0 and less than 8, and wherein normalizing the angle information for each intra-prediction mode comprises:
the angle information corresponding to each intra prediction mode is normalized with reference to the intra prediction mode 8 of h.264.
3. The method of claim 1, wherein the determining the target macroblock within the intra-predicted region comprises:
acquiring all macro blocks in an intra-frame prediction area;
calculating the gradient of each macro block in all the macro blocks;
when the gradient of a macro block is greater than or equal to 0 degree and less than or equal to a preset value, determining that the macro block is effective;
determining a valid macroblock as the target macroblock.
4. The method of claim 1, wherein the calculating the target gradient of the target macroblock comprises:
determining the difference value between every two adjacent pixels in the target macro block;
calculating the average value of all the difference values;
determining the target gradient from the average.
5. The method of claim 1, wherein the determining M pending intra prediction modes from the all intra prediction modes based on the difference value comprises:
sequencing the target difference values according to a configuration sequence;
acquiring (M-1) intra-frame prediction modes corresponding to target difference values arranged at preset positions;
determining the (M-1) intra-frame prediction modes and the direct current coefficient DC intra-frame prediction mode as the M pending intra-frame prediction modes.
6. The method of claim 1, wherein the determining the target intra-prediction mode for the target macroblock from the M pending intra-prediction modes according to the M cost values comprises:
obtaining a minimum target cost value from the M cost values;
and determining the intra-frame prediction mode corresponding to the target cost value as the target intra-frame prediction mode.
7. An electronic device, comprising a memory and a processor, the memory having stored thereon an intra-prediction mode determination program executable on the processor, the intra-prediction mode determination program when executed by the processor implementing the method of any of claims 1-6.
8. The electronic device of claim 7, wherein the electronic device is a node that constitutes a content distribution network or a blockchain network.
9. An intra prediction mode determination system, the system comprising:
the device comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring angle information corresponding to each intra-frame prediction mode in all intra-frame prediction modes;
the normalization unit is used for performing normalization processing on the angle information corresponding to each intra-frame prediction mode to obtain target angle information corresponding to each intra-frame prediction mode;
a determining unit, configured to determine a target macroblock within an intra-predicted region, including: acquiring all macro blocks in the intra-frame prediction area, calculating the gradient of each macro block in all the macro blocks, determining that the macro block is effective when the gradient of the macro block is greater than or equal to 0 degree and less than or equal to a preset value, and determining the effective macro block as the target macro block;
the calculating unit is used for calculating the gradient angle value of the target macro block as a target gradient;
the calculation unit is further used for calculating a target difference value between the target gradient and each kind of target angle information;
the determining unit is further configured to determine M pending intra prediction modes from the all intra prediction modes according to the target difference;
the prediction unit is used for predicting by adopting the M undetermined intra-frame prediction modes to obtain M cost values;
the determining unit is further configured to determine a target intra-prediction mode of the target macroblock from the M pending intra-prediction modes according to the M cost values.
10. A computer-readable storage medium having stored thereon an intra-prediction mode determination program executable by one or more processors to implement the intra-prediction mode determination method of any one of claims 1 to 6.
CN201811174297.8A 2018-10-09 2018-10-09 Intra-frame prediction mode determination method, electronic device, system and storage medium Active CN109462758B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811174297.8A CN109462758B (en) 2018-10-09 2018-10-09 Intra-frame prediction mode determination method, electronic device, system and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811174297.8A CN109462758B (en) 2018-10-09 2018-10-09 Intra-frame prediction mode determination method, electronic device, system and storage medium

Publications (2)

Publication Number Publication Date
CN109462758A CN109462758A (en) 2019-03-12
CN109462758B true CN109462758B (en) 2021-04-06

Family

ID=65607419

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811174297.8A Active CN109462758B (en) 2018-10-09 2018-10-09 Intra-frame prediction mode determination method, electronic device, system and storage medium

Country Status (1)

Country Link
CN (1) CN109462758B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109982075B (en) * 2019-03-21 2022-11-08 南京威翔科技有限公司 Intra-frame prediction universal angle method based on FPGA
CN112087634B (en) * 2020-08-11 2022-03-08 北京博雅慧视智能技术研究院有限公司 Optimal angle judgment method and system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102724509A (en) * 2012-06-19 2012-10-10 清华大学 Method and device for selecting optimal intra-frame coding mode for video sequence
CN103517069A (en) * 2013-09-25 2014-01-15 北京航空航天大学 HEVC intra-frame prediction quick mode selection method based on texture analysis
CN104054343A (en) * 2012-01-13 2014-09-17 夏普株式会社 Image decoding device, image encoding device, and data structure of encoded data
EP2723082A3 (en) * 2012-10-16 2014-10-22 Canon Kabushiki Kaisha Image encoding apparatus and image encoding method
JP5887012B2 (en) * 2015-09-11 2016-03-16 日立マクセル株式会社 Image decoding method
CN107509076A (en) * 2017-08-25 2017-12-22 中国软件与技术服务股份有限公司 A kind of Encoding Optimization towards ultra high-definition video

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104284186A (en) * 2014-09-24 2015-01-14 复旦大学 Fast algorithm suitable for HEVC standard intra-frame prediction mode judgment process
US10841581B2 (en) * 2016-07-14 2020-11-17 Arris Enterprises Llc Region specific encoding and SAO-sensitive-slice-width-adaptation for improved-quality HEVC encoding

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104054343A (en) * 2012-01-13 2014-09-17 夏普株式会社 Image decoding device, image encoding device, and data structure of encoded data
CN102724509A (en) * 2012-06-19 2012-10-10 清华大学 Method and device for selecting optimal intra-frame coding mode for video sequence
EP2723082A3 (en) * 2012-10-16 2014-10-22 Canon Kabushiki Kaisha Image encoding apparatus and image encoding method
CN103517069A (en) * 2013-09-25 2014-01-15 北京航空航天大学 HEVC intra-frame prediction quick mode selection method based on texture analysis
JP5887012B2 (en) * 2015-09-11 2016-03-16 日立マクセル株式会社 Image decoding method
CN107509076A (en) * 2017-08-25 2017-12-22 中国软件与技术服务股份有限公司 A kind of Encoding Optimization towards ultra high-definition video

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
HEVC快速帧内模式和深度决策算法;伍冠健,宋立锋;《广州工业大学学报》;20151115;全文 *

Also Published As

Publication number Publication date
CN109462758A (en) 2019-03-12

Similar Documents

Publication Publication Date Title
CN109462758B (en) Intra-frame prediction mode determination method, electronic device, system and storage medium
JP6697582B2 (en) Intra-predictive video coding method and apparatus
CN107396112B (en) Encoding method and device, computer device and readable storage medium
CN107483953B (en) Inter frame motion estimation method, apparatus and electronic equipment
CN104363450A (en) Intra-frame coding mode decision-making method and device
CN110020093A (en) Video retrieval method, edge device, video frequency searching device and storage medium
CN106845338B (en) Pedestrian detection method and system in video stream
CN110298858A (en) A kind of image cropping method and device
CN109495742B (en) Video frame coding method, device and equipment
CN111614959B (en) Video coding method and device and electronic equipment
CN104866194B (en) Image searching method and device
CN109640087A (en) A kind of intra prediction mode decision method, device and equipment
CN104978731A (en) Information processing method and electronic equipment
CN108765503B (en) Skin color detection method, device and terminal
CN109685015A (en) Processing method, device, electronic equipment and the computer storage medium of image
WO2023005421A1 (en) Work cover display method, device, medium and electronic apparatus
JP2014099848A (en) Image division system and image division method
CN110708505B (en) Video alarm method, device, electronic equipment and computer readable storage medium
EP2367357A2 (en) Adaptive search area in motion estimation processes
CN109640098A (en) A kind of intra-frame prediction method based on AVS2, system and electronic equipment and storage medium
Yao et al. A fast DEA-based intra-coding algorithm for HEVC
TWI754496B (en) Image fusion method, device, electronic equipment and storage medium
CN110248194B (en) Intra-frame angle prediction method and device
CN113099231B (en) Method and device for determining sub-pixel interpolation position, electronic equipment and storage medium
CN108632622B (en) Intra-frame prediction method and device and electronic equipment

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