Video transcoding method, device, server and medium

By predicting the popularity of newly uploaded videos and encoding only the hot videos at low rates, the problem of increasing equipment costs in the existing technology is solved, and the effect of reducing video transmission bandwidth consumption and cost is achieved.

CN114257815BActive Publication Date: 2025-02-25DOUYIN VISION CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111566633.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-20
Publication Date
2025-02-25
Estimated Expiration
2041-12-20

AI Technical Summary

Technical Problem

While reducing the consumption of video transmission bandwidth, the prior art increases equipment costs, especially when a large number of video uploads require a large number of servers to support computing power.

Method used

By determining the static information of the newly uploaded target video and inputting it into the preset uploaded heat prediction model for heat prediction, if the prediction result is hot video, the target video is transcoding using the preset hot video encoding method with a low video code rate.

Benefits of technology

Only the hot video encoding method is used to preset hot video encoding methods, without setting up a large number of servers, avoiding increasing equipment costs. At the same time, by predicting video popularity in advance, the hot video transcoding time is advanced, further reducing the bandwidth consumption and cost of video transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114257815B_ABST
    Figure CN114257815B_ABST
Patent Text Reader

Abstract

The disclosed embodiment discloses a video transcoding method, device, server and medium. The method includes: obtaining a newly uploaded target video; determining the target video static information corresponding to the target video; inputting the target video static information into a preset upload heat prediction model to perform heat prediction during uploading, and determining the upload heat prediction result corresponding to the target video; if the upload heat prediction result is a hot video, transcoding the target video using a preset hot video encoding method. Through the technical solution of the disclosed embodiment, the video transmission cost can be reduced without increasing the equipment cost.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present disclosure relate to Internet technologies, and more particularly to a video transcoding method, device, server, and medium. Background Art

[0002] With the development of mobile Internet, the traffic of video services has increased rapidly, and the bandwidth consumption of video transmission has become an important cost expenditure for video service providers.

[0003] At present, in order to reduce the bandwidth consumption of video transmission, the video can be transcoded using a coding method with a lower video bit rate while ensuring the video quality. For example, the H265 coding method can be used for video transcoding. However, video transcoding using a coding method with a lower video bit rate requires more computing power. If this coding method is used to transcode a large number of videos uploaded every day, a large number of servers need to be set up for computing power support, which will increase the equipment cost while reducing the video transmission cost. It can be seen that how to reduce the video transmission cost without increasing the equipment cost is crucial. Summary of the invention

[0004] The embodiments of the present disclosure provide a video transcoding method, apparatus, server, and medium to reduce video transmission costs without increasing equipment costs.

[0005] In a first aspect, an embodiment of the present disclosure provides a video transcoding method, including:

[0006] Get the newly uploaded target video;

[0007] Determine target video static information corresponding to the target video;

[0008] Inputting the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determining an upload heat prediction result corresponding to the target video;

[0009] If the uploaded heat prediction result is a hot video, the target video is transcoded using a preset hot video encoding method.

[0010] In a second aspect, the present disclosure also provides a video transcoding device, including:

[0011] The target video acquisition module is used to acquire the newly uploaded target video;

[0012] A target information video static determination module is used to determine the target video static information corresponding to the target video;

[0013] An upload heat prediction module, used to input the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determine an upload heat prediction result corresponding to the target video;

[0014] The thermal video transcoding module is used to transcode the target video using a preset thermal video encoding method if the uploaded heat prediction result is a thermal video.

[0015] In a third aspect, an embodiment of the present disclosure further provides a server, the server comprising:

[0016] one or more processors;

[0017] A memory for storing one or more programs;

[0018] When the one or more programs are executed by the one or more processors, the one or more processors implement the video transcoding method provided in any embodiment of the present disclosure.

[0019] In a fourth aspect, an embodiment of the present disclosure further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a video transcoding method as provided in any embodiment of the present disclosure.

[0020] The disclosed embodiment determines the target video static information corresponding to the newly uploaded target video, and inputs the target video static information into a preset upload heat prediction model to perform heat prediction at the time of uploading, determines the upload heat prediction result corresponding to the target video, and when the upload heat prediction result is a hot video, transcodes the target video using a preset thermal video encoding method with a lower video bit rate, thereby only transcoding the hot video using the preset thermal video encoding method, without setting up a large number of servers for computing power support, thereby not increasing the equipment cost, and by performing video heat prediction when the video is uploaded, there is no need to wait until the video is played to perform video heat prediction, thereby advancing the transcoding time of the hot video, further reducing the bandwidth consumption of video transmission, and reducing the video transmission cost. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] 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 reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale.

[0022] Figure 1 is a flow chart of a video transcoding method provided by Embodiment 1 of the present disclosure;

[0023] Figure 2This is an example of a video transcoding time involved in the first embodiment of the present disclosure;

[0024] Figure 3 is a flow chart of a video transcoding method provided by Embodiment 2 of the present disclosure;

[0025] Figure 4 This is an example of a preset playback popularity prediction model involved in the second embodiment of the present disclosure;

[0026] Figure 5 is a structural diagram of a video transcoding device provided in Embodiment 3 of the present disclosure;

[0027] Figure 6 It is a structural diagram of a server provided in Embodiment 4 of the present disclosure. DETAILED DESCRIPTION

[0028] 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 described herein, which are instead provided for 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.

[0029] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.

[0030] The term "including" and its variations used herein are open inclusions, i.e., "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.

[0031] 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.

[0032] 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".

[0033] 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.

[0034] Embodiment 1

[0035] Figure 1 This is a flow chart of a video transcoding method provided in the first embodiment of the present disclosure. This embodiment is applicable to the case of transcoding videos uploaded by users to a server. The method can be executed by a video transcoding device, which can be implemented by software and / or hardware and integrated in the server. Figure 1 As shown, the method specifically comprises the following steps:

[0036] S110: Obtain a newly uploaded target video.

[0037] The target video may refer to an original video currently contributed by the author. Specifically, after the author creates a new target video on the terminal device, the author may upload the newly created target video to the server through the terminal device for contribution, so that the server may obtain the currently newly uploaded target video.

[0038] S120: Determine target video static information corresponding to the target video.

[0039] Among them, the static information of the target video may refer to the static feature information of the target video itself. Exemplarily, the static information of the target video may include but is not limited to: at least one of the target video upload time point, the target video duration and the target video author information. The target video author information may include but is not limited to: at least one of the number of fans, the total number of uploaded videos, the number of uploaded videos in a preset historical time period, the number of uploaded video plays in a preset historical time period, the number of likes of uploaded videos in a preset historical time period, and the number of reviews of uploaded videos in a preset historical time period. Among them, the preset historical time period may refer to a recent historical time period that is preset in advance. For example, the preset historical time period may be within the recent 15 days. The number of uploaded videos in the preset historical time period may include: the total number and / or average number of uploaded videos in the preset historical time period. The number of likes of uploaded videos in the preset historical time period may include: the total number and / or average number of uploaded videos in the preset historical time period. The number of reviews of uploaded videos in the preset historical time period may include: the total number and / or average number of uploaded videos in the preset historical time period.

[0040] Specifically, the server can extract information of the newly uploaded target video to obtain the upload time and duration of the target video. The server can pre-store the author information and historical uploaded video information of each author, so that the server can query based on the target author identification information to obtain the corresponding target video author information.

[0041] S130: Input the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determine the upload heat prediction result corresponding to the target video.

[0042] Among them, the preset upload heat prediction model can be a pre-set model for predicting the heat of newly uploaded videos. For example, the preset upload heat prediction model can be but is not limited to: LightGBM (Light Gradient Boosting Machine) tree model. The LightGBM tree model is a distributed gradient boosting model based on a decision tree algorithm. The preset upload heat prediction model used in this embodiment is a model pre-trained based on sample data. Among them, the sample data may include sample video static information corresponding to the sample video and the upload heat standard result corresponding to the sample video. Among them, the upload heat standard result corresponding to the sample video can be determined based on the playback volume (i.e., viewing volume) of the sample video within 24 hours after the video is uploaded. For example, when the playback volume of the sample video within 24 hours after the video is uploaded is greater than or equal to the preset threshold, the upload heat standard result corresponding to the sample video is determined to be a hot video; when the playback volume of the sample video within 24 hours after the video is uploaded is less than the preset threshold, the upload heat standard result corresponding to the sample video is determined to be a cold video. By using the above sample data to train the preset upload heat prediction model, a preset upload heat prediction model that can accurately predict the heat of the video when the video is uploaded is obtained.

[0043] Specifically, the static information of the target video can be input into a trained preset upload heat prediction model in an input form recognizable by the model, such as a feature vector, to perform heat prediction during uploading. The preset upload heat prediction model can directly output the upload heat prediction result corresponding to the target video, or it can output the predicted probability value that the target video is a hot video, and determine the final upload heat prediction result based on the predicted probability value. For example, if the output predicted probability value is greater than 0.5, it is determined that the upload heat prediction result corresponding to the target video is a hot video, otherwise it is a cold video.

[0044] S140: If the uploaded heat prediction result is a hot video, the target video is transcoded using a preset hot video encoding method.

[0045] The preset hot video encoding method may be an encoding method with a lower video bit rate than the cold video encoding method. For example, the preset hot video encoding method may be, but is not limited to, the H265 encoding method.

[0046] Specifically, in order to ensure that the audience can watch clear and smooth videos, the videos uploaded by the author are usually transcoded. When the target video is uploaded, if it is predicted that the target video is a hot video, the preset hot video encoding method can be used to directly transcode the target video, so as to obtain a video file with a lower video bit rate, so that when the video file is sent down, the bandwidth consumption of video transmission can be reduced, thereby reducing the bandwidth cost. In addition, this embodiment only transcodes the hot video using the preset hot video encoding method, rather than all uploaded videos, so there is no need to set up a large number of servers for computing power support, and thus does not increase the equipment cost. In addition, this embodiment predicts the video heat when the video is uploaded, without waiting until the video is played to predict the video heat based on the playback characteristics, thereby advancing the transcoding time of the hot video, further reducing the bandwidth consumption of the video transmission, and reducing the video transmission cost.

[0047] It should be noted that in this embodiment, more computing power is allocated to hot videos for transcoding into H265 video files. Therefore, the higher the popularity of the video, the higher the coverage of the H265 video, which makes the average bit rate of users watching lower and the bandwidth cost lower. Therefore, by only encoding hot videos with high quality, the high concentration of popularity can be used to use only a small part of the computing power to achieve the bit rate reduction of most playbacks, thereby reducing the video transmission cost while ensuring that the consumption of transcoding computing power remains unchanged.

[0048] Exemplarily, the transcoding process for each video can be implemented in the following two ways:

[0049] As a way to achieve this, Figure 2 An example of video transcoding time is given. Figure 2 As shown, each uploaded video can be transcoded using an encoding method with low computing power consumption but high video bit rate. For example, each uploaded video can be transcoded using the H264 encoding method, thereby ensuring that terminal devices that do not support H265 can also watch the video. At the same time, the popularity of the video can be predicted when it is uploaded by executing the operations of steps S110-S130, and when the uploaded popularity prediction result is a hot video, the uploaded hot video can be transcoded twice using the H265 encoding method. When the transcoded video file is sent to the terminal device, it can be detected whether the terminal device supports watching H265 videos. If it does, the H265 video can be directly sent. If it does not, the H264 video can be sent, thereby ensuring that terminal devices that do not support H265 can also watch the video.

[0050] It should be noted that in this embodiment, the video popularity prediction is performed when the video is uploaded. Figure 2 The hot video can be transcoded to H265 at the T1 moment in the video, without waiting for the video to play for a period of time. Figure 2 At the T2 moment in the video, the video popularity is predicted based on the playback characteristics, and the hot video is transcoded to H265. Compared with the T2 moment, this embodiment can advance the transcoding time of the hot video, thereby further reducing the bandwidth consumption between the T1 moment and the T2 moment, and further saving the video transmission cost.

[0051] As another implementation method, this embodiment can perform transcoding based on the upload heat prediction result of each video. For example, if the upload heat prediction result is a hot video, the target video is transcoded using a preset hot video encoding method; if the upload heat prediction result is a cold video, the target video is transcoded using a preset cold video encoding method. Among them, when the video quality is the same, the video bit rate of the preset cold video encoding method is greater than the video bit rate of the preset hot video encoding method. For example, the preset cold video encoding method is the H264 encoding method; the preset hot video encoding method is the H265 encoding method. This embodiment can perform transcoding on each uploaded video based on the upload heat prediction result when all terminal devices support watching H265 videos, which can avoid H264 transcoding of hot videos and further reduce computing power consumption.

[0052] The technical solution of the disclosed embodiment determines the target video static information corresponding to the newly uploaded target video, and inputs the target video static information into a preset upload heat prediction model to perform heat prediction during uploading, determines the upload heat prediction result corresponding to the target video, and when the upload heat prediction result is a hot video, transcodes the target video using a preset thermal video encoding method with a lower video bit rate, thereby only transcoding the hot video using the preset thermal video encoding method, without setting up a large number of servers for computing power support, thereby not increasing the equipment cost, and by performing video heat prediction when the video is uploaded, there is no need to wait until the video is played to perform video heat prediction, thereby advancing the transcoding time of the hot video, further reducing the bandwidth consumption of video transmission, and reducing the video transmission cost.

[0053] Embodiment 2

[0054] Figure 3 This is a flowchart of a video transcoding method provided in the second embodiment of the present disclosure. Based on the above embodiments, this embodiment describes in detail the process of heat prediction and video secondary transcoding when playing the target video after the upload heat prediction result corresponding to the target video is a cold video. The explanations of the terms that are the same or corresponding to the above embodiments are not repeated here.

[0055] See also Figure 3 The frequency transcoding method provided in this embodiment specifically includes the following steps:

[0056] S310: Obtain a newly uploaded target video.

[0057] S320: Determine target video static information corresponding to the target video.

[0058] S330: Input the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determine the upload heat prediction result corresponding to the target video.

[0059] S340: If the uploaded heat prediction result is a cold video, the target video dynamic information when the target video is currently being played is obtained.

[0060] Among them, the target video dynamic information may refer to the timing feature information of the current playback after the target video is uploaded. The target video dynamic information may change dynamically over time. Exemplarily, the target video dynamic information may include, but is not limited to: at least one of the current cumulative playback volume, the current cumulative like volume, the current cumulative comment volume, and the target video playback volume information in the most recent preset time period after the target video is uploaded. Among them, the most recent preset time period may be one or more. For example, the most recent preset time period may include: the most recent 1 hour, the most recent 4 hours, and the most recent 8 hours. The target video playback volume information in the most recent preset time period may include: the total playback volume and / or evaluation playback volume of the target video in the most recent preset time period.

[0061] Specifically, when the upload heat prediction result corresponding to the target video is a cold video, the target video can be transcoded using a preset cold video encoding method, and the transcoded video file can be sent to the viewer's terminal device so that the viewer can watch the target video. After the target video has been played for a period of time, the playback information of the target video can be collected and counted to obtain the dynamic information of the target video when the target video is currently played.

[0062] S350: Input the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determine a playback heat prediction result corresponding to the target video.

[0063] Among them, the preset playback heat prediction model can be a pre-set model for predicting the heat of the played video. For example, the preset playback heat prediction model can be a single prediction model, for example, the preset playback heat prediction model can be but not limited to a k-nearest neighbor prediction sub-model or a random forest prediction sub-model. The preset playback heat prediction model can also be a model that integrates multiple prediction sub-models. For example, the preset playback heat prediction model can be a model that integrates a k-nearest neighbor prediction sub-model and a random forest prediction sub-model. The preset playback heat prediction model used in this embodiment is a model that is pre-trained based on sample data. Among them, the sample data may include sample video dynamic information and sample video static information corresponding to the sample video and the playback heat standard result corresponding to the sample video. Among them, the playback heat standard result corresponding to the sample video can be determined based on the playback volume (i.e., viewing volume) of the sample video within 24 hours after the prediction time point. For example, when the playback volume of the sample video within 24 hours after the prediction time point is greater than or equal to the preset threshold, the playback heat standard result corresponding to the sample video is determined to be a hot video; when the playback volume of the sample video within 24 hours after the prediction time point is less than the preset threshold, the playback heat standard result corresponding to the sample video is determined to be a cold video. By using the above sample data to train the preset playback heat prediction model, a preset playback heat prediction model that can accurately predict the heat of a video when the video is playing is obtained.

[0064] Specifically, the target video dynamic information and the target video static information can be input into a trained preset playback heat prediction model in an input form recognizable by the model, such as a feature vector, to predict the heat during playback. The preset playback heat prediction model can directly output the playback heat prediction result corresponding to the target video, or it can output the predicted probability value that the target video is a hot video, and determine the final playback heat prediction result based on the predicted probability value. For example, if the output predicted probability value is greater than 0.5, it is determined that the playback heat prediction result corresponding to the target video is a hot video, otherwise it is a cold video.

[0065] S360: If the playback heat prediction result is a hot video, the target video is transcoded twice using a preset hot video encoding method.

[0066] Specifically, during the playback of the target video, if the target video is predicted to be a hot video, the target video can be transcoded twice using a preset hot video encoding method to obtain a video file with a lower video bit rate, so that when the video file is sent down again, the bandwidth consumption of the video transmission can be reduced, thereby reducing the bandwidth cost. This embodiment uses a preset playback heat prediction model to perform a secondary prediction of the video heat, so that hot videos that were not predicted when the video was uploaded can be predicted again, so that hot videos can be predicted more accurately, and the hot videos are transcoded twice using a preset hot video encoding method, further reducing the bandwidth consumption of the video transmission. In addition, the input information of the preset playback heat prediction model in this embodiment is multi-dimensional time series feature information, which can further improve the accuracy of video heat prediction.

[0067] For example, if the playback heat prediction result is a cold video, a new round of playback heat prediction can be performed by returning to execute the operation of step S340 until the target video is a hot video or the prediction stop time is reached.

[0068] The technical solution of this embodiment, after the uploaded heat prediction result is a cold video, the target video dynamic information and the target video static information when the target video is currently being played can be input into a preset playback heat prediction model to perform heat prediction during playback, determine the playback heat prediction result corresponding to the target video, and when the playback heat prediction result is a hot video, perform secondary transcoding on the target video using a preset hot video encoding method, so that hot videos that were not predicted when the video was uploaded can be predicted again, so that hot videos can be predicted more accurately, and the hot videos can be secondary transcoded using a preset hot video encoding method, further reducing the bandwidth consumption of video transmission.

[0069] Based on the above technical solution, the preset playback heat prediction model may include: at least two prediction sub-models; accordingly, step S350 may include: inputting the target video dynamic information and the target video static information into each prediction sub-model respectively to predict the heat during playback, and obtaining the prediction results output by each prediction sub-model; fusing the prediction results output by each prediction sub-model to determine the playback heat prediction result corresponding to the target video.

[0070] Specifically, the preset playback heat prediction model can be composed of at least two prediction sub-models. Similar to the method of obtaining prediction results by multi-tree voting in random forests, this embodiment can fuse the prediction results of at least two different types of prediction sub-models to obtain the final playback heat prediction result, thereby further improving the accuracy of heat prediction. For example, the final playback heat prediction result can be determined from each prediction result based on the determination method of minority obeys majority. Alternatively, the predicted probability value of the target video output by each prediction sub-model as a hot video can be averaged, and the playback heat prediction result can be determined based on the obtained average probability value. For example, if the average probability value is greater than 0.5, it is determined that the playback heat prediction result corresponding to the target video is a hot video, otherwise it is a cold video.

[0071] For example, Figure 4 An example of a preset playback popularity prediction model is given. Figure 4 As shown, the preset playback heat prediction model may include: a k-nearest neighbor prediction sub-model and a random forest prediction sub-model. By inputting the target video dynamic information and the target video static information into the k-nearest neighbor prediction sub-model and the random forest prediction sub-model respectively to predict the heat during playback, a first prediction result output by the k-nearest neighbor prediction sub-model and a second prediction result output by the random forest prediction sub-model are obtained, and the first prediction result and the second prediction result are fused to obtain the final playback heat prediction result, thereby further improving the accuracy of the prediction result.

[0072] Exemplarily, the prediction results output by each prediction sub-model are fused to determine the playback heat prediction result corresponding to the target video, which may include: weighted averaging the prediction probability values ​​output by each prediction sub-model that the target video is a hot video to obtain a processed target prediction probability value; based on the target prediction probability value, determine the playback heat prediction result corresponding to the target video.

[0073] Specifically, the predicted probability value output by each prediction sub-model corresponds to a weight value, which is used to characterize the importance of the prediction result of each preset sub-model, that is, the accuracy. In the process of presetting the playback heat prediction model, the weight value corresponding to each prediction sub-model can be trained to obtain an accurate weight value. In the use stage, the predicted probability values ​​of the target video as a hot video output by each prediction sub-model can be weighted averaged, and the obtained weighted average value is used as the target prediction probability value, and when the target prediction probability value is greater than 0.5, it can be determined that the playback heat prediction result corresponding to the target video is a hot video, otherwise it is a cold video. By assigning different weight values ​​to each prediction sub-model, the accuracy of the prediction result can be further improved.

[0074] On the basis of the above-mentioned technical solutions, before "obtaining the target video dynamic information when playing the target video" in step S340, it may also include: obtaining the target playback volume corresponding to the target video in the current time window; detecting whether the target video meets the preset heat basic condition based on the target playback volume; accordingly, "obtaining the target video dynamic information when playing the target video" in S340 may include: if the preset heat basic condition is met, obtaining the target video dynamic information when playing the target video.

[0075] The target playback volume may refer to the number of times the target video is viewed within the current time window. The preset heat basic condition may be a pre-set basic condition that a hot video needs to meet. For example, the preset heat basic condition may be set to a video playback volume within the current time window that is greater than or equal to a preset playback volume threshold.

[0076] Specifically, before performing a heat prediction during playback, you can first detect whether the target playback volume corresponding to the target video in the current time window meets the preset heat basic conditions, for example, whether the target playback volume is greater than or equal to the preset playback volume threshold. If so, it can be determined that the target video meets the preset heat basic conditions, and then subsequent heat prediction operations can be performed; if not, it indicates that the target video cannot be a hot video at present, and there is no need to perform heat prediction operations. At this time, you can obtain the target playback volume corresponding to the target video in the next time window until the target video meets the preset heat basic conditions. By using the preset heat basic conditions, you can perform a preliminary test on the heat of the video, further improving the detection efficiency and the accuracy of heat prediction.

[0077] Exemplarily, detecting whether the target video meets the preset basic conditions of popularity based on the target playback volume may include: determining the current playback volume threshold according to the cold video playback volume corresponding to each cold video currently existing in the current time window; if it is detected that the target playback volume is greater than or equal to the current playback volume threshold, it is determined that the target video meets the preset basic conditions of popularity.

[0078] Specifically, the cold video playback volume corresponding to each cold video (including the target video) currently existing in the current time window can be obtained, and the playback volumes of each cold video are arranged in descending order, and the preset number of target cold video playback volumes are obtained as the current playback volume threshold. When it is detected that the target playback volume is greater than or equal to the current playback volume threshold, it indicates that the target video is a video with a preset number of playbacks before, and it can be determined that the target video meets the preset heat basic condition. By using the current playback volume threshold determined in real time for detection, the current heat situation of the target video can be more accurately identified, thereby further improving the accuracy of heat prediction.

[0079] The following is an embodiment of a video transcoding device provided in an embodiment of the present disclosure. The device and the video transcoding method of the above embodiment belong to the same inventive concept. For details not described in detail in the embodiment of the video transcoding device, reference can be made to the video transcoding method of the above embodiment.

[0080] Embodiment 3

[0081] Figure 5 This is a schematic diagram of the structure of a video transcoding device provided in the third embodiment of the present disclosure. This embodiment is applicable to the case where a video uploaded by a user to a server is transcoded. Figure 5 As shown, the device specifically includes: a target video acquisition module 510, a target video static information determination module 520, an upload heat prediction module 530 and a hot video transcoding module 540.

[0082] Among them, the target video acquisition module 510 is used to obtain the newly uploaded target video; the target video static information determination module 520 is used to determine the target video static information corresponding to the target video; the upload heat prediction module 530 is used to input the target video static information into the preset upload heat prediction model to perform heat prediction during uploading, and determine the upload heat prediction result corresponding to the target video; the thermal video transcoding module 540 is used to transcode the target video using the preset thermal video encoding method if the upload heat prediction result is a hot video.

[0083] The technical solution of the disclosed embodiment determines the target video static information corresponding to the newly uploaded target video, and inputs the target video static information into a preset upload heat prediction model to perform heat prediction during uploading, determines the upload heat prediction result corresponding to the target video, and when the upload heat prediction result is a hot video, transcodes the target video using a preset thermal video encoding method with a lower video bit rate, thereby only transcoding the hot video using the preset thermal video encoding method, without setting up a large number of servers for computing power support, thereby not increasing the equipment cost, and by performing video heat prediction when the video is uploaded, there is no need to wait until the video is played to perform video heat prediction, thereby advancing the transcoding time of the hot video, further reducing the bandwidth consumption of video transmission, and reducing the video transmission cost.

[0084] On the basis of the above technical solution, the static information of the target video includes: at least one of the target video upload time point, the target video duration and the target video author information;

[0085] Based on the above technical solutions, the preset upload heat prediction model is: LightGBM tree model.

[0086] On the basis of the above technical solutions, the device also includes:

[0087] The cold video transcoding module is used to transcode the target video using a preset cold video encoding method if the uploaded heat prediction result is a cold video; wherein, when the video quality is the same, the video bit rate of the preset cold video encoding method is greater than the video bit rate of the preset hot video encoding method.

[0088] Based on the above technical solutions, the preset cold video encoding method is the H264 encoding method; the preset hot video encoding method is the H265 encoding method.

[0089] On the basis of the above technical solutions, the device also includes:

[0090] The target video dynamic information acquisition module is used to obtain the target video dynamic information when the target video is currently being played if the uploaded heat prediction result is a cold video;

[0091] The playback heat prediction module is used to input the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determine the playback heat prediction result corresponding to the target video;

[0092] The secondary transcoding module is used to perform secondary transcoding on the target video using a preset hot video encoding method if the playback heat prediction result is a hot video.

[0093] On the basis of the above technical solutions, the preset playback popularity prediction model includes: at least two prediction sub-models;

[0094] The upload heat prediction module 530 includes:

[0095] A prediction result determination unit, used to input the target video dynamic information and the target video static information into each prediction sub-model respectively to perform popularity prediction during playback, and obtain the prediction result output by each prediction sub-model;

[0096] The fusion processing determination unit is used to perform fusion processing on the prediction results output by each prediction sub-model to determine the playback heat prediction result corresponding to the target video.

[0097] On the basis of the above-mentioned technical solutions, the fusion processing determination unit is specifically used to: perform weighted averaging processing on the predicted probability values ​​of the target video being a hot video output by each prediction sub-model to obtain the processed target prediction probability value; based on the target prediction probability value, determine the playback heat prediction result corresponding to the target video.

[0098] Based on the above technical solutions, the preset playback popularity prediction model includes: a k-nearest neighbor prediction sub-model and a random forest prediction sub-model.

[0099] Based on the above technical solutions, the target video dynamic information includes: the current cumulative playback volume after the target video is uploaded, the current cumulative like volume, the current cumulative comment volume and at least one of the target video playback volume information in the recent preset time period.

[0100] On the basis of the above technical solutions, the device also includes:

[0101] A target playback volume acquisition module is used to acquire the target playback volume corresponding to the target video in the current time window before acquiring the target video dynamic information when playing the target video;

[0102] A target video detection module is used to detect whether the target video meets the preset popularity basic condition based on the target playback volume;

[0103] The target video dynamic information acquisition module is specifically used to obtain the target video dynamic information when playing the target video if the preset heat basic condition is met.

[0104] On the basis of the above-mentioned technical solutions, the target video detection module is specifically used to: determine the current playback volume threshold according to the cold video playback volume corresponding to each cold video currently existing in the current time window; if it is detected that the target playback volume is greater than or equal to the current playback volume threshold, it is determined that the target video meets the preset heat basic conditions.

[0105] The video transcoding device provided in the embodiments of the present disclosure can execute the video transcoding method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects for executing the video transcoding method.

[0106] It is worth noting that in the embodiment of the above-mentioned video transcoding device, the various units and modules included are only divided according to functional logic, but are not limited to the above-mentioned division, as long as the corresponding functions can be realized; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention.

[0107] Embodiment 4

[0108] Reference below Figure 6 , which shows a structural diagram of a server 900 suitable for implementing an embodiment of the present disclosure. Figure 6 The server 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.

[0109] like Figure 6As shown, the server 900 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 901, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 902 or a program loaded from a storage device 908 to a random access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the server 900 are also stored. The processing device 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.

[0110] Typically, the following devices may be connected to the I / O interface 905: input devices 906 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; output devices 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices 908 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 909. The communication devices 909 may allow the server 900 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 6 The server 900 is shown with various devices, but it should be understood that it is not required to implement or have all the devices shown. More or fewer devices may be implemented or have instead.

[0111] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 909, or installed from a storage device 908, or installed from a ROM 902. When the computer program is executed by the processing device 901, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.

[0112] The server provided in the embodiment of the present disclosure and the video transcoding method provided in the above embodiment belong to the same inventive concept. The technical details not fully described in the embodiment of the present disclosure can be referred to the above embodiment, and the embodiment of the present disclosure has the same beneficial effects as the above embodiment.

[0113] Embodiment 5

[0114] The embodiment of the present disclosure provides a computer storage medium on which a computer program is stored. When the program is executed by a processor, the video transcoding method provided by the above embodiment is implemented.

[0115] It should be noted that the computer-readable medium disclosed above 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 the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, 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.

[0116] 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.

[0117] The computer-readable medium may be included in the server, or may exist independently without being installed in the server.

[0118] The above-mentioned computer-readable medium carries one or more programs. When the above-mentioned one or more programs are executed by the server, the server: obtains the newly uploaded target video; determines the target video static information corresponding to the target video; inputs the target video static information into a preset upload heat prediction model to perform heat prediction during uploading, and determines the upload heat prediction result corresponding to the target video; if the upload heat prediction result is a hot video, transcodes the target video using a preset hot video encoding method.

[0119] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages ​​or a combination thereof, including, but not limited to, 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 through 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., through the Internet using an Internet service provider).

[0120] 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.

[0121] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a unit does not limit the unit itself in some cases. For example, an editable content display unit may also be described as an "editing unit".

[0122] 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.

[0123] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, 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 foregoing.

[0124] According to one or more embodiments of the present disclosure, [Example 1] provides a video transcoding method, including:

[0125] Get the newly uploaded target video;

[0126] Determine target video static information corresponding to the target video;

[0127] Inputting the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determining an upload heat prediction result corresponding to the target video;

[0128] If the uploaded heat prediction result is a hot video, the target video is transcoded using a preset hot video encoding method.

[0129] According to one or more embodiments of the present disclosure, [Example 2] provides a video transcoding method, further comprising:

[0130] Optionally, the target video static information includes: at least one of the target video upload time point, the target video duration and the target video author information.

[0131] According to one or more embodiments of the present disclosure, [Example 3] provides a video transcoding method, further comprising:

[0132] Optionally, the preset upload heat prediction model is: LightGBM tree model.

[0133] According to one or more embodiments of the present disclosure, [Example 4] provides a video transcoding method, further comprising:

[0134] Optionally, the method further includes:

[0135] If the upload heat prediction result is a cold video, transcoding the target video using a preset cold video encoding method;

[0136] Wherein, when the video quality is the same, the video bit rate of the preset cold video encoding method is greater than the video bit rate of the preset hot video encoding method.

[0137] According to one or more embodiments of the present disclosure, [Example 5] provides a video transcoding method, further comprising:

[0138] Optionally, the method further includes:

[0139] If the upload heat prediction result is a cold video, obtaining the target video dynamic information when the target video is currently being played;

[0140] Inputting the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determining a playback heat prediction result corresponding to the target video;

[0141] If the playback heat prediction result is a hot video, the target video is transcoded twice using the preset hot video encoding method.

[0142] According to one or more embodiments of the present disclosure, [Example 6] provides a video transcoding method, further comprising:

[0143] Optionally, the preset playback popularity prediction model includes: at least two prediction sub-models;

[0144] The step of inputting the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determining a playback heat prediction result corresponding to the target video, includes:

[0145] Inputting the target video dynamic information and the target video static information into each prediction sub-model respectively to predict the popularity during playback, and obtaining the prediction result output by each prediction sub-model;

[0146] The prediction results output by each prediction sub-model are fused to determine the playback popularity prediction result corresponding to the target video.

[0147] According to one or more embodiments of the present disclosure, [Example 7] provides a video transcoding method, further comprising:

[0148] Optionally, the step of fusing the prediction results output by each prediction sub-model to determine the playback popularity prediction result corresponding to the target video includes:

[0149] Performing weighted average processing on the predicted probability values ​​of the target video being a hot video output by each of the prediction sub-models to obtain a processed target predicted probability value;

[0150] Based on the target prediction probability value, determine the playback popularity prediction result corresponding to the target video.

[0151] According to one or more embodiments of the present disclosure, [Example 8] provides a video transcoding method, further comprising:

[0152] Optionally, the preset playback popularity prediction model includes: a k-nearest neighbor prediction sub-model and a random forest prediction sub-model.

[0153] According to one or more embodiments of the present disclosure, [Example 9] provides a video transcoding method, further comprising:

[0154] Optionally, the target video dynamic information includes: at least one of the current cumulative number of views of the target video after it is uploaded, the current cumulative number of likes, the current cumulative number of comments, and the target video view volume information within a recent preset time period.

[0155] According to one or more embodiments of the present disclosure, [Example 10] provides a video transcoding method, further comprising:

[0156] Optionally, before acquiring the target video dynamic information when playing the target video, the method further includes:

[0157] Obtain the target playback volume corresponding to the target video in the current time window;

[0158] Detecting whether the target video meets a preset popularity basic condition based on the target playback volume;

[0159] The acquiring of target video dynamic information when playing the target video includes:

[0160] If the preset heat basic condition is met, the target video dynamic information when the target video is played is obtained.

[0161] According to one or more embodiments of the present disclosure, [Example 11] provides a video transcoding method, further comprising:

[0162] Optionally, the detecting whether the target video meets a preset popularity basic condition based on the target playback volume includes:

[0163] Determine a current playback volume threshold value according to the cold video playback volume corresponding to each cold video currently existing in the current time window;

[0164] If it is detected that the target playback volume is greater than or equal to the current playback volume threshold, it is determined that the target video meets the preset popularity basic condition.

[0165] According to one or more embodiments of the present disclosure, [Example 12] provides a video transcoding device, including:

[0166] The target video acquisition module is used to acquire the newly uploaded target video;

[0167] A target video static information determination module, used to determine the target video static information corresponding to the target video;

[0168] An upload heat prediction module, used to input the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determine an upload heat prediction result corresponding to the target video;

[0169] The thermal video transcoding module is used to transcode the target video using a preset thermal video encoding method if the uploaded heat prediction result is a thermal video.

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

[0171] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.

[0172] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.

Claims

1. A video transcoding method, characterized in that: include: Get the newly uploaded target video; Determine target video static information corresponding to the target video, wherein the target video static information is static feature information of the target video itself; Inputting the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determining an upload heat prediction result corresponding to the target video; If the uploaded heat prediction result is a hot video, transcoding the target video using a preset hot video encoding method; If the upload heat prediction result is a cold video, obtaining the target video dynamic information when the target video is currently being played; Inputting the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determining a playback heat prediction result corresponding to the target video; If the playback heat prediction result is a hot video, the target video is transcoded twice using the preset hot video encoding method.

2. The method according to claim 1, characterized in that The target video static information includes: at least one of the target video upload time point, the target video duration and the target video author information.

3. The method according to claim 1, characterized in that The preset upload heat prediction model is: LightGBM tree model.

4. The method according to claim 1, characterized in that The preset playback popularity prediction model includes: at least two prediction sub-models; The step of inputting the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determining a playback heat prediction result corresponding to the target video, includes: Inputting the target video dynamic information and the target video static information into each prediction sub-model respectively to predict the popularity during playback, and obtaining the prediction result output by each prediction sub-model; The prediction results output by each prediction sub-model are fused to determine the playback popularity prediction result corresponding to the target video.

5. The method according to claim 4, characterized in that The step of fusing the prediction results output by each prediction sub-model to determine the playback popularity prediction result corresponding to the target video includes: Performing weighted average processing on the predicted probability values ​​of the target video being a hot video output by each of the prediction sub-models to obtain a processed target predicted probability value; Based on the target prediction probability value, determine the playback popularity prediction result corresponding to the target video.

6. The method according to claim 1, characterized in that The preset playback popularity prediction model includes: a k-nearest neighbor prediction sub-model and a random forest prediction sub-model.

7. The method according to claim 1, characterized in that The target video dynamic information includes: the current cumulative playback volume of the target video after uploading, the current cumulative like volume, the current cumulative comment volume and at least one of the target video playback volume information in the most recent preset time period.

8. The method according to claim 1, characterized in that Before obtaining the target video dynamic information when playing the target video, the method further includes: Obtain the target playback volume corresponding to the target video in the current time window; Detecting whether the target video meets a preset popularity basic condition based on the target playback volume; The acquiring of target video dynamic information when playing the target video includes: If the preset heat basic condition is met, the target video dynamic information when the target video is played is obtained.

9. The method according to claim 8, characterized in that The detecting whether the target video meets a preset popularity basic condition based on the target playback volume includes: Determine a current playback volume threshold value according to the cold video playback volume corresponding to each cold video currently existing in the current time window; If it is detected that the target playback volume is greater than or equal to the current playback volume threshold, it is determined that the target video meets the preset popularity basic condition.

10. A video transcoding device, characterized in that: include: The target video acquisition module is used to acquire the newly uploaded target video; A target video static information determination module, used to determine the target video static information corresponding to the target video, wherein the target video static information is static feature information of the target video itself; An upload heat prediction module, used to input the static information of the target video into a preset upload heat prediction model to perform heat prediction during uploading, and determine an upload heat prediction result corresponding to the target video; A thermal video transcoding module, used for transcoding the target video using a preset thermal video encoding method if the uploaded heat prediction result is a thermal video; The target video dynamic information acquisition module is used to obtain the target video dynamic information when the target video is currently being played if the uploaded heat prediction result is a cold video; The playback heat prediction module is used to input the target video dynamic information and the target video static information into a preset playback heat prediction model to perform heat prediction during playback, and determine the playback heat prediction result corresponding to the target video; The secondary transcoding module is used to perform secondary transcoding on the target video using a preset hot video encoding method if the playback heat prediction result is a hot video.

11. A server, characterized in that: The server comprises: one or more processors; A memory for storing one or more programs; When the one or more programs are executed by the one or more processors, the one or more processors implement the video transcoding method as described in any one of claims 1-9.

12. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the video transcoding method as described in any one of claims 1 to 9 is implemented.

Citation Information

Patent Citations

  • Video processing method, device and equipment and storage medium

    CN112492351A

  • Video transcoding method and device, equipment and medium

    CN112954354A