QP determination method and device based on AI information, computer equipment and storage medium
Through neural networks, video frames are divided into image blocks and similar objects are recognized, combined with importance scores, and QP information is accurately adjusted, which solves the problem of improving video quality in the prior art, especially in the clarity adjustment of the area of interest.
Patent Information
- Application Number
- CN202411994333.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-05-23
AI Technical Summary
The prior art is difficult to finely adjust the quantization parameters (QP) of video frames to improve the clarity of the region of interest, making it difficult to achieve video quality improvement.
The video frame is divided into image blocks through the preset neural network, similar objects are identified and their similar probability values and importance scores are calculated, and the target quantization parameter QP information is determined using the preset encoder.
The accuracy of the video frame QP information is improved, and the video quality is enhanced, especially the subjective effect in the area of interest.
Smart Images

Figure CN120034649A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of video image coding, and in particular to a QP determination method, device, computer equipment and storage medium based on AI information. Background Art
[0002] With the development of science and technology, people's demand for high-resolution videos is growing. However, the raw video data of high resolution is usually very large and has high requirements for storage and transmission. Video coding technology can use the spatial correlation and temporal correlation of videos to remove redundant information of raw videos, achieve efficient compression, and reduce the required storage space and transmission bandwidth. At the same time, neural networks have developed rapidly in recent years. How to combine neural networks and video coding technology to improve the subjective quality of coding has become a recent research hotspot.
[0003] Video coding technology can greatly compress the original data. Under the condition of constant bit rate (CBR), the larger the given bit rate, the better the bit stream quality, the clearer the picture, and the larger the space required for the bit stream; the smaller the bit rate, the worse the bit stream quality, the blurrier the picture, and the smaller the space required for the bit stream. There is little research on how to fine-tune the clarity of the area of interest (such as cars, license plates, and faces). The current combination of neural networks and video coding mainly focuses on changing the prediction mode to improve the overall quality of the picture. This type of research is often more complicated to implement in practical applications, and it is difficult to fine-tune the quantization parameter (Quantization Parameter, QP) of the area of interest. Therefore, how to accurately determine the QP information of the video frame through AI technology to improve the video quality has become a technical problem that needs to be solved urgently. Summary of the invention
[0004] The present application provides a QP determination method, apparatus, computer equipment and storage medium based on AI information, which accurately determines the QP information of video frames through AI technology to improve video quality.
[0005] In a first aspect, the present application provides a QP determination method based on AI information, the method comprising:
[0006] Processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each of the image blocks through the preset neural network, and determining a similarity probability value between each of the image blocks and a similar object;
[0007] Obtaining in advance the importance score of each of the similar objects;
[0008] Based on each of the similarity probability values and each of the importance scores, target quantization parameter QP information of each of the image blocks is determined by a preset encoder.
[0009] In a second aspect, the present application further provides a QP determination device based on AI information, the device comprising:
[0010] a similarity probability value calculation module, used to process a single-frame initial image through a preset neural network, divide the single-frame initial image into at least one image block, and identify each of the image blocks through the preset neural network, and determine a similarity probability value between each of the image blocks and a similar object;
[0011] An importance score prediction module, used to obtain the importance score of each of the similar objects in advance;
[0012] The target QP information determination module is used to determine the target quantization parameter QP information of each image block through a preset encoder based on each similarity probability value and each importance score.
[0013] In a third aspect, the present application also provides a computer device, comprising a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program and implement the QP determination method based on AI information as described above when executing the computer program.
[0014] In a fourth aspect, the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor implements the QP determination method based on AI information as described above.
[0015] The present application discloses a QP determination method, device, computer equipment and storage medium based on AI information, wherein the QP determination method based on AI information includes processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each of the image blocks through the preset neural network, determining the similarity probability value between each of the image blocks and similar objects; pre-acquiring the importance score of each of the similar objects; and determining the target quantization parameter QP information of each of the image blocks through a preset encoder based on each of the similarity probability values and each of the importance scores. In the above manner, the present application divides the single-frame initial image into image blocks through a preset neural network, and identifies similar objects therein. By calculating the similarity probability values of similar objects, objects in the image can be more accurately identified and distinguished, and the QP information is automatically adjusted according to the importance of the object, thereby improving the accuracy of determining the QP information of the video frame, thereby improving the video quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0017] Figure 1 is a schematic flow chart of a QP determination method based on AI information provided in the first embodiment of the present application;
[0018] Figure 2 A schematic diagram of image block division of a QP determination method based on AI information provided in the first embodiment of the present application;
[0019] Figure 3 is a schematic flow chart of a QP determination method based on AI information provided in the second embodiment of the present application;
[0020] Figure 4 is a schematic flow chart of a QP determination method based on AI information provided in the third embodiment of the present application;
[0021] Figure 5 A schematic block diagram of a QP determination device based on AI information provided in an embodiment of the present application;
[0022] Figure 6 A schematic block diagram of the structure of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0023] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0024] The flowcharts shown in the accompanying drawings are only examples and do not necessarily include all the contents and operations / steps, nor must they be executed in the order described. For example, some operations / steps may also be decomposed, combined or partially merged, so the actual execution order may change according to actual conditions.
[0025] It should be understood that the terms used in this application specification are only for the purpose of describing specific embodiments and are not intended to limit the application. As used in this application specification and the appended claims, unless the context clearly indicates otherwise, the singular forms "a", "an" and "the" are intended to include plural forms.
[0026] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0027] The embodiments of the present application provide a QP determination method, device, computer equipment and storage medium based on AI information. Among them, the QP determination method based on AI information can be applied to a server, and a single frame initial image is divided into image blocks by a preset neural network, and similar objects therein are identified. By calculating the similarity probability values of similar objects, objects in the image can be more accurately identified and distinguished, and the QP information is automatically adjusted according to the importance of the object, thereby improving the accuracy of determining the QP information of the video frame, thereby improving the video quality. Among them, the server can be an independent server or a server cluster.
[0028] In conjunction with the accompanying drawings, some embodiments of the present application are described in detail below. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.
[0029] See also Figure 1 , Figure 1 This is a schematic flow chart of a QP determination method based on AI information provided by the first embodiment of the present application. The QP determination method based on AI information can be applied to a server, and is used to divide a single-frame initial image into image blocks through a preset neural network, and identify similar objects therein. By calculating the similarity probability values of similar objects, objects in the image can be more accurately identified and distinguished, and the QP information is automatically adjusted according to the importance of the object, thereby improving the accuracy of determining the QP information of the video frame, thereby improving the video quality.
[0030] like Figure 1 As shown, the QP determination method based on AI information specifically includes steps S10 to S30.
[0031] Step S10, processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each image block through the preset neural network, and determining a similarity probability value between each image block and a similar object;
[0032] Specifically, Figure 2 As shown, Figure 2A schematic diagram of image block division of a QP determination method based on AI information provided for the first embodiment of the present application. The coding standard used in this embodiment is HEVC (High Efficiency Video Coding), which introduces a tree coding unit (Coding Tree Unit, CTU). A frame of image can be divided into several non-overlapping CTUs, and each CTU can be further subdivided into smaller blocks. When encoding, CTUs are encoded in order from left to right and from top to bottom.
[0033] When the neural network divides a single frame of the initial image, it also needs to divide it into blocks and calculate the probability of each block being a certain object. The smaller the block divided by the neural network, the more obvious the effect of improving the subjective quality of encoding, but the complexity will be significantly increased. After comprehensively considering the complexity and performance, the division is carried out in 16*16 blocks. The more pixels a certain object has in the current block, the higher its probability. The probability value range is [0,1].
[0034] Step S20, obtaining the importance score of each of the similar objects in advance;
[0035] Specifically, the importance score in this embodiment may be a score with various meanings, such as the user's interest in similar objects, or the importance score of similar objects may be determined from a historical database.
[0036] Step S30: Based on each of the similarity probability values and each of the importance scores, determine target quantization parameter QP information of each of the image blocks through a preset encoder.
[0037] Specifically, after determining the probability that the current CTU is a similar object, the QP of the current coding block is adjusted accordingly. If the current block is the object of interest and the greater the probability, the greater the reduction in QP; the smaller the probability that the current block is the object of interest, the smaller the reduction in QP. At the same time, if the current block is not the object of interest, the QP of the current block can be increased, and the saved bit rate can be used for the area of interest. This will not cause a significant increase in bit rate when improving the subjective effect of the area of interest. The smaller the block segmented by the neural network, the finer the encoder adjusts the QP, and the larger the segmented block, the coarser the QP adjustment.
[0038] In one embodiment, a single frame initial image is received as input and prepared for subsequent processing. The input image is analyzed using a preset neural network model to divide the image into at least one initial tree-shaped coding unit (CTU), each CTU being a region of the image that can be further subdivided into smaller coding units (CU).
[0039] Within each CTU, the neural network identifies similar objects, which involves sub-steps such as feature extraction, object detection, and classification. For each similar object, its similarity probability value with other known objects is calculated, and the importance of each similar object is scored using a preset neural network.
[0040] Based on the similarity probability value and importance score of each similar object, the preset encoder determines the target quantization parameter (QP) information of each CTU. The QP information can specifically be factors such as coding efficiency, image quality, and bit rate control.
[0041] The present embodiment discloses a QP determination method, device, computer equipment and storage medium based on AI information, wherein the QP determination method based on AI information includes processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each of the image blocks through the preset neural network, determining the similarity probability value between each of the image blocks and similar objects; pre-acquiring the importance score of each of the similar objects; and determining the target quantization parameter QP information of each of the image blocks through a preset encoder based on each of the similarity probability values and each of the importance scores. In the above manner, the present application divides the single-frame initial image into image blocks through a preset neural network, and identifies similar objects therein. By calculating the similarity probability values of similar objects, objects in the image can be more accurately identified and distinguished, and the QP information is automatically adjusted according to the importance of the object, thereby improving the accuracy of determining the QP information of the video frame, thereby improving the video quality.
[0042] See also Figure 3 , Figure 3 This is a schematic flow chart of a QP determination method based on AI information provided in the second embodiment of the present application. The QP determination method based on AI information can be applied to a server, and the image is divided into image blocks according to the HEVC standard using a preset neural network, which can ensure the accuracy and consistency of image segmentation, thereby improving coding efficiency and image quality. The neural network identifies similar objects in image blocks and extracts features, which can improve the accuracy of object recognition. The neural network predicts the importance score of the object, so that the encoding process can adaptively allocate resources according to the importance of the object, optimize the encoding efficiency, and improve the accuracy of determining the QP information of the video frame, thereby improving the video quality.
[0043] based on Figure 1 The embodiment shown, this embodiment Figure 3 As shown, step S10 includes steps S101 to S104.
[0044] Step S101, dividing the single-frame initial image into at least one image block according to the image size of the single-frame initial image and a preset high-efficiency video coding standard HEVC;
[0045] Step S102, identifying each of the similar objects in each of the image blocks through the preset neural network, and extracting object features of each of the similar objects;
[0046] Step S103, determining a similarity index according to the object features of each of the similar objects;
[0047] Step S104: Calculate the similarity probability value between each image block and each similar object through the preset neural network and each similarity index.
[0048] In one embodiment, according to the image size and the preset HEVC standard, a single frame initial image is divided into at least one image block using a quadtree structure. CTU (image block) is the largest coding unit in HEVC and can be further divided into multiple coding units (CU).
[0049] A preset neural network is used to identify similar objects in each image block and extract the features of these objects. The preset neural network can be a convolutional neural network (CNN) for feature extraction and object recognition. Based on the extracted object features, a similarity index is determined. The similarity index includes features such as shape, color, and texture, which are used for subsequent similarity measurement. The similarity probability value of each similar object is calculated using the similarity measurement model and similarity index built into the preset neural network.
[0050] The present embodiment discloses a QP determination method, device, computer equipment and storage medium based on AI information. The QP determination method based on AI information includes dividing the single-frame initial image into at least one image block according to the image size of the single-frame initial image and a preset high-efficiency video coding standard HEVC; identifying each of the similar objects in each of the image blocks through the preset neural network, and extracting the object features of each of the similar objects; determining a similarity index according to the object features of each of the similar objects; calculating a similarity probability value between each image block and each of the similar objects through the preset neural network and each of the similarity indexes; obtaining an importance score of each of the similar objects in advance; and determining the target quantization parameter QP information of each of the image blocks through a preset encoder based on each of the similarity probability values and each of the importance scores. Through the above method, the present application utilizes a preset neural network to divide the image into image blocks according to the HEVC standard, which can ensure the accuracy and consistency of image segmentation, thereby improving coding efficiency and image quality. By identifying similar objects in image blocks and extracting features through the neural network, the accuracy of object recognition can be improved. The neural network predicts the importance score of the object, so that the encoding process can adaptively allocate resources according to the importance of the object, optimize the coding efficiency, improve the accuracy of determining the QP information of the video frame, and thus improve the video quality.
[0051] In one embodiment, step S104 includes:
[0052] Determining similar object features of each of the similar objects according to each of the similarity indicators;
[0053] The participation degree of each of the similar object features is calculated by the preset neural network, and the participation degree is defined as the similarity probability value.
[0054] In one embodiment, the preset neural network generally includes at least one convolutional layer and at least one fully connected layer. Images of similar objects are input into the preset neural network, and image features are extracted through the convolutional layer in the preset neural network. The convolutional layer can capture local features and patterns in the image, and the features are further extracted and integrated through the fully connected layer in the network. The fully connected layer helps to form a global feature representation.
[0055] On the basis of feature extraction, a specific mechanism in the preset neural network (such as attention mechanism) is used to calculate the participation of each similar object feature, and based on the calculated feature participation, the similarity probability value of each similar object feature in the preset neural network is determined.
[0056] See also Figure 4 , Figure 4 This is a schematic flow chart of a QP determination method based on AI information provided in the third embodiment of the present application. The QP determination method based on AI information can be applied to a server, and is used to divide an image into image blocks and identify similar objects through a preset neural network. It can encode the image content more accurately, thereby improving the encoding efficiency, determining the object type when the similarity probability value is higher than the threshold, helping to adopt different encoding strategies for different object types, optimizing resource allocation, and improving the accuracy of determining the QP information of the video frame, thereby improving the video quality.
[0057] based on Figure 1 The embodiment shown, this embodiment Figure 4 As shown, step S30 includes steps S301 to S303.
[0058] Step S301: when the similarity probability value is higher than a probability threshold, determining the object type of the similar object;
[0059] Step S302: determining the importance of the image block according to the object type and each importance score;
[0060] Step S303: Determine the target QP information according to the importance of the image block.
[0061] In one embodiment, after calculating the similarity probability value of each similar object, a probability threshold is set to check whether the similarity probability value of each similar object is higher than the probability threshold. For similar objects with similarity probability values higher than the threshold, a preset neural network or classification model is used to determine the object type. The object type can be determined based on a classification algorithm of object features, such as a support vector machine (SVM), a decision tree, or a deep learning model. According to the determined object type and the importance score of each similar object, the importance of each image block is evaluated, and the target quantization parameter (QP) information is determined according to the importance of the image block.
[0062] The present embodiment discloses a QP determination method, device, computer equipment and storage medium based on AI information, wherein the QP determination method based on AI information includes processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each of the image blocks through the preset neural network, determining the similarity probability value between each of the image blocks and similar objects; obtaining the importance score of each of the similar objects in advance; determining the object type of the similar object when the similarity probability value is higher than the probability threshold; determining the importance of the image block according to the object type and each of the importance scores; and determining the target QP information according to the importance of the image block. In the above manner, the present application divides the image into image blocks and identifies similar objects through a preset neural network, and can encode the image content more accurately, thereby improving the encoding efficiency, and determining the object type when the similarity probability value is higher than the threshold, which helps to adopt different encoding strategies for different object types, optimize resource allocation, and improve the accuracy of determining the QP information of the video frame, thereby improving the video quality.
[0063] In a more preferred embodiment, step S303 includes:
[0064] When the importance of the image block is higher than a preset importance threshold, lowering the target QP information;
[0065] When the importance of the image block is lower than or equal to the preset importance threshold, the target QP information is increased.
[0066] Specifically, if the current block is the object of interest, and the greater the probability, the greater the reduction in QP; the smaller the probability that the current block is the object of interest, the smaller the reduction in QP. At the same time, if the current block is not the object of interest, the QP of the current block can be increased, and the saved bit rate can be used for the area of interest. In this way, when the subjective effect of the area of interest is improved, it will not cause a significant increase in bit rate. The smaller the block segmented by the neural network, the finer the encoder adjusts the QP, and the larger the segmented block, the coarser the adjustment of QP.
[0067] In a more preferred embodiment, based on Figure 1 In the embodiment shown, in this embodiment, before step S10, the following steps are included:
[0068] Obtaining preset object features and object labels of each preset object in the historical object database, and using the preset object features as a training set and the object labels as a verification set;
[0069] Predicting similar probability values of the training set through an initial neural network to generate training results;
[0070] Based on the training results and the verification set, a verification result is generated, and the initial neural network is fine-tuned by the verification result to generate the preset neural network.
[0071] Specifically, preset object features and object labels of preset objects are extracted from the historical object database. These data will be used to train and verify the neural network model. The preset object features are used as training sets, and the object labels are used as verification sets to provide a data basis for the training and evaluation of the neural network. The training set is predicted through the initial neural network to generate training results.
[0072] Based on the training results and the validation set, the validation results are generated, and the parameters of the initial neural network are fine-tuned according to the validation results. Fine-tuning can optimize the model parameters and improve the performance of the model on specific tasks. After parameter fine-tuning, the final preset neural network is generated.
[0073] Based on any of the above embodiments, in this embodiment, after step S30, the following steps are further included:
[0074] According to the target QP information, each of the image blocks is encoded by the preset encoder to generate a single-frame target image corresponding to the initial single-frame initial image.
[0075] Specifically, the process of the present application is briefly summarized based on the above embodiments, and the importance scoring is based on the user's interest level as an example.
[0076] First, read the raw data of a single-frame initial image, set the object of interest (such as a person or a car) and the intensity of interest of the object, and process the raw data by frame through a neural network, divide it into blocks, calculate the probability of each block being which object it is, and send it to the encoder. The encoder adjusts the image based on the probability of the current block and the intensity of interest of the object to improve the subjective quality of the area of interest and save the bit rate of the non-interested area. If all frames are processed, end the current process, otherwise continue the process with the next frame until all frames are processed.
[0077] See also Figure 5 , Figure 5The embodiment of the present application provides a schematic block diagram of a QP determination device based on AI information, wherein the QP determination device based on AI information is used to perform the aforementioned QP determination method based on AI information. The QP determination device based on AI information can be configured on a server.
[0078] like Figure 5 As shown, the QP determination device 400 based on AI information includes:
[0079] A similarity probability value calculation module 410 is used to process a single-frame initial image through a preset neural network, divide the single-frame initial image into at least one image block, and identify each image block through the preset neural network to determine a similarity probability value between each image block and a similar object;
[0080] An importance score prediction module 420, used to obtain the importance score of each of the similar objects in advance;
[0081] The target QP information determination module 430 is used to determine the target quantization parameter QP information of each of the image blocks through a preset encoder based on each of the similarity probability values and each of the importance scores.
[0082] Furthermore, the similarity probability value calculation module 410 includes:
[0083] An image block division unit, configured to divide the single-frame initial image into at least one image block according to an image size of the single-frame initial image and a preset high-efficiency video coding standard HEVC;
[0084] An object feature extraction unit, configured to identify each of the similar objects in each of the image blocks through the preset neural network, and extract object features of each of the similar objects;
[0085] A similarity index determination unit, used to determine a similarity index according to the object features of each of the similar objects;
[0086] The similarity probability value calculation unit is used to calculate the similarity probability value between each image block and each similar object through the preset neural network and each similarity index.
[0087] Furthermore, the similarity probability value calculation unit includes:
[0088] A similar object feature determination subunit, used to determine the similar object feature of each of the similar objects according to each of the similarity indicators;
[0089] The similarity probability value definition subunit is used to calculate the participation degree of each of the similar object features through the preset neural network, and define the participation degree as the similarity probability value.
[0090] Furthermore, the target QP information determination module 430 includes:
[0091] an object type determination unit, configured to determine the object type of the similar object when the similarity probability value is higher than a probability threshold;
[0092] An importance determination unit, configured to determine the importance of the image block according to the object type and each importance score;
[0093] The target QP information determining unit is used to determine the target QP information according to the importance of the image block.
[0094] Further, the target QP information determining unit includes:
[0095] a target QP information reducing subunit, configured to reduce the target QP information if the importance of the image block is higher than a preset importance threshold;
[0096] The target QP information increasing subunit is used to increase the target QP information when the importance of the image block is lower than or equal to the preset importance threshold.
[0097] Further, the QP determination device 400 based on AI information includes:
[0098] A feature and label acquisition module, used to acquire preset object features and object labels of each preset object in the historical object database, and use the preset object features as a training set and the object labels as a verification set;
[0099] A training result generating module, used for predicting the similarity probability value of the training set through an initial neural network to generate a training result;
[0100] The preset neural network generation module is used to generate a verification result based on the training result and the verification set, and to perform parameter fine-tuning processing on the initial neural network through the verification result to generate the preset neural network.
[0101] Further, the QP determination device 400 based on AI information includes:
[0102] The encoding module is used to encode each of the image blocks through the preset encoder according to the target QP information to generate a single-frame target image corresponding to the initial single-frame initial image.
[0103] It should be noted that those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-described device and each module can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0104] The above-mentioned device can be implemented in the form of a computer program. Figure 6 Runs on the computer device shown.
[0105] See also Figure 6 , Figure 6 1 is a schematic block diagram of a computer device provided in an embodiment of the present application. The computer device may be a server.
[0106] See also Figure 6 The computer device includes a processor, a memory and a network interface connected through a system bus, wherein the memory may include a non-volatile storage medium and an internal memory.
[0107] The non-volatile storage medium can store an operating system and a computer program. The computer program includes program instructions, and when the program instructions are executed, the processor can execute any QP determination method based on AI information.
[0108] The processor is used to provide computing and control capabilities and support the operation of the entire computer equipment.
[0109] The internal memory provides an environment for the operation of the computer program in the non-volatile storage medium. When the computer program is executed by the processor, the processor can execute any QP determination method based on AI information.
[0110] The network interface is used for network communication, such as sending assigned tasks, etc. Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0111] It should be understood that the processor may be a central processing unit (CPU), and the processor may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0112] In one embodiment, the processor is used to run a computer program stored in the memory to implement the following steps:
[0113] Processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each of the image blocks through the preset neural network, and determining a similarity probability value between each of the image blocks and a similar object;
[0114] Obtaining in advance the importance score of each of the similar objects;
[0115] Based on each of the similarity probability values and each of the importance scores, target quantization parameter QP information of each of the image blocks is determined by a preset encoder.
[0116] In one embodiment, a single-frame initial image is processed by a preset neural network, the single-frame initial image is segmented into at least one image block, and each image block is identified by the preset neural network, and a similarity probability value between each image block and a similar object is determined to achieve:
[0117] Dividing the single-frame initial image into at least one image block according to an image size of the single-frame initial image and a preset high-efficiency video coding standard HEVC;
[0118] Identifying each of the similar objects in each of the image blocks through the preset neural network, and extracting object features of each of the similar objects;
[0119] Determining a similarity index according to the object features of each of the similar objects;
[0120] The similarity probability value between each image block and each similar object is calculated through the preset neural network and each similarity index.
[0121] In one embodiment, the similarity probability value between each image block and each similar object is calculated by using the preset neural network and each similarity index, so as to achieve:
[0122] Determining similar object features of each of the similar objects according to each of the similarity indicators;
[0123] The participation degree of each of the similar object features is calculated by the preset neural network, and the participation degree is defined as the similarity probability value.
[0124] In one embodiment, based on each of the similarity probability values and each of the importance scores, a target quantization parameter QP information of each of the image blocks is determined by a preset encoder to achieve:
[0125] In a case where the similarity probability value is higher than a probability threshold, determining an object type of the similar object;
[0126] Determining the importance of the image block according to the object type and each importance score;
[0127] The target QP information is determined according to the importance of the image block.
[0128] In one embodiment, the target QP information is determined according to the importance of the image block, so as to achieve:
[0129] When the importance of the image block is higher than a preset importance threshold, lowering the target QP information;
[0130] When the importance of the image block is lower than or equal to the preset importance threshold, the target QP information is increased.
[0131] In one embodiment, a single-frame initial image is processed by a preset neural network, the single-frame initial image is segmented into at least one image block, and each image block is identified by the preset neural network, and before the similarity probability value between each image block and a similar object is determined, it is used to implement:
[0132] Obtaining preset object features and object labels of each preset object in the historical object database, and using the preset object features as a training set and the object labels as a verification set;
[0133] Predicting similar probability values of the training set through an initial neural network to generate training results;
[0134] Based on the training results and the verification set, a verification result is generated, and the initial neural network is fine-tuned by the verification result to generate the preset neural network.
[0135] In one embodiment, based on each of the similarity probability values and each of the importance scores, after the target quantization parameter QP information of each of the image blocks is determined by a preset encoder, it is used to implement:
[0136] According to the target QP information, each of the image blocks is encoded by the preset encoder to generate a single-frame target image corresponding to the initial single-frame initial image.
[0137] A computer-readable storage medium is also provided in an embodiment of the present application, wherein the computer-readable storage medium stores a computer program, wherein the computer program includes program instructions, and the processor executes the program instructions to implement any one of the QP determination methods based on AI information provided in the embodiments of the present application.
[0138] The computer-readable storage medium may be an internal storage unit of the computer device described in the foregoing embodiment, such as a hard disk or memory of the computer device. The computer-readable storage medium may also be an external storage device of the computer device, such as a plug-in hard disk, a smart memory card (Smart Medi a Card, SMC), a secure digital (Secure Digital, SD) card, a flash memory card (Flash Card), etc., equipped on the computer device.
[0139] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in the present application, and these modifications or replacements should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A QP determination method based on AI information, characterized in that: include: Processing a single-frame initial image through a preset neural network, dividing the single-frame initial image into at least one image block, and identifying each of the image blocks through the preset neural network, and determining a similarity probability value between each of the image blocks and a similar object; Obtaining in advance the importance score of each of the similar objects; Based on each of the similarity probability values and each of the importance scores, target quantization parameter QP information of each of the image blocks is determined by a preset encoder.
2. The QP determination method based on AI information according to claim 1, characterized in that: The method of processing a single-frame initial image by using a preset neural network, dividing the single-frame initial image into at least one image block, identifying each image block by using the preset neural network, and determining a similarity probability value between each image block and a similar object includes: Dividing the single-frame initial image into at least one image block according to an image size of the single-frame initial image and a preset high-efficiency video coding standard HEVC; Identifying each of the similar objects in each of the image blocks through the preset neural network, and extracting object features of each of the similar objects; Determining a similarity index according to the object features of each of the similar objects; The similarity probability value between each image block and each similar object is calculated through the preset neural network and each similarity index.
3. The QP determination method based on AI information according to claim 2, characterized in that: The calculating the similarity probability value between each image block and each similar object by using the preset neural network and each similarity index includes: Determining similar object features of each of the similar objects according to each of the similarity indicators; The participation degree of each of the similar object features is calculated by the preset neural network, and the participation degree is defined as the similarity probability value.
4. The QP determination method based on AI information according to claim 1, characterized in that: The step of determining target quantization parameter QP information of each image block by a preset encoder based on each similarity probability value and each importance score includes: In a case where the similarity probability value is higher than a probability threshold, determining an object type of the similar object; Determining the importance of the image block according to the object type and each importance score; The target QP information is determined according to the importance of the image block.
5. The QP determination method based on AI information according to claim 4, characterized in that: The determining the target QP information according to the importance of the image block includes: When the importance of the image block is higher than a preset importance threshold, lowering the target QP information; When the importance of the image block is lower than or equal to the preset importance threshold, the target QP information is increased.
6. The QP determination method based on AI information according to claim 1, characterized in that: The method includes: processing a single-frame initial image by using a preset neural network, dividing the single-frame initial image into at least one image block, identifying each image block by using the preset neural network, and determining a similarity probability value between each image block and a similar object. Obtaining preset object features and object labels of each preset object in the historical object database, and using the preset object features as a training set and the object labels as a verification set; Predicting similar probability values of the training set through an initial neural network to generate training results; Based on the training results and the verification set, a verification result is generated, and the initial neural network is fine-tuned by the verification result to generate the preset neural network.
7. The QP determination method based on AI information according to any one of claims 1 to 6, characterized in that: After determining the target quantization parameter QP information of each image block by a preset encoder based on each similarity probability value and each importance score, the method further comprises: According to the target QP information, each of the image blocks is encoded by the preset encoder to generate a single-frame target image corresponding to the initial single-frame initial image.
8. A QP determination device based on AI information, characterized in that: include: a similarity probability value calculation module, used to process a single-frame initial image through a preset neural network, divide the single-frame initial image into at least one image block, and identify each of the image blocks through the preset neural network, and determine a similarity probability value between each of the image blocks and a similar object; An importance score prediction module, used to obtain the importance score of each of the similar objects in advance; The target QP information determination module is used to determine the target quantization parameter QP information of each image block through a preset encoder based on each similarity probability value and each importance score.
9. A computer device, characterized in that: The computer device includes a memory and a processor; The memory is used to store computer programs; The processor is configured to execute the computer program and implement the QP determination method based on AI information according to any one of claims 1 to 7 when executing the computer program.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, which, when executed by a processor, enables the processor to implement the QP determination method based on AI information according to any one of claims 1 to 7.