Image coding method and device, electronic equipment and computer medium

By using the video merger and encoding mode and the advanced motion vector prediction mode in the image coding, the problem of predictive deviation of complex scenes and fast motion motion vector predictive deviations is solved, which significantly improves coding efficiency and accuracy.

CN119383338APending Publication Date: 2025-01-28BEIJING VIMICRO ARTIFICIAL INTELLIGENCE CHIP TECH CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411498366.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-25
Publication Date
2025-01-28

AI Technical Summary

Technical Problem

In complex scenes or fast motion, the prediction of the motion vector will be biased, resulting in a decrease in image encoding efficiency.

Method used

By selecting the video merger and video merger coding price estimation value by selecting inter -frame images in the video combined coding mode, the output frame image is in the high -end sports vector prediction mode, the cost estimation value, sports vector prediction value and sports vector under the predictive prediction mode of the high -end sports vector , And determine the target coding mode based on these values, and finally output code type information.

Benefits of technology

Reduce the deviation of the motion vector prediction, improve the accuracy and efficiency of coding, reduce the complexity and calculation of the encoding process, and achieve more efficient coding selection and overall coding performance improvement.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119383338A_ABST
    Figure CN119383338A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses an image coding method and device, electronic equipment and a computer medium. A specific embodiment of the method comprises the following steps: selecting a video merging index and a video merging coding cost estimation value of an inter-frame image in a video merging coding mode; based on the video merging index, outputting an advanced motion vector coding cost estimation value, a motion vector prediction value and a motion vector when the inter-frame image is in an advanced motion vector prediction mode; determining a target coding mode based on the advanced motion vector coding cost estimation value and the video merge coding cost estimation value; and outputting coded codeword information based on the target coding mode. According to the embodiment, the coding efficiency can be remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present disclosure relate to the field of image coding, and in particular to an image coding method, device, electronic device and computer medium. Background Art

[0002] As video content becomes increasingly rich and viewing needs become more diverse, video coding technology is also constantly improving. At present, when encoding images, the commonly used method is to improve coding efficiency through motion compensation and predictive coding. Specifically, the video encoder analyzes the motion information between video frames and uses the motion vectors of existing frames to predict the current frame, thereby reducing the data information that needs to be transmitted.

[0003] However, it is found in practice that when the above-mentioned image encoding method is used, the following technical problems often occur:

[0004] In complex scenes or fast motion situations, the prediction of motion vectors may be biased, resulting in reduced coding efficiency.

[0005] The above information disclosed in this Background section is only for enhancement of understanding of the background of the inventive concept and therefore it may contain information that does not form the prior art that is already known in this country to a person of ordinary skill in the art. Summary of the invention

[0006] The content of this disclosure is used to introduce concepts in a brief form, which will be described in detail in the detailed implementation section below. The content of this disclosure is not intended to identify the key features or essential features of the technical solution claimed for protection, nor is it intended to limit the scope of the technical solution claimed for protection.

[0007] Some embodiments of the present disclosure propose image encoding methods, devices, electronic devices, and computer-readable media to solve one or more of the technical problems mentioned in the above background technology section.

[0008] In the first aspect, some embodiments of the present disclosure provide an image encoding method, which includes: selecting a video merge index and a video merge encoding cost estimate when an inter-frame image is in a video merge encoding mode; based on the above video merge index, outputting an advanced motion vector encoding cost estimate, a motion vector prediction value and a motion vector when the inter-frame image is in an advanced motion vector prediction mode; based on the above advanced motion vector encoding cost estimate and the above video merge encoding cost estimate, determining a target encoding mode; based on the above target encoding mode, outputting encoding codeword information.

[0009] In a second aspect, some embodiments of the present disclosure provide an image encoding device, which includes: a selection unit, configured to select a video merge index and a video merge encoding cost estimate when an inter-frame image is in a video merge encoding mode; a first output unit, configured to output an advanced motion vector encoding cost estimate, a motion vector prediction value and a motion vector when the inter-frame image is in an advanced motion vector prediction mode based on the above-mentioned video merge index; a determination unit, configured to determine a target encoding mode based on the above-mentioned advanced motion vector encoding cost estimate and the above-mentioned video merge encoding cost estimate; and a second output unit, configured to output encoding codeword information based on the above-mentioned target encoding mode.

[0010] In a third aspect, some embodiments of the present disclosure provide an electronic device comprising: one or more processors; a storage device on which one or more programs are stored, and when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any implementation manner of the above-mentioned first aspect.

[0011] In a fourth aspect, some embodiments of the present disclosure provide a computer-readable medium having a computer program stored thereon, wherein when the program is executed by a processor, the method described in any implementation manner of the above-mentioned first aspect is implemented.

[0012] The above-mentioned embodiments of the present disclosure have the following beneficial effects: through the image coding method of some embodiments of the present application, the coding efficiency can be significantly improved. Specifically, the reason for the reduction in coding efficiency is that in the case of complex scenes or fast motion, the prediction of the motion vector will be biased. Based on this, the image coding method of some embodiments of the present application first selects the video merge index and the video merge coding cost estimation value of the inter-frame image in the video merge coding mode. In this way, the deviation of the motion vector prediction can be reduced and the accuracy of coding can be improved. Secondly, based on the above-mentioned video merge index, the advanced motion vector coding cost estimation value, the motion vector prediction value and the motion vector of the inter-frame image in the advanced motion vector prediction mode are output. In this way, the prediction of the motion vector can be further optimized and the complexity and calculation amount in the coding process can be reduced. Then, based on the above-mentioned advanced motion vector coding cost estimation value and the above-mentioned video merge coding cost estimation value, the target coding mode is determined. In this way, more efficient coding selection can be achieved and the overall coding performance can be improved. Finally, based on the above-mentioned target coding mode, the coding codeword information is output. In this way, by accurately matching the motion characteristics and scene complexity of the video content, the coding efficiency can be significantly improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar figure labels represent the same or similar elements. It should be understood that the drawings are schematic and that the components and elements are not necessarily drawn to scale.

[0014] Figure 1 is a flowchart of some embodiments of the image encoding method according to the present disclosure;

[0015] Figure 2 is a flowchart of some embodiments of the image encoding device according to the present disclosure;

[0016] Figure 3 It is a schematic diagram of the structure of an electronic device suitable for implementing some embodiments of the present disclosure. DETAILED DESCRIPTION

[0017] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments set forth herein. On the contrary, these embodiments are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.

[0018] It should also be noted that, for ease of description, only the parts related to the invention are shown in the drawings. In the absence of conflict, the embodiments and features in the embodiments of the present disclosure can be combined with each other.

[0019] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.

[0020] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".

[0021] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.

[0022] The present disclosure will be described in detail below with reference to the accompanying drawings and in conjunction with embodiments.

[0023] Figure 11 is a flowchart of some embodiments of the image encoding method according to the present disclosure. 100 of some embodiments of the image encoding method according to the present disclosure is shown. The image encoding method, applied to an intelligent robot, comprises the following steps:

[0024] Step 101 , selecting a video merging index and a video merging coding cost estimation value of an inter-frame image in a video merging coding mode.

[0025] In some embodiments, the execution subject (e.g., computing device) of the image encoding method may select a video merge index and a video merge encoding cost estimate value of an inter-frame image in a video merge encoding mode by using a preset motion compensation algorithm. The video merge index may be: an index value for identifying a video merge encoding mode. For example, the preset motion compensation algorithm may be: a block matching algorithm. The video merge encoding mode may be: a Merge mode. The video merge encoding cost estimate value may be: a rate-distortion cost estimate value.

[0026] It should be noted that the above-mentioned wireless connection methods may include but are not limited to 3G / 4G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (ultra wideband) connection, and other wireless connection methods currently known or to be developed in the future.

[0027] Step 102: Based on the video merge index, output the advanced motion vector coding cost estimation value, motion vector prediction value and motion vector of the inter-frame image in the advanced motion vector prediction mode.

[0028] In some embodiments, the above-mentioned execution entity can output the advanced motion vector coding cost estimate, motion vector prediction value and motion vector of the inter-frame image in the advanced motion vector prediction mode based on the above-mentioned video merge index. For example, the advanced motion vector prediction mode can be: AMVP mode. The advanced motion vector coding cost estimate can be: MVA_COST (Motion Vector Activity Cost). The motion vector prediction value can be represented by but not limited to: AMVP_MVP (Advanced Motion Vector Prediction Most Valuable Predictor), MERGE_MVP (Merge Mode Most Valuable Predictor). The motion vector can be represented by but not limited to: MVA (Motion Vector Activity), MVB (Motion Vector Base).

[0029] In practice, the above execution subject can output the advanced motion vector coding cost estimation value, motion vector prediction value and motion vector of the inter-frame image in the advanced motion vector prediction mode through the following steps:

[0030] The first step is to obtain the advanced motion vector prediction value of the inter-frame image in the advanced motion vector prediction mode.

[0031] In practice, the above-mentioned execution subject can obtain the advanced motion vector prediction value of the inter-frame image in the advanced motion vector prediction mode through a wired connection or a wireless connection. For example, the advanced motion vector prediction value can be: AMVP_MVP (Advanced Motion Vector Prediction Most Valuable Predictor).

[0032] In the second step, motion estimation is performed on the above-mentioned high-level motion vector prediction value to generate a first motion vector and a first high-level motion vector encoding cost estimation value.

[0033] In practice, the execution subject may perform motion estimation processing on the advanced motion vector prediction value by a preset motion estimation algorithm to generate a first motion vector and a first advanced motion vector encoding cost estimate. For example, the preset motion estimation algorithm may be a test zone search (TZSearch) algorithm. The first motion vector may be MVA (Motion Vector Activity). The first advanced motion vector encoding cost estimate may be MVA_COS (Motion Vector Activity Cost).

[0034] The third step is to determine the merge index motion vector prediction value of the above video merge index.

[0035] In practice, the execution subject may determine the merge index motion vector prediction value of the video merge index. For example, the merge index motion vector prediction value may be: MERGE_MVP (Merge Mode Motion Vector Predictor).

[0036] The fourth step is to perform motion estimation processing on the merged index motion vector prediction value to generate a second motion vector and a second high-level motion vector encoding cost estimation value.

[0037] In practice, the execution subject may perform motion estimation processing on the merged index motion vector prediction value by a preset motion estimation algorithm to generate a second motion vector and a second high-level motion vector encoding cost estimate. For example, the second motion vector may be: MVB (Motion Vector Base). The second high-level motion vector encoding cost estimate may be: MVB_COST (Motion Vector Base COST).

[0038] In the fifth step, in response to determining that the first high-level motion vector coding cost estimate is less than the second high-level motion vector coding cost estimate, the first high-level motion vector coding cost estimate is determined as the high-level motion vector coding cost estimate in the high-level motion vector prediction mode.

[0039] In practice, in response to determining that the first high-level motion vector encoding cost estimate is less than the second high-level motion vector encoding cost estimate, the execution entity may determine the first high-level motion vector encoding cost estimate as the high-level motion vector encoding cost estimate in the high-level motion vector prediction mode.

[0040] Optionally, in response to determining that the second high-level motion vector encoding cost estimate is less than the first high-level motion vector encoding cost estimate, the second high-level motion vector encoding cost estimate is determined as the high-level motion vector encoding cost estimate in the high-level motion vector prediction mode.

[0041] In some embodiments, in response to determining that the second high-level motion vector encoding cost estimate is less than the first high-level motion vector encoding cost estimate, the execution entity may determine the second high-level motion vector encoding cost estimate as the high-level motion vector encoding cost estimate under the high-level motion vector prediction mode.

[0042] Step 103: Determine a target coding mode based on the high-level motion vector coding cost estimate and the video merge coding cost estimate.

[0043] In some embodiments, the execution subject may determine a target coding mode based on the advanced motion vector coding cost estimate and the video merge coding cost estimate, wherein the target coding mode may be represented by but not limited to: video merge coding mode, advanced motion vector prediction mode.

[0044] In practice, the execution subject may determine the target coding mode based on the high-level motion vector coding cost estimate and the video merge coding cost estimate by the following steps:

[0045] In the first step, in response to determining that the video merge coding cost estimate value is less than the advanced motion vector coding cost estimate value, the video merge coding mode is determined as the target coding mode.

[0046] In practice, in response to determining that the video merge coding cost estimate is less than the advanced motion vector coding cost estimate, the execution entity may determine the video merge coding mode as the target coding mode.

[0047] Optionally, in response to determining that the advanced motion vector coding cost estimate value is less than the video merge coding cost estimate value, the advanced motion vector prediction mode is determined as the target coding mode.

[0048] In some embodiments, in response to determining that the advanced motion vector coding cost estimate value is less than the video merge coding cost estimate value, the execution entity may determine the advanced motion vector prediction mode as the target coding mode.

[0049] Step 104: output the encoding codeword information based on the above target encoding mode.

[0050] In some embodiments, based on the target encoding mode, the execution subject may output encoding codeword information, wherein the encoding codeword information may represent but is not limited to: video merge index, mode flag 1, motion vector residual.

[0051] In practice, the execution subject may output the encoding codeword information based on the target encoding mode through the following steps:

[0052] The first step is to output a video merging index in response to determining that the target encoding mode is the video merging encoding mode.

[0053] In practice, in response to determining that the target encoding mode is the video merge encoding mode, the execution entity may output a video merge index.

[0054] Optionally, in response to determining that the target coding mode is the advanced motion vector prediction mode, and the motion vector prediction value is the advanced motion vector prediction value, the output mode flag is 0, and the motion vector residual.

[0055] In some embodiments, in response to determining that the target coding mode is the advanced motion vector prediction mode, and the motion vector prediction value is the advanced motion vector prediction value, the execution subject may output a mode flag of 0 and a motion vector residual. The motion vector residual may be: the difference between the motion vector prediction value and the motion vector. For example, the advanced motion vector prediction value may be: AMVP MVP (Advanced Motion Vector Prediction Most Valuable Predictor). The mode flag of 0 may be: mode_flag = 0. The motion vector residual may be: motion compensation residual.

[0056] Optionally, in response to determining that the target coding mode is the advanced motion vector prediction mode, and the motion vector prediction value is the merge index motion vector prediction value, the output mode flag is 1, the video merge index, and the motion vector residual.

[0057] In some embodiments, in response to determining that the target coding mode is the advanced motion vector prediction mode, and the motion vector prediction value is the merge index motion vector prediction value, the execution subject may output a mode flag of 1, a video merge index, and a motion vector residual. For example, the mode flag of 1 may be: mode_flag=1.

[0058] The above-mentioned embodiments of the present application have the following beneficial effects: the image coding method of some embodiments of the present application can significantly improve the coding efficiency. Specifically, the reason for the reduction in coding efficiency is that in the case of complex scenes or fast motion, the prediction of the motion vector will be biased. Based on this, the image coding method of some embodiments of the present application first selects the video merge index and the video merge coding cost estimation value of the inter-frame image in the video merge coding mode. In this way, the deviation of the motion vector prediction can be reduced and the accuracy of coding can be improved. Secondly, based on the above-mentioned video merge index, the advanced motion vector coding cost estimation value, the motion vector prediction value and the motion vector of the inter-frame image in the advanced motion vector prediction mode are output. In this way, the prediction of the motion vector can be further optimized and the complexity and calculation amount in the coding process can be reduced. Then, based on the above-mentioned advanced motion vector coding cost estimation value and the above-mentioned video merge coding cost estimation value, the target coding mode is determined. In this way, more efficient coding selection can be achieved and the overall coding performance can be improved. Finally, based on the above-mentioned target coding mode, the coding codeword information is output. In this way, by accurately matching the motion characteristics and scene complexity of the video content, the coding efficiency can be significantly improved.

[0059] Further references Figure 2As an implementation of the methods shown in the above figures, the present disclosure provides some embodiments of an image encoding device, and these image encoding device embodiments are Figure 1 Corresponding to the method embodiments shown, the image encoding device can be specifically applied to various electronic devices.

[0060] like Figure 2 As shown, the image encoding device 200 of some embodiments includes: a selection unit 201, a first output unit 202, a determination unit 203 and a second output unit 204. The selection unit 201 is configured to select a video merge index and a video merge coding cost estimation value when the inter-frame image is in the video merge coding mode; the first output unit 202 is configured to output the advanced motion vector coding cost estimation value, the motion vector prediction value and the motion vector when the inter-frame image is in the advanced motion vector prediction mode based on the video merge index; the determination unit 203 is configured to determine the target coding mode based on the advanced motion vector coding cost estimation value and the video merge coding cost estimation value; the second output unit 204 is configured to output the coding codeword information based on the target coding mode.

[0061] It can be understood that the units described in the image encoding device 200 are similar to those described in the reference Figure 1 Therefore, the operations, features and beneficial effects described above for the method are also applicable to the image encoding device 200 and the units included therein, and will not be described in detail here.

[0062] Reference below Figure 3 , which shows a schematic diagram of the structure of an electronic device (e.g., a computing device) 300 suitable for implementing some embodiments of the present disclosure. The electronic devices in some embodiments of the present disclosure may include, but are not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle-mounted terminals (e.g., vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 3 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.

[0063] like Figure 3As shown, the electronic device 300 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 301, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 302 or a program loaded from a storage device 308 into a random access memory (RAM) 303. In the RAM 303, various programs and data required for the operation of the electronic device 300 are also stored. The processing device 301, the ROM 302, and the RAM 303 are connected to each other via a bus 304. An input / output (I / O) interface 305 is also connected to the bus 304.

[0064] Typically, the following devices may be connected to the I / O interface 305: input devices 306 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; output devices 307 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices 308 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 309. The communication devices 309 may allow the electronic device 300 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 3 The electronic device 300 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead. Figure 3 Each block shown in the figure may represent one device, or may represent multiple devices as required.

[0065] In particular, according to some embodiments of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, some embodiments of the present disclosure include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In some such embodiments, the computer program can be downloaded and installed from the network through the communication device 309, or installed from the storage device 308, or installed from the ROM 302. When the computer program is executed by the processing device 301, the above-mentioned functions defined in the method of some embodiments of the present disclosure are executed.

[0066] It should be noted that the computer-readable medium recorded in some embodiments of the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In some embodiments of the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In some embodiments of the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0067] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.

[0068] The computer-readable medium may be included in the electronic device; or it may exist independently without being installed in the electronic device. The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: selects a video merge index and a video merge coding cost estimate when the inter-frame image is in the video merge coding mode; based on the video merge index, outputs an advanced motion vector coding cost estimate, a motion vector prediction value, and a motion vector when the inter-frame image is in the advanced motion vector prediction mode; determines a target coding mode based on the advanced motion vector coding cost estimate and the video merge coding cost estimate; and outputs coding codeword information based on the target coding mode.

[0069] Computer program code for performing the operations of some embodiments of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0070] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0071] The units described in some embodiments of the present disclosure may be implemented by software or by hardware. The described units may also be provided in a processor, for example, may be described as: a processor comprising: a selection unit, a first output unit, a determination unit, and a second output unit. The names of these units do not constitute limitations on the units themselves in certain circumstances, for example, the selection unit may also be described as a "unit for selecting a video merge index and a video merge coding cost estimate for an inter-frame image in a video merge coding mode".

[0072] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.

[0073] The above descriptions are only some preferred embodiments of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the embodiments of the present disclosure is not limited to the technical solutions formed by a specific combination of the above-mentioned technical features, but should also cover other technical solutions formed by any combination of the above-mentioned technical features or their equivalent features without departing from the above-mentioned inventive concept. For example, the above-mentioned features are replaced with the technical features with similar functions disclosed in the embodiments of the present disclosure (but not limited to) and the technical solutions formed.

Claims

1. An image encoding method, comprising: Selecting a video merge index and a video merge coding cost estimate value for an inter-frame image in a video merge coding mode; Based on the video merge index, outputting an advanced motion vector coding cost estimation value, a motion vector prediction value and a motion vector of an inter-frame image in an advanced motion vector prediction mode; Determining a target coding mode based on the high-level motion vector coding cost estimate and the video merge coding cost estimate; Based on the target coding mode, encoding codeword information is output.

2. The method according to claim 1, wherein: The method of outputting an advanced motion vector coding cost estimation value, a motion vector prediction value and a motion vector of an inter-frame image in an advanced motion vector prediction mode based on the video merge index comprises: Obtaining an advanced motion vector prediction value when an inter-frame image is in an advanced motion vector prediction mode; Performing motion estimation processing on the high-level motion vector prediction value to generate a first motion vector and a first high-level motion vector coding cost estimate value; Determine a merge index motion vector prediction value of the video merge index; Performing motion estimation processing on the merged index motion vector prediction value to generate a second motion vector and a second high-level motion vector coding cost estimate value; In response to determining that the first advanced motion vector encoding cost estimate value is less than the second advanced motion vector encoding cost estimate value, the first advanced motion vector encoding cost estimate value is determined as the advanced motion vector encoding cost estimate value in advanced motion vector prediction mode.

3. The method according to claim 2, wherein: The method of outputting an advanced motion vector coding cost estimation value, a motion vector prediction value and a motion vector of an inter-frame image in an advanced motion vector prediction mode based on the video merge index also includes: In response to determining that the second advanced motion vector encoding cost estimate value is less than the first advanced motion vector encoding cost estimate value, the second advanced motion vector encoding cost estimate value is determined as the advanced motion vector encoding cost estimate value in the advanced motion vector prediction mode.

4. The method according to claim 2, wherein: The determining of the target coding mode based on the high-level motion vector coding cost estimate and the video merge coding cost estimate comprises: In response to determining that the video merge coding cost estimate value is less than the high-level motion vector coding cost estimate value, the video merge coding mode is determined as a target coding mode.

5. The method according to claim 4, wherein: The determining of the target coding mode based on the high-level motion vector coding cost estimate and the video merge coding cost estimate further includes: In response to determining that the advanced motion vector coding cost estimate value is less than the video merge coding cost estimate value, the advanced motion vector prediction mode is determined as a target coding mode.

6. The method according to claim 1, wherein: The step of outputting encoding codeword information based on the target encoding mode includes: In response to determining that the target encoding mode is the video merge encoding mode, a video merge index is output.

7. The method according to claim 1, wherein: The output encoding codeword information also includes: In response to determining that the target coding mode is the advanced motion vector prediction mode and the motion vector prediction value is the advanced motion vector prediction value, outputting a mode flag of 0 and a motion vector residual; In response to determining that the target coding mode is the advanced motion vector prediction mode, and the motion vector prediction value is the merge index motion vector prediction value, the output mode flag is 1, the video merge index, and the motion vector residual.

8. An image encoding device, comprising: A selection unit is configured to select a video merging index and a video merging coding cost estimation value of an inter-frame image in a video merging coding mode; A first output unit is configured to output an advanced motion vector coding cost estimation value, a motion vector prediction value and a motion vector of an inter-frame image in an advanced motion vector prediction mode based on the video merge index; A determination unit configured to determine a target coding mode based on the high-level motion vector coding cost estimate and the video merge coding cost estimate; The second output unit is configured to output the encoded codeword information based on the target encoding mode.

9. An electronic device, comprising: one or more processors; a storage device having one or more programs stored thereon; When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.

10. A computer readable medium having a computer program stored thereon, wherein: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.