CN112040333A - Video distribution method, device, terminal and storage medium - Google Patents

Video distribution method, device, terminal and storage medium Download PDF

Info

Publication number
CN112040333A
CN112040333A CN202010923226.4A CN202010923226A CN112040333A CN 112040333 A CN112040333 A CN 112040333A CN 202010923226 A CN202010923226 A CN 202010923226A CN 112040333 A CN112040333 A CN 112040333A
Authority
CN
China
Prior art keywords
transcoding
video file
target
video
determining
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010923226.4A
Other languages
Chinese (zh)
Other versions
CN112040333B (en
Inventor
耿玉峰
周超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202010923226.4A priority Critical patent/CN112040333B/en
Publication of CN112040333A publication Critical patent/CN112040333A/en
Application granted granted Critical
Publication of CN112040333B publication Critical patent/CN112040333B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/637Control signals issued by the client directed to the server or network components
    • H04N21/6373Control signals issued by the client directed to the server or network components for rate control, e.g. request to the server to modify its transmission rate
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/637Control signals issued by the client directed to the server or network components
    • H04N21/6377Control signals issued by the client directed to the server or network components directed to server
    • H04N21/6379Control signals issued by the client directed to the server or network components directed to server directed to encoder, e.g. for requesting a lower encoding rate
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/65Transmission of management data between client and server
    • H04N21/654Transmission by server directed to the client
    • H04N21/6547Transmission by server directed to the client comprising parameters, e.g. for client setup

Landscapes

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

Abstract

The disclosure provides a video publishing method, a video publishing device, a video publishing terminal and a storage medium, and relates to the technical field of internet. The method comprises the following steps: determining a plurality of transcoding parameter sets in response to a publishing instruction of the first video file; determining a plurality of groups of transcoding time lengths and uploading time lengths according to the network transmission parameters and the plurality of transcoding parameter sets of the terminal; determining a target transcoding parameter set based on the multiple groups of transcoding time lengths and uploading time lengths, wherein the target transcoding parameter set is a transcoding parameter set which corresponds to the condition that the sum of the transcoding time lengths and the uploading time lengths meets the condition; transcoding the first video file according to the target transcoding parameter set to obtain a second video file; and uploading the second video file, so that the publishing process of the video file can be optimized by combining various publishing conditions in the publishing process, the publishing time of the video file is shortened, and the publishing efficiency of the video file is improved.

Description

Video distribution method, device, terminal and storage medium
Technical Field
The present disclosure relates to the field of internet technologies, and in particular, to a video distribution method, apparatus, terminal, and storage medium.
Background
With the development of internet technology, short video applications become one of the most explosive applications, and users can create and share short videos through the short video applications. In order to ensure that a new short video can be supplemented in time in a short video application program, video creators need to keep enthusiasm for publishing the short video, and an important factor influencing the enthusiasm for the creators to publish the short video is time consumption for publishing the short video.
In the related art, when a short video is released in a short video application program, the short video needs to be transcoded first, and the transcoded short video is uploaded to a server.
In the related art, transcoding and uploading the short video takes a long time in the process of distributing the short video, which results in low efficiency of distributing the short video.
Disclosure of Invention
The embodiment of the disclosure provides a video publishing method, a video publishing device, a terminal and a storage medium, which can improve the publishing efficiency of videos. The technical scheme is as follows:
according to an aspect of the embodiments of the present disclosure, there is provided a video distribution method, including:
determining a plurality of transcoding parameter sets in response to a publishing instruction of the first video file;
determining multiple groups of transcoding time lengths and uploading time lengths according to network transmission parameters of a terminal and the multiple transcoding parameter groups, wherein one group of transcoding time length and uploading time length is respectively used for representing the time length consumed by transcoding the first video file by applying a corresponding transcoding parameter group and the time length consumed by uploading the first video file to a server based on the network transmission parameters;
determining a target transcoding parameter set based on the multiple groups of transcoding time lengths and the uploading time length, wherein the target transcoding parameter set is a transcoding parameter set which corresponds to the condition that the sum of the transcoding time length and the uploading time length meets the condition;
transcoding the first video file according to the target transcoding parameter set to obtain a second video file;
and uploading the second video file.
In a possible implementation manner, the determining multiple sets of transcoding durations and uploading durations according to the network transmission parameters of the terminal and the multiple sets of transcoding parameters includes:
for each transcoding parameter set, acquiring a target transcoding rate corresponding to the transcoding mode according to the transcoding mode included in the transcoding parameter set, wherein the target transcoding rate is the rate of transcoding a video file by the terminal through the transcoding mode; determining the ratio of the file duration of the first video file to the target transcoding rate as the transcoding duration; and the number of the first and second groups,
for each transcoding parameter group, determining a data volume corresponding to the first video file based on the transcoding parameter group, wherein the data volume is a predicted data volume of a third video file obtained by transcoding the first video file through the transcoding parameter group; and determining the uploading time according to the data volume and the network transmission parameters.
In another possible implementation manner, before the obtaining, according to the transcoding manner included in the transcoding parameter set, the target transcoding rate corresponding to the transcoding manner, the method further includes:
responding to the terminal to transcode the video file for the first time, and performing transcoding test on multiple transcoding modes to obtain the transcoding rate of the terminal for transcoding the video file through each transcoding mode;
and storing the transcoding rate corresponding to each transcoding mode.
In another possible implementation manner, each transcoding parameter group comprises a transcoding manner and parameter information;
the determining a plurality of transcoding parameter sets comprises:
determining a plurality of transcoding modes, and determining the parameter information according to the video content of the first video file;
and respectively combining the parameter information and each transcoding mode to form a transcoding parameter set.
In another possible implementation manner, the parameter information includes a target definition and a target transcoding code rate;
the determining the parameter information according to the video content of the first video file includes:
determining a target definition according to the original definition of the first video file, wherein the target definition is the lowest definition of the first video file after transcoding;
determining the target transcoding code rate according to the video content of the first video file and the target definition;
and the target definition and the target transcoding code rate form the parameter information.
In another possible implementation manner, the determining the target transcoding bitrate according to the video content of the first video file and the target definition includes:
performing feature extraction on the video content of the first video file to obtain the image feature of the video content;
determining content information of the first video file according to the image characteristics of the video content;
determining image feature difference between each frame of video to obtain difference information between each frame of video;
and determining a target transcoding code rate matched with the content information and the difference information under the target definition according to the content information, the difference information and the target definition of the first video file.
In another possible implementation manner, the determining the target transcoding bitrate according to the video content of the first video file and the target definition includes:
and inputting the video content of the first video file and the target definition into a transcoding code rate determination model to obtain the target transcoding code rate.
In another possible implementation manner, before the determining the model of the transcoding code rate for inputting the video content of the first video file and the target definition and obtaining the target transcoding code rate, the method further includes:
acquiring a sample video file and a transcoding code rate determination model to be trained, wherein the sample video file is a video file marked with definition and transcoding code rate of the video file;
and performing model training on the transcoding code rate determination model to be trained according to the definition and the transcoding code rate of the sample video file to obtain the transcoding code rate determination model.
According to another aspect of the embodiments of the present disclosure, there is provided a video distribution apparatus including:
a parameter group determination unit configured to perform determining a plurality of transcoding parameter groups in response to an issuance instruction of the first video file;
the time length determining unit is configured to execute determining multiple groups of transcoding time lengths and uploading time lengths according to network transmission parameters of the terminal and the multiple transcoding parameter groups, wherein one group of transcoding time lengths and uploading time lengths are respectively used for representing the time length consumed by transcoding the first video file by applying the corresponding transcoding parameter group and the time length consumed by uploading the first video file to the server based on the network transmission parameters;
a target parameter set determining unit configured to determine a target transcoding parameter set based on the multiple groups of transcoding time lengths and the uploading time length, wherein the target transcoding parameter set is a transcoding parameter set of which the sum of the corresponding transcoding time length and the uploading time length meets the condition;
the transcoding unit is configured to transcode the first video file according to the target transcoding parameter group to obtain a second video file;
an upload unit configured to perform uploading the second video file.
In a possible implementation manner, the duration determining unit includes:
the first determining subunit is configured to execute, for each transcoding parameter group, acquiring a target transcoding rate corresponding to the transcoding mode according to the transcoding mode included in the transcoding parameter group, where the target transcoding rate is a rate of transcoding a video file by the terminal through the transcoding mode; determining the ratio of the file duration of the first video file to the target transcoding rate as the transcoding duration; and the number of the first and second groups,
the second determining subunit is configured to determine, for each transcoding parameter group, a data size corresponding to the first video file based on the transcoding parameter group, where the data size is a predicted data size of a third video file obtained by transcoding the first video file by the transcoding parameter group; and determining the uploading time according to the data volume and the network transmission parameters.
In another possible implementation manner, the apparatus further includes:
the transcoding test unit is configured to respond to the terminal to transcode the video file for the first time, execute transcoding test on multiple transcoding modes and obtain the transcoding rate of the terminal for transcoding the video file through each transcoding mode;
and the storage unit is configured to store the transcoding rate corresponding to each transcoding mode.
In another possible implementation manner, each transcoding parameter group comprises a transcoding manner and parameter information;
the parameter group determination unit includes:
a third determining subunit, configured to perform determining multiple transcoding modes, and determine the parameter information according to the video content of the first video file;
and the composition subunit is configured to perform composition of the parameter information and each transcoding mode into one transcoding parameter group.
In another possible implementation manner, the parameter information includes a target definition and a target transcoding code rate;
the third determining subunit is configured to determine a target definition according to the original definition of the first video file, where the target definition is the lowest definition of the first video file after transcoding; determining the target transcoding code rate according to the video content of the first video file and the target definition; and the target definition and the target transcoding code rate form the parameter information.
In another possible implementation manner, the third determining subunit is configured to perform feature extraction on the video content of the first video file to obtain an image feature of the video content; determining content information of the first video file according to the image characteristics of the video content; determining image feature difference between each frame of video to obtain difference information between each frame of video; and determining a target transcoding code rate matched with the content information and the difference information under the target definition according to the content information, the difference information and the target definition of the first video file.
In another possible implementation manner, the third determining subunit is configured to execute a transcoding code rate determining model for inputting the video content of the first video file and the target definition, so as to obtain the target transcoding code rate.
In another possible implementation manner, the apparatus further includes:
the system comprises an acquisition unit, a transcoding unit and a transcoding unit, wherein the acquisition unit is configured to execute acquisition of a sample video file and a transcoding code rate determination model to be trained, and the sample video file is a video file marked with definition and transcoding code rate of the video file;
and the model training unit is configured to perform model training on the transcoding code rate determination model to be trained according to the definition and the transcoding code rate of the sample video file to obtain the transcoding code rate determination model.
According to another aspect of the embodiments of the present disclosure, there is provided a terminal, where the terminal includes a processor and a memory, where at least one program code is stored in the memory, and the at least one program code is loaded and executed by the processor to implement the video distribution method according to any one of the foregoing possible implementation manners.
According to another aspect of the embodiments of the present disclosure, there is provided a computer-readable storage medium having at least one program code stored therein, where the at least one program code is loaded and executed by a processor to implement the video distribution method according to any one of the above-mentioned possible implementation manners.
According to another aspect of the embodiments of the present disclosure, there is provided a computer program product or a computer program, the computer program product or the computer program including computer program code, the computer program code being stored in a computer-readable storage medium, the computer program code being read by a processor of a computer apparatus from the computer-readable storage medium, the computer program code being executed by the processor, so that the computer apparatus performs the operations performed in the above-described video distribution method.
In the embodiment of the disclosure, when the first video file is published, the target transcoding parameter set used for publishing the first video file is determined by predicting the transcoding time length and the uploading time length, so that the publishing process of the video file can be optimized by combining various publishing conditions in the publishing process, the publishing time length of the video file is reduced, and the publishing efficiency of the video file is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present disclosure, and it is obvious for those skilled in the art to obtain other drawings based on the drawings without creative efforts.
Fig. 1 is a schematic diagram of an implementation environment of a video distribution method design according to an exemplary embodiment;
FIG. 2 is a flow diagram of a method for video distribution provided in accordance with an exemplary embodiment;
FIG. 3 is a flow diagram of a method for video distribution provided in accordance with an exemplary embodiment;
FIG. 4 is a flow diagram of a method for video distribution provided in accordance with an exemplary embodiment;
FIG. 5 is a block diagram of a video distribution apparatus provided in accordance with an exemplary embodiment;
FIG. 6 is a block diagram of a video distribution apparatus provided in accordance with an exemplary embodiment;
fig. 7 is a schematic structural diagram of a terminal according to an exemplary embodiment.
Detailed Description
To make the objects, technical solutions and advantages of the present disclosure more apparent, embodiments of the present disclosure will be described in detail with reference to the accompanying drawings.
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
Fig. 1 is a schematic diagram of an implementation environment related to a video distribution method according to an exemplary embodiment. Referring to fig. 1, the implementation environment includes: a terminal 101 and a server 102. The terminal 101 and the server 102 perform data interaction through a wireless network.
The terminal 101 is installed with a target application program, and the acquired video file can be edited by the target application program to obtain a first video file to be uploaded. In response to receiving the video uploading instruction, the first video file is transcoded, and the transcoded second video file is uploaded to the server 102. The server 102 issues the received second video file to the other terminals 101, so that the other terminals 101 can play the second video file, and the video file is shared.
The target application program is any application program with a video editing function and an uploading function. For example, the target application is a short video application, a video playback application, and the like. In the embodiments of the present disclosure, the target application is not particularly limited.
Fig. 2 is a flowchart of a video distribution method according to an exemplary embodiment. As shown in fig. 2, the method comprises the steps of:
in step S201, a plurality of transcoding parameter sets is determined in response to an instruction to issue a first video file.
In step S202, according to the network transmission parameter of the terminal and the plurality of transcoding parameter sets, a plurality of sets of transcoding durations and uploading durations are determined, where a set of transcoding durations and uploading durations are respectively used to indicate a duration consumed by transcoding the first video file by applying the corresponding transcoding parameter set and a duration consumed by uploading the first video file to the server based on the network transmission parameter.
In step S203, a target transcoding parameter set is determined based on the multiple groups of transcoding durations and the uploading duration, where the target transcoding parameter set is a transcoding parameter set whose sum of the corresponding transcoding duration and the uploading duration satisfies a condition.
In step S204, the first video file is transcoded according to the target transcoding parameter set to obtain a second video file.
In step S205, the second video file is uploaded.
In one possible implementation manner, the determining multiple sets of transcoding durations and uploading durations according to the network transmission parameters of the terminal and the multiple sets of transcoding parameters includes:
for each transcoding parameter set, acquiring a target transcoding rate corresponding to the transcoding mode according to the transcoding mode included in the transcoding parameter set, wherein the target transcoding rate is the rate of transcoding a video file by the terminal through the transcoding mode; determining the ratio of the file duration of the first video file to the target transcoding rate as the transcoding duration; and the number of the first and second groups,
for each transcoding parameter group, determining a data volume corresponding to the first video file based on the transcoding parameter group, wherein the data volume is a predicted data volume of a third video file obtained by transcoding the first video file through the transcoding parameter group; and determining the uploading time length according to the data volume and the network transmission parameter.
In another possible implementation manner, before the obtaining the target transcoding rate corresponding to the transcoding manner according to the transcoding manner included in the transcoding parameter set, the method further includes:
responding to the terminal to carry out video file transcoding for the first time, and carrying out transcoding test on multiple transcoding modes to obtain the transcoding rate of the terminal for carrying out video file transcoding through each transcoding mode;
and storing the transcoding rate corresponding to each transcoding mode.
In another possible implementation manner, each transcoding parameter group comprises a transcoding manner and parameter information;
the determining a plurality of transcoding parameter sets comprises:
determining a plurality of transcoding modes, and determining the parameter information according to the video content of the first video file;
and respectively combining the parameter information with each transcoding mode to form a transcoding parameter set.
In another possible implementation, the parameter information includes a target definition and a target transcoding code rate;
the determining the parameter information according to the video content of the first video file includes:
determining a target definition according to the original definition of the first video file, wherein the target definition is the lowest definition of the first video file after transcoding;
determining the target transcoding code rate according to the video content of the first video file and the target definition;
and the target definition and the target transcoding code rate form the parameter information.
In another possible implementation manner, the determining the target transcoding bitrate according to the video content of the first video file and the target definition includes:
extracting the characteristics of the video content of the first video file to obtain the image characteristics of the video content;
determining the content information of the first video file according to the image characteristics of the video content;
determining image feature difference between each frame of video to obtain difference information between each frame of video;
and determining a target transcoding code rate matched with the content information and the difference information under the target definition according to the content information, the difference information and the target definition of the first video file.
In another possible implementation manner, the determining the target transcoding bitrate according to the video content of the first video file and the target definition includes:
and inputting the video content of the first video file and the target definition into a transcoding code rate determination model to obtain the target transcoding code rate.
In another possible implementation manner, before the determining the model of the transcoding bitrate of the video content of the first video file and the target definition is obtained, the method further includes:
acquiring a sample video file and a transcoding code rate determination model to be trained, wherein the sample video file is a video file marked with definition and transcoding code rate of the video file;
and performing model training on the transcoding code rate determination model to be trained according to the definition and the transcoding code rate of the sample video file to obtain the transcoding code rate determination model.
In the embodiment of the disclosure, when the first video file is published, the target transcoding parameter set used for publishing the first video file is determined by predicting the transcoding time length and the uploading time length, so that the publishing process of the video file can be optimized by combining various publishing conditions in the publishing process, the publishing time length of the video file is reduced, and the publishing efficiency of the video file is improved.
Fig. 3 is a flowchart of a video distribution method according to an exemplary embodiment. As shown in fig. 3, the method comprises the steps of:
in step S301, in response to an instruction to issue a first video file, the terminal determines a plurality of transcoding modes.
Generally, after a terminal collects a video file, a user edits the video file through the terminal, and after the editing is completed, the user triggers a video publishing button, and correspondingly, in response to the terminal detecting that the video publishing button is triggered, a publishing instruction of a first video file is determined to be received.
The multiple transcoding modes comprise at least two of soft coding modes, hard coding modes or transcoding-free transcoding modes. In the embodiment of the disclosure, the target application program in the terminal can be transcoded by any one of a plurality of transcoding methods. Correspondingly, in the development process of the target application program, a software developer writes implementation plug-ins of various transcoding modes into the target application program. In this step, the terminal determines a plurality of transcoding modes that the terminal can implement.
The video file editing operation includes editing operations such as adding background music and video special effects, and in the embodiment of the disclosure, the editing process is not specifically limited. By transcoding the first video file, the user-edited content can be applied to the first video file. Moreover, the volume of the first video file is properly compressed, so that the volume of the first video file is smaller on the premise of ensuring that the first video file has enough resolution and definition, time consumption in the uploading process is saved, the pressure of network bandwidth is relieved, and the storage pressure on a server can be relieved.
In step S302, the terminal determines parameter information according to the video content of the first video file.
The parameter information comprises target definition, target transcoding code rate and the like. Wherein the target definition is the lowest definition of the first video file after transcoding; the target transcoding code rate is a sampling frequency for sampling the first video file in the transcoding process.
In the step, the target definition of the first video file is determined according to the definition of the first video file, and the target transcoding code rate is determined on the premise that the definition of the transcoded first video file is not lower than the target definition. The process is realized by the following steps (1) to (3), and comprises the following steps:
(1) and the terminal determines the definition of the target according to the original definition of the first video file.
Optionally, the terminal determines the target definition of the first video file from the corresponding relationship between the original definition and the target definition according to the original definition of the first video file. Or the terminal divides different definition areas according to different definitions, and each definition area corresponds to one target definition, wherein the target definition is the lowest definition corresponding to each definition area. The terminal determines the original definition of the first video file, determines the definition region where the original definition is located, and further determines the target definition corresponding to the definition region.
It should be noted that the terminal is also capable of determining the target definition without the original definition of the first video file. For example, if the terminal determines the default definition of the system as the target definition, the terminal determines the default definition as the target definition for the first video file of any original definition.
(2) And the terminal determines the target transcoding code rate according to the video content of the first video file and the target definition.
Referring to fig. 4, the video content refers to video content composed of a plurality of video frames of the first video file. Optionally, the multiple frames of video frames are key frames of the first video file; or the multi-frame video frames are all video frames of the first video file; or the multi-frame video frame is a plurality of frames of video frames which are piled and selected in the first video file.
In a possible implementation manner, the terminal determines a target bitrate corresponding to the first video file according to the image characteristics and the target definition of the video content. The process is realized by the following steps (2-1) - (2-4), and comprises the following steps:
and (2-1) the terminal performs feature extraction on the video content of the first video file to obtain the image feature of the video content.
In this step, the terminal respectively performs image recognition on the multiple frames of video frames of the first video file, extracts the image features of the multiple frames of video frames, and combines the image features of the multiple frames of video frames into the image features of the video content.
And (2-2) the terminal determines the content information of the first video file according to the image characteristics of the video content.
The content information is image content corresponding to image features of the video content and is used for representing the complexity of the first video file. For example, the content information is the number of target objects in the video content, the color of the target objects, or the difference between the target objects, etc.
And (2-3) the terminal determines the image characteristic difference between each frame of video to obtain the difference information between each frame of video.
The difference information is an image characteristic difference between each frame of video frame of the first video file and is used for representing the change degree of the first video file. For example, the difference information is the sum of the information amounts of the image characteristic differences between adjacent video frames in the multi-frame video frames of the first video file, and the like.
And (2-4) the terminal determines a target transcoding code rate matched with the content information and the difference information under the target definition according to the content information, the difference information and the target definition of the first video file.
And the terminal determines the target transcoding code rate of the first video file through any algorithm. For example, the terminal determines a target transcoding rate of the first video file through a Content Aware Processing & Encoding (cap) algorithm. Under the same target definition, the target transcoding code rate of the first video file is positively correlated with the information quantity of the content information and the information quantity of the difference information of the first video file. Wherein the information amount of the content information is positively correlated with the number of target objects in the video content, the color of the target objects, or the difference between the target objects. The amount of information of the difference information is proportional to the difference in image characteristics between each frame of video in the first video file.
For example, in a first video file with a video content of the sky, content information of the first video file is a characteristic of the sky, the content is relatively single, and the change of the sky is small, so that both the information amount of the content information and the information amount of the difference information of the first video file with the video content of the sky are low, and a low transcoding code rate is determined as a target transcoding code rate. And for the first video file with the video content of the football match, the video content of the first video file comprises the players, audiences and the like which currently play the football match, and the video content in the first video file is a match picture, and the video content changes frequently, so that the information content of the content information and the information content of the difference information of the first video file with the video content of the football match are both high, and the high transcoding code rate is determined as the target transcoding code rate.
In the implementation mode, the target transcoding code rate of the first video file is determined by analyzing the image characteristics of the first video file, so that the target transcoding code rate of the first video file is ensured to be suitable for the transcoding code rate of the first video file, and the accuracy of the transcoding code rate is further ensured.
In another possible implementation manner, the terminal inputs the video content of the first video file and the target definition into a transcoding code rate determination model to obtain the target transcoding code rate. The transcoding code rate determination model is a model used for determining the transcoding code rate suitable for the video file according to the target definition.
Before this step, a model needs to be trained, and the process of training the model comprises the following steps (A1) - (A2):
(A1) the method comprises the steps that a terminal obtains a sample video file and a transcoding code rate determination model to be trained, wherein the sample video file is a video file marked with definition and transcoding code rate of the video file.
The sample video files comprise video files before transcoding and video files after transcoding, and the video sample video files are marked according to the definition of the video files after transcoding and the transcoding code rate in the transcoding process. Optionally, the definition of the video file adopts any definition labeling manner, and in the embodiment of the present disclosure, the definition labeling manner of the video file is not specifically limited. For example, the definition evaluation is performed using a VMAF (video multi-method Assessment Fusion) value, and the video file is labeled according to the evaluation result.
(A2) And the terminal performs model training on the transcoding code rate determination model to be trained according to the definition and the transcoding code rate of the sample video file to obtain the transcoding code rate determination model.
The sample video file is input into the transcoding code rate determining model to be trained, so that the transcoding code rate determining model to be trained can learn the image characteristics and the required definition of different video files according to the sample video file and determine different transcoding code rates.
In the implementation mode, the transcoding code rate of the video file is determined through the transcoding code rate determination model, the speed of determining the transcoding code rate is increased, and the transcoding efficiency of the video file is further increased.
It should be noted that the model training process may also be performed by other electronic devices. Correspondingly, the terminal sends a model obtaining request to other electronic equipment, the other electronic equipment receives the model obtaining request, obtains a transcoding code rate determining model according to the model obtaining request, sends the transcoding code rate determining model to the terminal, and the terminal receives the transcoding code rate determining model. The process of training the transcoding code rate determination model by other electronic devices is similar to the process of training the transcoding code rate determination model by the terminal, and is not repeated here.
(3) And the terminal combines the target definition and the target transcoding code rate into the parameter information.
In the implementation mode, the terminal determines the target transcoding code rate of the first video file by sensing the video content and the target definition of the first video file so as to predict the transcoding time length of the first video file subsequently.
In step S303, the terminal combines the parameter information with each transcoding method to form a transcoding parameter set.
Each transcoding parameter group comprises a transcoding mode and parameter information. And the terminal combines the parameter information with each transcoding mode respectively to obtain a plurality of transcoding parameter groups.
In step S304: and for each transcoding parameter group, the terminal acquires a target transcoding rate corresponding to the transcoding mode according to the transcoding mode included in the transcoding parameter group.
Referring to fig. 4, the target transcoding rate is a rate at which the terminal transcodes the video file by the transcoding method, that is, a duration of the transcoded video file in unit time. Alternatively, the transcoding rates of different transcoding methods may be the same or different for the same video file. In the embodiments of the present disclosure, this is not particularly limited.
In a possible implementation manner, when the terminal transcodes the first video file, the hardware parameters of the terminal are obtained, and according to the hardware parameters of the terminal, the transcoding test is performed on the first video file through the transcoding manner corresponding to the transcoding parameter set, so as to obtain the transcoding rate corresponding to the transcoding parameter set. In the implementation mode, the terminal predicts the transcoding rate of the first video file, and the accuracy of the determined transcoding rate is guaranteed.
In another possible implementation manner, a plurality of transcoding manners and a transcoding rate corresponding to each transcoding manner are stored in the terminal, and a locally stored transcoding rate corresponding to the transcoding manner is obtained according to the transcoding manner corresponding to the transcoding parameter set. Correspondingly, before the step, when the terminal transcodes the video file for the first time, the terminal is transcoded according to the hardware parameters of the terminal to obtain the transcoding rate of the terminal in each transcoding mode, and the transcoding rate is stored locally. The process is realized by the following steps (1) to (2), and comprises the following steps:
(1) and responding to the terminal to transcode the video file for the first time, and performing transcoding test on multiple transcoding modes to obtain the transcoding rate of the terminal for transcoding the video file through each transcoding mode.
The terminal transcodes the video file according to each transcoding mode, the transcoding time for transcoding the video file by each transcoding mode is counted, and the ratio of the file time of the video file to the transcoding time of each transcoding mode is determined as the transcoding rate of the terminal in the transcoding mode.
(2) And the terminal stores the transcoding rate corresponding to each transcoding mode.
In this step, the terminal stores the transcoding rate of each transcoding mode locally, or the terminal binds the transcoding rate with the terminal identifier of the terminal and stores the transcoding rate bound with the terminal identifier into the database. In the embodiment of the present disclosure, a storage manner of the transcoding rate is not specifically limited.
It should be noted that, in response to the terminal storing the transcoding rate of each transcoding method locally, the terminal obtains the locally stored transcoding rate through a data interface local to the terminal. And responding to the terminal to store the transcoding rate of each transcoding mode in the database, and acquiring the current transcoding rate of each transcoding of the current terminal from the database by the terminal according to the terminal identifier of the current terminal.
Another point to be described is that, in this implementation, in response to that the first video file to be published is a video file that is published by the terminal for the first time, the terminal performs a transcoding test on the terminal according to the first video file, stores a test result in the local, and determines the test result as a transcoding rate corresponding to each transcoding mode.
In the implementation mode, the terminal determines the transcoding rate of each transcoding mode in advance, so that the terminal can directly acquire the transcoding rate when transcoding the video file, the efficiency is improved, the publishing efficiency of the video file is improved, and the transcoding test is only performed in the process of publishing the video file for the first time, so that the influence of the transcoding test on the publishing process is reduced, and the occupation of terminal resources is reduced, and the smoothness of the terminal is guaranteed.
In step S305, the terminal determines a ratio of the file duration of the first video file and the target transcoding rate as the transcoding duration.
The transcoding duration is used for representing the duration consumed by transcoding the first video file by applying the corresponding transcoding parameter set.
In the implementation mode, the terminal predicts the transcoding time of the first video file according to the transcoding rate of each transcoding mode, so that the terminal can determine the transcoding time of each transcoding mode in advance, and the transcoding time and the uploading time of the video file are combined conveniently to determine the publishing time of the first video file.
In step S306, the terminal determines a data size corresponding to the first video file based on the transcoding parameter set, where the data size is a predicted data size of a third video file obtained by transcoding the first video file through the transcoding parameter set.
The data size represents the size of the video file, and the third video file is a transcoded video file predicted by the terminal. In this step, the terminal determines a sampling frequency in the transcoding process of the first video file according to the target transcoding code rate corresponding to the transcoding parameter set, so as to predict a data volume corresponding to the first video file after the first video file is sampled by the first sampling frequency, and then predicts a data volume corresponding to the transcoded first video file according to the transcoding mode corresponding to the transcoding parameter set.
In step S307, the terminal determines an upload duration according to the data size and the network transmission parameter.
The uploading time length is used for representing the time length consumed by uploading the network transmission parameters based on the terminal to the server after the transcoding is performed on the first video file by the corresponding transcoding parameter group. And the terminal takes the ratio of the data volume of the first video file to the network transmission parameter as the uploading duration of the third video file. For example, the data volume corresponding to the first video file is S, the network transmission parameter is bw, and the uploading duration of the second video file is S/bw.
Referring to fig. 4, the network transmission parameter is a parameter that affects the uploading speed of the video file. For example, the network transmission parameter is bandwidth, signal strength, and the like. Correspondingly, before the step, the terminal acquires the network transmission parameters of the terminal. The process is realized by the following steps (1) to (2), and comprises the following steps:
(1) the terminal sends a parameter detection packet to the routing equipment in the current network, and the parameter detection packet is used for detecting the network transmission parameters of the current network.
The terminal sends a parameter detection packet to the routing equipment in the current network, and detects the network transmission parameters of the current network through the parameter detection packet.
(2) And the terminal receives a response message of the parameter detection packet in the current network, wherein the response message carries the network transmission parameters of the network.
In this step, the terminal periodically scans the response messages in the current network, analyzes the scanned response messages to obtain the network transmission parameters carried by each response message, and determines the network transmission parameters of the current network according to the network transmission parameters carried by each response message.
In the implementation mode, the network transmission parameters of the current network environment are detected through the parameter detection packet, so that the network transmission parameters influencing the uploading of the video files are known in advance, and the uploading duration of the transcoded third video files is predicted conveniently.
It should be noted that, for a plurality of transcoding parameter sets, the terminal determines the transcoding duration and the uploading duration of the transcoding parameter set through the above step 304-307, respectively, to obtain the transcoding duration and the uploading duration corresponding to the plurality of transcoding parameter sets.
In step S308, the terminal determines a target transcoding parameter set based on the multiple groups of transcoding durations and the uploading duration, where the target transcoding parameter set is a transcoding parameter set whose sum of the corresponding transcoding duration and the uploading duration satisfies a condition.
Continuing to refer to fig. 4, in this step, the terminal sums the transcoding duration and the uploading duration of each transcoding parameter set, respectively, to obtain the overall publishing duration of the first video file. For example, if the transcoding time length is T, the data size corresponding to the first video file is S, and the network transmission parameter is bw, the overall publishing time length of the first video file is determined by the following formula one.
The formula I is as follows: cost is T + S/bw
The method comprises the steps of obtaining a first video file, a second video file, a third video file, a network transmission parameter and a Cost, wherein Cost is the overall release time length of the first video file, T is the transcoding time length of each transcoding mode, S/bw is the uploading time length of the third video file, S is the data volume, and bw is the network transmission parameter.
The condition that the sum of the transcoding duration and the uploading duration meets the condition means that the sum of the transcoding duration and the uploading duration is the minimum sum of the multiple groups of transcoding durations and uploading durations. Correspondingly, for each transcoding mode, the terminal determines the release duration of the first video file corresponding to the transcoding mode according to a formula I according to the parameters corresponding to each transcoding mode; and comparing the release time lengths corresponding to the transcoding modes, thereby determining the release time length with the shortest release time length.
For example, the multiple transcoding modes include a soft coding mode, a hard coding mode, or no transcoding.
For the soft coding mode, the data size of the third video file is: ssw(ii) a Transcoding duration is Tsw
For the hard-coded mode, the data size of the third video file is Shw(ii) a Transcoding duration is Thw
For the mode without transcoding, the third video file is Sskip(i.e., the amount of data of the first video file) with a transcoding duration of Tskip=0。
And determining the release time length of the first video file corresponding to each transcoding mode according to the data volume, the transcoding time length and the network transmission parameters of the third video file of the formula I and the three transcoding modes, and further determining the target transcoding mode with the shortest release time length from the release time lengths corresponding to each transcoding mode.
In step S309, the terminal transcodes the first video file according to the target transcoding parameter set to obtain a second video file.
In this step, the terminal determines a transcoding mode and parameter information in the target transcoding parameter set, and transcodes the first video file according to the transcoding mode and parameter information to obtain a second video file.
In step S310, the terminal uploads the second video file.
And uploading the second video file to a server in the current network according to the current network transmission parameters.
In the embodiment of the disclosure, when the first video file is published, the target transcoding parameter set used for publishing the first video file is determined by predicting the transcoding time length and the uploading time length, so that the publishing process of the video file can be optimized by combining various publishing conditions in the publishing process, the publishing time length of the video file is reduced, and the publishing efficiency of the video file is improved.
Fig. 5 is a block diagram of a video distribution apparatus according to an example embodiment. Referring to fig. 5, the apparatus includes:
a parameter group determining unit 501 configured to perform determining a plurality of transcoding parameter groups in response to an instruction to issue a first video file;
a time length determining unit 502 configured to determine a plurality of groups of transcoding time lengths and uploading time lengths according to the network transmission parameters of the terminal and the plurality of transcoding parameter sets, where a group of transcoding time lengths and uploading time lengths are respectively used for indicating a time length consumed for transcoding the first video file by applying the corresponding transcoding parameter set and a time length consumed for uploading to the server based on the network transmission parameters;
a target parameter set determining unit 503 configured to determine a target transcoding parameter set based on the multiple sets of transcoding durations and uploading durations, where the target transcoding parameter set is a transcoding parameter set whose sum of the corresponding transcoding duration and the uploading duration satisfies a condition;
a transcoding unit 504 configured to perform transcoding of the first video file according to the target transcoding parameter set, resulting in a second video file;
an uploading unit 505 configured to perform uploading the second video file.
In one possible implementation, referring to fig. 6, the duration determining unit 502 includes:
the first determining subunit 5021 is configured to execute, for each transcoding parameter group, obtaining a target transcoding rate corresponding to a transcoding mode according to the transcoding mode included in the transcoding parameter group, where the target transcoding rate is a rate of transcoding a video file by the terminal through the transcoding mode; determining the ratio of the file duration of the first video file to the target transcoding rate as the transcoding duration; and the number of the first and second groups,
a second determining subunit 5022, configured to perform, for each transcoding parameter group, determining, based on the transcoding parameter group, a data size corresponding to the first video file, where the data size is a predicted data size of a third video file obtained by transcoding the first video file through the transcoding parameter group; and determining the uploading time length according to the data volume and the network transmission parameter.
In another possible implementation, referring to fig. 6, the apparatus further includes:
a transcoding test unit 506, configured to respond to the terminal transcoding the video file for the first time, execute transcoding test on multiple transcoding modes, and obtain a transcoding rate at which the terminal transcodes the video file through each transcoding mode;
the storage unit 507 is configured to store the transcoding rate corresponding to each transcoding method.
In another possible implementation manner, each transcoding parameter group comprises a transcoding manner and parameter information;
referring to fig. 6, the parameter group determination unit 501 includes:
a third determining subunit 5011 configured to perform determining a plurality of transcoding manners, and determine the parameter information according to the video content of the first video file;
the composing subunit 5012 is configured to perform composing the parameter information with each transcoding method into a transcoding parameter set.
In another possible implementation, the parameter information includes a target definition and a target transcoding code rate;
the third determining subunit 5011 is configured to perform determining a target definition according to the original definition of the first video file, where the target definition is the lowest definition of the transcoded first video file; determining the target transcoding code rate according to the video content of the first video file and the target definition; and the target definition and the target transcoding code rate form the parameter information.
In another possible implementation manner, the third determining subunit 5011 is configured to perform feature extraction on the video content of the first video file to obtain an image feature of the video content; determining the content information of the first video file according to the image characteristics of the video content; determining image feature difference between each frame of video to obtain difference information between each frame of video; and determining a target transcoding code rate matched with the content information and the difference information under the target definition according to the content information, the difference information and the target definition of the first video file.
In another possible implementation manner, the third determining subunit 5011 is configured to perform the transcoding rate determining model for inputting the video content of the first video file and the target definition, so as to obtain the target transcoding rate.
In another possible implementation, referring to fig. 6, the apparatus further includes:
an obtaining unit 508 configured to perform obtaining of a sample video file and a transcoding code rate determination model to be trained, the sample video file being a video file labeled with definition and transcoding code rate of the video file;
a model training unit 509 configured to perform model training on the transcoding code rate determination model to be trained according to the definition and the transcoding code rate of the sample video file, so as to obtain the transcoding code rate determination model.
In the embodiment of the disclosure, when the first video file is published, the target transcoding parameter set used for publishing the first video file is determined by predicting the transcoding time length and the uploading time length, so that the publishing process of the video file can be optimized by combining various publishing conditions in the publishing process, the publishing time length of the video file is reduced, and the publishing efficiency of the video file is improved.
It should be noted that: in the video distribution apparatus provided in the above embodiment, only the division of the above functional modules is taken as an example when video is distributed, and in practical applications, the above functions can be distributed by different functional modules as needed, that is, the internal structure of the terminal is divided into different functional modules to complete all or part of the above described functions. In addition, the video publishing device and the video publishing method provided by the above embodiments belong to the same concept, and specific implementation processes thereof are detailed in the method embodiments and are not described herein again.
Fig. 7 is a block diagram illustrating a terminal according to an example embodiment. The terminal 700 may be: a smartphone, a tablet, a laptop, or a desktop computer. Terminal 700 may also be referred to by other names such as user equipment, portable terminal, laptop terminal, desktop terminal, and so on.
In general, terminal 700 includes: a processor 701 and a memory 702.
The processor 701 may include one or more processing cores, such as a 4-core processor, an 8-core processor, and so on. The processor 701 may be implemented in at least one hardware form of a DSP (Digital Signal Processing), an FPGA (Field-Programmable Gate Array), and a PLA (Programmable Logic Array). The processor 701 may also include a main processor and a coprocessor, where the main processor is a processor for Processing data in an awake state, and is also called a Central Processing Unit (CPU); a coprocessor is a low power processor for processing data in a standby state. In some embodiments, the processor 701 may be integrated with a GPU (Graphics Processing Unit) which is responsible for rendering and drawing the content required to be displayed by the display screen. In some embodiments, the processor 701 may further include an AI (Artificial Intelligence) processor for processing computing operations related to machine learning.
Memory 702 may include one or more computer-readable storage media, which may be non-transitory. Memory 702 may also include high-speed random access memory, as well as non-volatile memory, such as one or more magnetic disk storage devices, flash memory storage devices. In some embodiments, a non-transitory computer readable storage medium in memory 702 is used to store at least one instruction for execution by processor 701 to implement a video distribution method provided by method embodiments of the present disclosure.
In some embodiments, the terminal 700 may further optionally include: a peripheral interface 703 and at least one peripheral. The processor 701, the memory 702, and the peripheral interface 703 may be connected by buses or signal lines. Various peripheral devices may be connected to peripheral interface 703 via a bus, signal line, or circuit board. Specifically, the peripheral device includes: at least one of a radio frequency circuit 704, a display screen 705, a camera assembly 706, an audio circuit 707, a positioning component 708, and a power source 709.
The peripheral interface 703 may be used to connect at least one peripheral related to I/O (Input/Output) to the processor 701 and the memory 702. In some embodiments, processor 701, memory 702, and peripheral interface 703 are integrated on the same chip or circuit board; in some other embodiments, any one or two of the processor 701, the memory 702, and the peripheral interface 703 may be implemented on a separate chip or circuit board, which is not limited in this embodiment.
The Radio Frequency circuit 704 is used for receiving and transmitting RF (Radio Frequency) signals, also called electromagnetic signals. The radio frequency circuitry 704 communicates with communication networks and other communication devices via electromagnetic signals. The rf circuit 704 converts an electrical signal into an electromagnetic signal to transmit, or converts a received electromagnetic signal into an electrical signal. Optionally, the radio frequency circuit 704 includes: an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a subscriber identity module card, and so forth. The radio frequency circuitry 704 may communicate with other terminals via at least one wireless communication protocol. The wireless communication protocols include, but are not limited to: the world wide web, metropolitan area networks, intranets, generations of mobile communication networks (2G, 3G, 4G, and 5G), Wireless local area networks, and/or WiFi (Wireless Fidelity) networks. In some embodiments, the radio frequency circuit 704 may also include NFC (Near Field Communication) related circuits, which are not limited by this disclosure.
The display screen 705 is used to display a UI (User Interface). The UI may include graphics, text, icons, video, and any combination thereof. When the display screen 705 is a touch display screen, the display screen 705 also has the ability to capture touch signals on or over the surface of the display screen 705. The touch signal may be input to the processor 701 as a control signal for processing. At this point, the display 705 may also be used to provide virtual buttons and/or a virtual keyboard, also referred to as soft buttons and/or a soft keyboard. In some embodiments, the display 705 may be one, disposed on a front panel of the terminal 700; in other embodiments, the display 705 can be at least two, respectively disposed on different surfaces of the terminal 700 or in a folded design; in other embodiments, the display 705 may be a flexible display disposed on a curved surface or on a folded surface of the terminal 700. Even more, the display 705 may be arranged in a non-rectangular irregular pattern, i.e. a shaped screen. The Display 705 may be made of LCD (Liquid Crystal Display), OLED (Organic Light-Emitting Diode), or the like.
The camera assembly 706 is used to capture images or video. Optionally, camera assembly 706 includes a front camera and a rear camera. Generally, a front camera is disposed at a front panel of the terminal, and a rear camera is disposed at a rear surface of the terminal. In some embodiments, the number of the rear cameras is at least two, and each rear camera is any one of a main camera, a depth-of-field camera, a wide-angle camera and a telephoto camera, so that the main camera and the depth-of-field camera are fused to realize a background blurring function, and the main camera and the wide-angle camera are fused to realize panoramic shooting and VR (Virtual Reality) shooting functions or other fusion shooting functions. In some embodiments, camera assembly 706 may also include a flash. The flash lamp can be a monochrome temperature flash lamp or a bicolor temperature flash lamp. The double-color-temperature flash lamp is a combination of a warm-light flash lamp and a cold-light flash lamp, and can be used for light compensation at different color temperatures.
The audio circuitry 707 may include a microphone and a speaker. The microphone is used for collecting sound waves of a user and the environment, converting the sound waves into electric signals, and inputting the electric signals to the processor 701 for processing or inputting the electric signals to the radio frequency circuit 704 to realize voice communication. For the purpose of stereo sound collection or noise reduction, a plurality of microphones may be provided at different portions of the terminal 700. The microphone may also be an array microphone or an omni-directional pick-up microphone. The speaker is used to convert electrical signals from the processor 701 or the radio frequency circuit 704 into sound waves. The loudspeaker can be a traditional film loudspeaker or a piezoelectric ceramic loudspeaker. When the speaker is a piezoelectric ceramic speaker, the speaker can be used for purposes such as converting an electric signal into a sound wave audible to a human being, or converting an electric signal into a sound wave inaudible to a human being to measure a distance. In some embodiments, the audio circuitry 707 may also include a headphone jack.
The positioning component 708 is used to locate the current geographic Location of the terminal 700 for navigation or LBS (Location Based Service). The Positioning component 708 can be a Positioning component based on the Global Positioning System (GPS) in the united states, the beidou System in china, or the galileo System in russia.
Power supply 709 is provided to supply power to various components of terminal 700. The power source 709 may be alternating current, direct current, disposable batteries, or rechargeable batteries. When the power source 709 includes a rechargeable battery, the rechargeable battery may be a wired rechargeable battery or a wireless rechargeable battery. The wired rechargeable battery is a battery charged through a wired line, and the wireless rechargeable battery is a battery charged through a wireless coil. The rechargeable battery may also be used to support fast charge technology.
In some embodiments, terminal 700 also includes one or more sensors 710. The one or more sensors 710 include, but are not limited to: acceleration sensor 711, gyro sensor 712, pressure sensor 713, fingerprint sensor 714, optical sensor 715, and proximity sensor 716.
Those skilled in the art will appreciate that the configuration shown in fig. 7 is not intended to be limiting of terminal 700 and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components may be used.
In an exemplary embodiment, there is also provided a storage medium comprising instructions, such as a memory comprising instructions, executable by a processor of a terminal to perform the video distribution method described above. Alternatively, the storage medium is a non-transitory computer-readable storage medium, which may be, for example, a ROM (Read-Only Memory), a RAM (Random Access Memory), a CD-ROM (Compact Disc Read-Only Memory), a magnetic tape, a floppy disk, an optical data storage device, and the like.
In an exemplary embodiment, there is also provided a computer program product including computer program code stored in a computer-readable storage medium, the computer program code being read by a processor of a computer apparatus from the computer-readable storage medium, the computer program code being executed by the processor to cause the computer apparatus to perform the operations performed in the above-described video distribution method.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A method for video distribution, the method comprising:
determining a plurality of transcoding parameter sets in response to a publishing instruction of the first video file;
determining multiple groups of transcoding time lengths and uploading time lengths according to network transmission parameters of a terminal and the multiple transcoding parameter groups, wherein one group of transcoding time length and uploading time length is respectively used for representing the time length consumed by transcoding the first video file by applying a corresponding transcoding parameter group and the time length consumed by uploading the first video file to a server based on the network transmission parameters;
determining a target transcoding parameter set based on the multiple groups of transcoding time lengths and the uploading time length, wherein the target transcoding parameter set is a transcoding parameter set which corresponds to the condition that the sum of the transcoding time length and the uploading time length meets the condition;
transcoding the first video file according to the target transcoding parameter set to obtain a second video file;
and uploading the second video file.
2. The method of claim 1, wherein determining the plurality of sets of transcoding durations and uploading durations according to the network transmission parameters of the terminal and the plurality of transcoding parameter sets comprises:
for each transcoding parameter set, acquiring a target transcoding rate corresponding to the transcoding mode according to the transcoding mode included in the transcoding parameter set, wherein the target transcoding rate is the rate of transcoding a video file by the terminal through the transcoding mode; determining the ratio of the file duration of the first video file to the target transcoding rate as the transcoding duration; and the number of the first and second groups,
for each transcoding parameter group, determining a data volume corresponding to the first video file based on the transcoding parameter group, wherein the data volume is a predicted data volume of a third video file obtained by transcoding the first video file through the transcoding parameter group; and determining the uploading time according to the data volume and the network transmission parameters.
3. The method according to claim 2, wherein before the obtaining of the target transcoding rate corresponding to the transcoding mode according to the transcoding mode included in the transcoding parameter set, the method further includes:
responding to the terminal to transcode the video file for the first time, and performing transcoding test on multiple transcoding modes to obtain the transcoding rate of the terminal for transcoding the video file through each transcoding mode;
and storing the transcoding rate corresponding to each transcoding mode.
4. The method of claim 1, wherein each transcoding parameter set comprises a transcoding mode and parameter information;
the determining a plurality of transcoding parameter sets comprises:
determining a plurality of transcoding modes, and determining the parameter information according to the video content of the first video file;
and respectively combining the parameter information and each transcoding mode to form a transcoding parameter set.
5. The method of claim 4, wherein the parameter information comprises a target sharpness and a target transcoding code rate;
the determining the parameter information according to the video content of the first video file includes:
determining a target definition according to the original definition of the first video file, wherein the target definition is the lowest definition of the first video file after transcoding;
determining the target transcoding code rate according to the video content of the first video file and the target definition;
and the target definition and the target transcoding code rate form the parameter information.
6. The method of claim 5, wherein determining the target transcoding bitrate based on the video content of the first video file and the target sharpness comprises:
performing feature extraction on the video content of the first video file to obtain the image feature of the video content;
determining content information of the first video file according to the image characteristics of the video content;
determining image feature difference between each frame of video to obtain difference information between each frame of video;
and determining a target transcoding code rate matched with the content information and the difference information under the target definition according to the content information, the difference information and the target definition of the first video file.
7. The method of claim 5, wherein determining the target transcoding bitrate based on the video content of the first video file and the target sharpness comprises:
and inputting the video content of the first video file and the target definition into a transcoding code rate determination model to obtain the target transcoding code rate.
8. A video distribution apparatus, characterized in that the apparatus comprises:
a parameter group determination unit configured to perform determining a plurality of transcoding parameter groups in response to an issuance instruction of the first video file;
the time length determining unit is configured to execute determining multiple groups of transcoding time lengths and uploading time lengths according to network transmission parameters of the terminal and the multiple transcoding parameter groups, wherein one group of transcoding time lengths and uploading time lengths are respectively used for representing the time length consumed by transcoding the first video file by applying the corresponding transcoding parameter group and the time length consumed by uploading the first video file to the server based on the network transmission parameters;
a target parameter set determining unit configured to determine a target transcoding parameter set based on the multiple groups of transcoding time lengths and the uploading time length, wherein the target transcoding parameter set is a transcoding parameter set of which the sum of the corresponding transcoding time length and the uploading time length meets the condition;
the transcoding unit is configured to transcode the first video file according to the target transcoding parameter group to obtain a second video file;
an upload unit configured to perform uploading the second video file.
9. A terminal, characterized in that it comprises a processor and a memory, in which at least one program code is stored, which is loaded and executed by the processor to implement the video distribution method according to any one of claims 1 to 7.
10. A computer-readable storage medium having at least one program code stored therein, the at least one program code being loaded and executed by a processor to implement the video distribution method of any of claims 1-7.
CN202010923226.4A 2020-09-04 2020-09-04 Video distribution method, device, terminal and storage medium Active CN112040333B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010923226.4A CN112040333B (en) 2020-09-04 2020-09-04 Video distribution method, device, terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010923226.4A CN112040333B (en) 2020-09-04 2020-09-04 Video distribution method, device, terminal and storage medium

Publications (2)

Publication Number Publication Date
CN112040333A true CN112040333A (en) 2020-12-04
CN112040333B CN112040333B (en) 2022-07-01

Family

ID=73590657

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010923226.4A Active CN112040333B (en) 2020-09-04 2020-09-04 Video distribution method, device, terminal and storage medium

Country Status (1)

Country Link
CN (1) CN112040333B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112533065A (en) * 2020-12-11 2021-03-19 北京达佳互联信息技术有限公司 Method and device for publishing video, electronic equipment and storage medium
CN114650437A (en) * 2022-03-14 2022-06-21 百果园技术(新加坡)有限公司 Video publishing method, device, equipment and storage medium
CN114866840A (en) * 2022-03-31 2022-08-05 广州方硅信息技术有限公司 VMAF image quality evaluation method, terminal, host, system and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120192239A1 (en) * 2011-01-25 2012-07-26 Youtoo Technologies, LLC Content creation and distribution system
US20120192225A1 (en) * 2011-01-25 2012-07-26 Youtoo Technologies, LLC Administration of Content Creation and Distribution System
CN105898448A (en) * 2015-12-14 2016-08-24 乐视云计算有限公司 Submission method and device of transcoding attribute information
WO2017166501A1 (en) * 2016-03-31 2017-10-05 乐视控股(北京)有限公司 Method and device for assigning transcoding task
CN109391825A (en) * 2017-08-03 2019-02-26 腾讯科技(深圳)有限公司 A kind of video transcoding method and its device, server, readable storage medium storing program for executing
CN110572713A (en) * 2019-09-24 2019-12-13 广州优视云集科技有限公司 transcoding method and processing terminal for adaptive video bandwidth ratio

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120192239A1 (en) * 2011-01-25 2012-07-26 Youtoo Technologies, LLC Content creation and distribution system
US20120192225A1 (en) * 2011-01-25 2012-07-26 Youtoo Technologies, LLC Administration of Content Creation and Distribution System
CN105898448A (en) * 2015-12-14 2016-08-24 乐视云计算有限公司 Submission method and device of transcoding attribute information
WO2017166501A1 (en) * 2016-03-31 2017-10-05 乐视控股(北京)有限公司 Method and device for assigning transcoding task
CN109391825A (en) * 2017-08-03 2019-02-26 腾讯科技(深圳)有限公司 A kind of video transcoding method and its device, server, readable storage medium storing program for executing
CN110572713A (en) * 2019-09-24 2019-12-13 广州优视云集科技有限公司 transcoding method and processing terminal for adaptive video bandwidth ratio

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112533065A (en) * 2020-12-11 2021-03-19 北京达佳互联信息技术有限公司 Method and device for publishing video, electronic equipment and storage medium
CN112533065B (en) * 2020-12-11 2022-07-22 北京达佳互联信息技术有限公司 Method and device for publishing video, electronic equipment and storage medium
CN114650437A (en) * 2022-03-14 2022-06-21 百果园技术(新加坡)有限公司 Video publishing method, device, equipment and storage medium
CN114650437B (en) * 2022-03-14 2024-04-16 百果园技术(新加坡)有限公司 Video publishing method, device, equipment and storage medium
CN114866840A (en) * 2022-03-31 2022-08-05 广州方硅信息技术有限公司 VMAF image quality evaluation method, terminal, host, system and storage medium

Also Published As

Publication number Publication date
CN112040333B (en) 2022-07-01

Similar Documents

Publication Publication Date Title
CN112040333B (en) Video distribution method, device, terminal and storage medium
CN115473957B (en) Image processing method and electronic equipment
CN110933330A (en) Video dubbing method and device, computer equipment and computer-readable storage medium
CN110022489B (en) Video playing method, device and storage medium
CN110572722A (en) Video clipping method, device, equipment and readable storage medium
CN110493626B (en) Video data processing method and device
CN108769738B (en) Video processing method, video processing device, computer equipment and storage medium
JP2022546542A (en) Communication method, communication device, communication system, server and computer program
CN110750734A (en) Weather display method and device, computer equipment and computer-readable storage medium
CN111416996B (en) Multimedia file detection method, multimedia file playing device, multimedia file equipment and storage medium
CN111402844A (en) Song chorusing method, device and system
KR20150057707A (en) Method for sharing file and electronic device thereof
CN109819314B (en) Audio and video processing method and device, terminal and storage medium
CN112911337B (en) Method and device for configuring video cover pictures of terminal equipment
CN112839107B (en) Push content determination method, device, equipment and computer-readable storage medium
CN116208704A (en) Sound processing method and device
CN110493635B (en) Video playing method and device and terminal
CN114691860A (en) Training method and device of text classification model, electronic equipment and storage medium
CN109714628B (en) Method, device, equipment, storage medium and system for playing audio and video
CN111312207A (en) Text-to-audio method and device, computer equipment and storage medium
CN111399796A (en) Voice message aggregation method and device, electronic equipment and storage medium
CN112492331B (en) Live broadcast method, device, system and storage medium
CN110519319B (en) Method and device for splitting partitions
CN108664421B (en) Method, device and storage medium for acquiring multimedia data
CN113076286A (en) Method, device and equipment for acquiring multimedia file and readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant