Video gear decision-making method and device, equipment, storage medium and product
By determining the link delay and setting the delay threshold in the video gear decision-making, the appropriate video gear is selected for adaptive bit rate decision-making, which solves the problem of video playback instability caused by high latency during the transcoding process and improves Improves the anti-shake ability and stability of video playback.
Patent Information
- Application Number
- CN202410715779.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-04
- Publication Date
- 2024-09-17
AI Technical Summary
The high latency of the existing video gear decision-making algorithm during the transcoding process causes the adaptive gear switching to fail smoothly, and the video buffer on the viewer side becomes smaller, resulting in a decrease in the anti-shake capability and stability of video playback.
By determining the link delay of the video stream from the transcoding server to the audience video server, and selecting an optional video file from multiple transcoded video files according to the set delay threshold, adaptive bit rate decisions are made to ensure that the video The smooth progress of gear switching reduces the risk of the viewer's video buffer becoming smaller.
It improves the effect of video gear decision-making, improves the anti-shake ability of video playback and the stability of video playback on the viewer side, ensuring the smooth progress of adaptive gear switching.
Smart Images

Figure CN118660185A
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of computer technology, and in particular to a video gear decision method, device, equipment, storage medium and product. Background Art
[0002] In order to meet the diverse needs of users, online videos watched by users generally provide a variety of video levels to choose from, such as source stream, high definition, standard definition, low definition and other different video levels. The encoding method, bit rate, resolution, frame rate, etc. between different video levels are different.
[0003] In order to improve the user experience when watching online, an automatic gear selection function is generally provided to automatically select the appropriate gear for the user to ensure smooth viewing and clarity. The existing adaptive gear selection algorithms can be mainly divided into three types: bandwidth-based, buffer size-based, and hybrid. The bandwidth-based algorithm mainly selects the gear based on the bandwidth value collected and predicted during the playback process; the buffer size-based algorithm mainly selects the gear based on the size of the data cached by the client; the hybrid algorithm comprehensively refers to the bandwidth value and cached data. These adaptive gear selection algorithms focus on the bit rate of the video gear when switching gears, that is, the adaptive gear selection algorithm is suitable for situations where the user network conditions are different and fluctuating, and can provide smooth video for users with poor networks, and provide clearer video for users with good networks.
[0004] However, the high latency in the transcoding process may cause unsmooth adaptive switching or a smaller video buffer on the viewer side, resulting in poor video gear decision-making, which in turn reduces the anti-jitter capability of video playback and reduces the stability of video playback on the viewer side. Summary of the invention
[0005] The embodiments of the present application provide a video gear decision method, device, equipment, storage medium and product to solve the technical problems in the prior art that the video gear decision effect is poor, resulting in a decrease in the anti-jitter capability of video playback and a decrease in the stability of video playback on the viewer side. The embodiments of the present application can effectively improve the video gear decision effect, enhance the anti-jitter capability of video playback and the stability of video playback on the viewer side.
[0006] In a first aspect, an embodiment of the present application provides a video gear decision method, comprising:
[0007] Determine the link delay of the video stream of one or more transcoded video gears being transcoded by the transcoding server and downstream reaching the viewer video server;
[0008] Determine one or more optional video gears from the one or more transcoded video gears according to the link delay and the set delay threshold;
[0009] An adaptive bit rate decision is performed based on the optional video gear to obtain a target video gear.
[0010] In a second aspect, an embodiment of the present application provides a video gear position decision device, including a delay determination module, a gear position determination module and a gear position decision module, wherein:
[0011] The delay determination module is configured to determine the link delay of the video stream of one or more transcoded video gears being transcoded by the transcoding server and being downstream to the viewer video server;
[0012] The gear determination module is configured to determine one or more optional video gears from the one or more transcoded video gears according to the link delay and a set delay threshold;
[0013] The gear decision module is configured to perform adaptive bit rate decision based on the optional video gear to obtain a target video gear.
[0014] In a third aspect, an embodiment of the present application provides a video gear decision device, including: a memory and one or more processors;
[0015] The memory is used to store one or more programs;
[0016] When the one or more programs are executed by the one or more processors, the one or more processors implement the video gear decision method as described in the first aspect.
[0017] In a fourth aspect, an embodiment of the present application provides a non-volatile storage medium storing computer executable instructions, wherein the computer executable instructions, when executed by a computer processor, are used to execute the video gear decision method as described in the first aspect.
[0018] In a fifth aspect, an embodiment of the present application provides a computer program product, which includes a computer program stored in a computer-readable storage medium. At least one processor of the device reads and executes the computer program from the computer-readable storage medium, so that the device performs the video gear decision method described in the first aspect.
[0019] The embodiment of the present application determines one or more optional video gears from one or more transcoded video gears according to the link delay of the video stream of one or more transcoded video gears being transcoded on the transcoding server and downstream to the viewer video server and setting a delay threshold, and obtains the target video gear by making an adaptive bit rate decision based on the optional video gears. The optional video gear that can ensure smooth adaptive gear switching and reduce the size of the video buffer on the viewer side is accurately determined according to the link delay and the set delay threshold, thereby effectively improving the video gear decision effect, and enhancing the anti-jitter capability of video playback and the stability of video playback on the viewer side. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 is a flow chart of a video gear decision method provided in an embodiment of the present application;
[0021] Figure 2 is a flow chart of another video gear decision method provided in an embodiment of the present application;
[0022] Figure 3 It is a structural schematic diagram of a video gear decision device provided in an embodiment of the present application;
[0023] Figure 4 It is a structural schematic diagram of a video gear decision device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0024] In order to make the purpose, technical scheme and advantages of the present application clearer, the specific embodiments of the present application are further described in detail below in conjunction with the accompanying drawings. It is understood that the specific embodiments described herein are only used to explain the present application, rather than to limit the present application. It should also be noted that, for the convenience of description, only the part related to the present application but not all the contents are shown in the accompanying drawings. Before discussing the exemplary embodiments in more detail, it should be mentioned that some exemplary embodiments are described as processes or methods depicted as flow charts. Although the flow chart describes each operation (or step) as a sequential process, many of the operations therein can be implemented in parallel, concurrently or simultaneously. In addition, the order of each operation can be rearranged. The above process can be terminated when its operation is completed, but it can also have additional steps not included in the accompanying drawings. The above process can correspond to a method, a function, a procedure, a subroutine, a subprogram, etc.
[0025] The video gear decision method provided in this application can be applied to video gear decision-making in live broadcast and video viewing scenarios. It aims to accurately determine the optional video gears that can ensure the smooth implementation of adaptive gear switching and reduce the size of the video buffer on the viewer side based on the link delay and the set delay threshold, effectively improve the video gear decision effect, and enhance the anti-jitter capability of video playback and the stability of video playback on the viewer side.
[0026] In the existing video gear decision scheme, in order to adapt to the diverse video viewing needs of users and the network environment of different users, multiple gears are generally provided to users in video playback scenarios such as online video and live broadcast, such as source stream gear, ultra-high definition gear, high definition gear, standard definition gear, low definition gear, etc. In order to improve the user's video viewing experience, the adaptive bitrate (ABR) function is generally provided to users based on the adaptive gear selection algorithm to automatically select the appropriate video gear for the user. The adaptive gear selection algorithm improves the user experience by adjusting the bitrate of the pushed video in real time. It is based on the user's network status and related status. When the network is good, a high bitrate and high-quality gear is selected. When the network is poor, a low bitrate gear is selected to ensure smoothness and avoid jamming. The existing adaptive gear selection algorithms can be mainly divided into three types: bandwidth-based, buffer size-based, and hybrid. These adaptive gear selection algorithms focus on the bitrate of the video gear, which are suitable for situations where the user's network conditions are different and fluctuating. They can provide smooth videos for users with poor networks and provide clearer videos for users with good networks.
[0027] However, the reasons for the freeze of user video playback are not only due to network conditions. The high latency of transcoding and transmission process may cause the adaptive bitrate switching to be unsmooth or the video buffer on the audience side to become smaller after switching from the source stream gear to the transcoding gear (in the live broadcast scenario, the host starts broadcasting for one second, and the audience can receive one second of video stream. If the transcoding delay is one second longer, the video buffer on the audience side may be one second less), resulting in a decrease in the anti-jitter ability on the audience side. In addition, video transcoding will also be affected by the load of the transcoding server. A high load on the transcoding server will further increase the delay of video transcoding, and may also cause the transcoded video frame rate (fps) to fail to cover the source stream video frame rate or frame loss during the video transcoding process, affecting the stability of video transcoding. In addition, the link distribution process of the video stream will also cause different delays for different gears of the same live broadcast room. Therefore, it is easier to introduce freezes in video playback when the adaptive bitrate is switched. Especially in the case of high latency, the instability of the video stream will aggravate the risk of freezes caused by high latency. Secondly, the complexity of the content distribution network architecture causes the video streams of different video gears in the same live broadcast room to be distributed from the host video server (vs, video server) to the audience video server (vs, video server) through different video proxy servers (vp, video proxy). In addition, due to the large difference in the bit rates of the streams of different gears and factors such as packet loss and retransmission in the link, the video streams of different video gears will also produce different transmission delays, which may also affect the size of the video buffer at the audience end in the switching scenario. Based on this, a video gear decision method of an embodiment of the present application is provided to solve the technical problem that the existing video gear decision effect is poor, resulting in a decrease in the anti-jitter ability of video playback and a decrease in the stability of video playback at the audience end.
[0028] Figure 1 A flowchart of a video gear decision method provided in an embodiment of the present application is given. The video gear decision method provided in an embodiment of the present application can be executed by a video gear decision device, which can be implemented by hardware and / or software and integrated in a video gear decision device (e.g., an audience video server).
[0029] The following description is made by taking the video gear decision device executing the video gear decision method as an example. Figure 1 , the video gear decision method includes:
[0030] S110: Determine the link delay of the video stream of one or more transcoding video levels being transcoded by the transcoding server and being downstream to the viewer video server.
[0031] The transcoding video gear provided by this solution is a gear for transcoding the source stream video, wherein different transcoding video gears may correspond to different combinations of encoding parameters such as encoding mode, bit rate, resolution and frame rate.
[0032] In one embodiment, the audience video server, anchor video server and transcoding server provided by this solution can be arranged in a content distribution network. The content distribution network relies on edge servers deployed in various places. Through the load balancing, content distribution, scheduling and other functional modules of the central platform, users can obtain the required content nearby, reduce network congestion, and improve user access response speed and hit rate. Optionally, the video server can be used as an audience video server or an anchor video server alone, or as an audience video server and an anchor video server at the same time.
[0033] In one embodiment, the video server maintains the users of the current video server on the channel. The combination of different video servers and video proxy servers can be distributed in different logical groups. The first user subscription subscribes to all video proxy servers in the same logical group. The video proxy server maintains the video server of the channel subscribed by this logical group. The first video server subscription of this logical group subscribes to all video service control servers (vmsc, video servercontroller). The video proxy server also maintains the subscription relationship of the channel subscribed by this logical group in each logical group. The video server will push the stream to the audience subscribed by this video server according to the channel subscription relationship, and push it to a video proxy server in the same logical group (regardless of whether there are other computer rooms subscribed). After receiving the video stream, the video server and the video proxy server will cache the video stream to the local video queue. A video queue will cache one stream, and streams of different video gears will use different video queues. After any video proxy server in the same logical group receives the video server stream, it can push the stream to other subscribed video servers in the current logical group and other logical group video proxy servers according to the channel subscription relationship. After any video proxy server in the same logical group receives the video proxy server stream, it will push it to the video server subscribed by the current logical group according to the channel subscription relationship. After the video server receives the stream from the video proxy server, it will push it to the subscribed user according to the channel subscription relationship.
[0034] In one embodiment, the anchor terminal uploads the source video stream to the anchor server, and the anchor server uploads the source video stream to the transcoding server, and the source video stream is transcoded into one or more transcoded video streams corresponding to the transcoded video gears by the transcoding server. The transcoding server sends the transcoded video stream to the anchor server, and the anchor server synchronizes the source video stream and the transcoded video streams corresponding to the one or more transcoded video gears to each audience video server, and the audience video server sends the video stream corresponding to the video gear to the audience terminal for the audience terminal to play the video.
[0035] Exemplarily, according to a set time interval or video frame interval, the link delay for transcoding one or more video streams of transcoded video gears in the transcoding server and downstream reaching the viewer video server is determined, that is, after the source stream video stream is transcoded into the transcoded video streams corresponding to one or more transcoded video gears in the transcoding server, the time it takes for the transcoded video streams corresponding to one or more transcoded video gears to be distributed from the host video server to the corresponding viewer video server.
[0036] In the process of distributing video streams from the host video server to the audience video server, the host video server may send the video stream directly to the audience video server, or send the video stream to the audience video server through one or more video proxy servers. When pulling the stream, the audience video server may need to pre-pull different video gears, resulting in a delay in the video stream reaching the audience video server. In one embodiment, a transcoded video gear corresponds to a link delay, and the corresponding link delay can be used to determine whether the transcoded video gear can be selected or disabled.
[0037] In one embodiment, when determining the link delay of the video stream being transcoded in the transcoding server and reaching the viewer video server downstream, it can be determined based on the sum of the transcoding time of the source stream video transcoding process and the downlink delay of the transcoded video stream being sent to the viewer server. For example, the link delay provided by this solution can be expressed as: total Delay = codecDelay + downlinkDelay, where codecDelay is the transcoding time and downlinkDelay is the downlink delay. Optionally, the transcoding time of the source stream video transcoding process can be counted by the transcoding server and sent to the anchor video server, and the video server broadcasts the transcoding time corresponding to each transcoded video gear, and the viewer video server can receive the transcoding time corresponding to each transcoded video gear.
[0038] In one embodiment, the link delay provided by the present solution can also be determined based on the difference between the transcoded video time information and the source stream video time information of the corresponding transcoded video gear. For example, the difference between the transcoded video time information of the key frame in the image group of the transcoded video stream and the source stream video time information of the key frame in the image group of the source stream video stream is used as the link delay. Optionally, the link delay provided by the present solution can be expressed as: totalDelay = codecGopInfo.addTime - originGopInfo.addTime, wherein codecGopInfo.addTime is the transcoded video time information of the transcoded video gear, and originGopInfo.addTime is the source stream video time information.
[0039] S120: Determine one or more optional video gears from one or more transcoded video gears according to the link delay and the set delay threshold.
[0040] Exemplarily, for each transcoded video gear, the link delay and the set delay threshold corresponding to the transcoded video gear are determined, and based on the link delay and the set delay threshold, it is determined whether to determine the corresponding transcoded video gear as an available video gear.
[0041] For example, when the link delay is less than or equal to the set delay threshold, or the link delay exceeds the set delay threshold by less than or equal to the set time length or ratio, the corresponding transcoded video gear is determined as the available video gear, and the subsequent adaptive bit rate decision will select the target video gear from these optional video gears and the source video gear. That is, when the link delay is greater than the set delay threshold, or the link delay exceeds the set delay threshold by reaching the set time length or ratio, the corresponding transcoded video gear is determined as the disabled video gear, and the subsequent adaptive bit rate decision will disable the corresponding transcoded video gear to ensure the smoothness of the user's video viewing.
[0042] In a possible embodiment, one or more optional video gears may be determined from one or more transcoded video gears by comprehensively considering the link delay and gear bit rate stratification. For example, the link delay of the low-definition transcoded video gear is 800ms, and the corresponding bit rate is 300kbps. The link delay of the high-definition transcoded video gear is 300ms, and the corresponding bit rate is 800kbps. At this time, the user bandwidth is 700kbps, and the adaptive gear selection controller may select the high-definition transcoded video gear as the available video gear). Optionally, one or more optional video gears may be determined from one or more transcoded video gears according to the link delay and the set delay threshold through machine learning or neural network models.
[0043] S130: Performing an adaptive bit rate decision based on the optional video gear to obtain a target video gear.
[0044] Exemplarily, after determining the optional video gear, when making an adaptive bit rate decision for the audience, the optional video gear corresponding to the set adaptive gear selection controller can be notified. When making an adaptive bit rate decision, the adaptive gear selection controller will avoid selecting the disabled video gear determined above and determine the target video gear among the source stream video gear and the optional video gear.
[0045] Optionally, the adaptive gear selection controller can determine the target video gear among the source stream video gear and the optional video gear based on one of three adaptive bit rate decision algorithms: bandwidth-based, buffer size-based, and mixed bandwidth and buffer.
[0046] In one embodiment, when the target video gear is different from the video gear of the video stream currently sent to the viewer end, a gear switching operation can be performed on the viewer end to switch the video gear of the video stream sent to the viewer end to the target video gear. When the target video gear is the same as the video gear of the video stream currently sent to the viewer end, there is no need to perform a gear switching operation, and the video stream of the current video gear continues to be sent to the viewer end.
[0047] In the above, by determining one or more optional video gears from one or more transcoded video gears according to the link delay of the video stream of one or more transcoded video gears being transcoded on the transcoding server and downstream to the viewer video server and setting a delay threshold, and making an adaptive bit rate decision based on the optional video gears to obtain the target video gear, the optional video gear that can ensure the smooth progress of adaptive gear switching and reduce the size of the video buffer on the viewer end is accurately determined according to the link delay and the set delay threshold, thereby effectively improving the video gear decision effect, and enhancing the anti-jitter capability of video playback and the stability of video playback on the viewer end.
[0048] Based on the above embodiments, Figure 2 A flowchart of another video gear decision method provided in an embodiment of the present application is given, and the video gear decision method is a specific implementation of the above-mentioned video gear decision method. Figure 2 , the video gear decision method includes:
[0049] S210: Determine transcoded video time information of one or more transcoded video gears and source stream video time information of source stream video gears.
[0050] S220: Determine the link delay of the video stream of one or more transcoded video levels being transcoded by the transcoding server and being downstream to the viewer video server according to the difference between the transcoded video time information and the source stream video time information.
[0051] Exemplarily, when the audience video server has both a queue for caching source video streams and a queue for caching transcoded video streams (one video gear corresponds to one queue), the transcoded video time information (codecGop I nfo.addTime) of one or more transcoded video gears and the source stream video time information (or i gi nGop I nfo.addTime) of the source stream video gear are determined, where the video time information can be determined based on the timestamp information corresponding to the latest received image group.
[0052] In one embodiment, for each transcoded video gear, the difference between the corresponding transcoded video time information and the source stream video time information is determined, and the difference is used as the link delay for the video stream of the corresponding transcoded video gear to be transcoded in the transcoding server and downstream to the audience video server. For example, when the audience video server has a queue for caching the source stream video stream and a queue for caching the transcoded video stream at the same time, for the same group of images, the audience video server calculates the difference between the key frame (I frame) timestamp of the received source stream video stream and the key frame of the transcoded video stream, and uses the difference as the link delay.
[0053] This solution accurately determines the link delay based on the difference between the transcoded video time information and the source stream video time information, accurately determines the optional video gears that can be used for gear decisions, and / or the transcoded video gears that need to be disabled, effectively reducing the situation where adaptive gear switching is not smooth or the video buffer on the viewer side becomes smaller, and improves the anti-jitter capability of video playback and the stability of video playback on the viewer side.
[0054] In one possible embodiment, the video gear decision method provided by the present solution determines the link delay of one or more transcoded video gears when the video stream is transcoded on the transcoding server and downstream reaches the viewer video server. It can be: when the first key frame of the source stream image group matches the second key frame of the transcoded image group corresponding to the transcoded video gear, the transcoded image group is a non-pre-pulled image group and the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group, determine the link delay of the transcoded video gear when it is transcoded on the transcoding server and downstream reaches the viewer video server.
[0055] Exemplarily, before determining the link delay corresponding to the transcoded video gear, first determine whether the first key frame of the source stream image group matches the second key frame of the transcoded image group corresponding to the transcoded video gear, whether the transcoded image group is a non-pre-pulled image group, and whether the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group. When the above conditions are met, the link delay is determined based on the difference between the transcoded video time information and the source stream video time information.
[0056] Optionally, the link delay provided by this solution can be determined by the following formula:
[0057] if(originGopInfo.curIFrameSeg==codecGopInfo.curIFrameSeg&&
[0058] codecGopInfo.isNotFetchData&&
[0059] codecGopInfo.addTime>=originGopInfo.addTime)
[0060] totalDelay=codecGopInfo.addTime-originGopInfo.addTime
[0061] Among them, originGopInfo.curIFrameSeg is the relevant information of the second key frame of the transcoded image group corresponding to the transcoded video gear, codecGopInfo.curIFrameSeg is the relevant information of the first key frame of the source stream image group, originGopInfo.curIFrameSeg==codecGopInfo.curIFrameSeg indicates that the first key frame of the source stream image group matches the second key frame of the transcoded image group corresponding to the transcoded video gear; codecGopInfo.isNotFetchData indicates that the transcoded image group is a non-pre-pulled image group; codecGopInfo.addTime is the second time information of the transcoded image group, originGopInfo.addTime is the time information of the source stream image group, and codecGopInfo.addTime>=originGopInfo.addTime indicates that the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group.
[0062] What needs to be explained is that according to the forwarding logic of the content distribution network, when a user in a live broadcast room on a viewer video server stops watching a video of a transcoded video gear (for example, an ultra-clear transcoded video gear), the video queue of the transcoded video gear on the video server will be deleted. If there are other viewers on the video server watching the video of the transcoded video gear in the live broadcast room at this time, then the source stream of the live broadcast room and the video queue corresponding to the transcoded video gear will always keep the latest video stream. Although the transcoded video stream is normal at this time, the time to pull the video stream corresponding to the transcoded video gear from the anchor video server will increase (for example, increase 1-2 seconds), and the increase in the video pulling time will cause the link delay calculation result to increase. Based on this, in addition to limiting the calculation of link delay to the same key frame of the source stream and the transcoded stream, this solution also sets a restriction on skipping pre-pull packets during calculation (i.e., codecGop I nfo.isNotFetchData), reducing the impact of pre-pull packets on the link delay calculation result and improving the accuracy of link delay. This solution determines the link delay when the first key frame of the source stream image group matches the second key frame of the transcoded image group corresponding to the transcoded video gear, the transcoded image group is a non-pre-pulled image group, and the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group. This ensures accurate calculation of the link delay of the video stream being transcoded on the transcoding server and downstream to the viewer video server, thereby improving the anti-jitter capability of video playback and the stability of video playback on the viewer end.
[0063] S230: Determine one or more optional video gears from one or more transcoded video gears according to the link delay and the set delay threshold.
[0064] In a possible embodiment, the video gear decision method provided by the present solution determines one or more optional video gears from one or more transcoding video gears based on the link delay and the set delay threshold, which can be: when the link delay corresponding to the transcoding video gear is less than or equal to the set delay threshold, the transcoding video gear is determined as an available video gear.
[0065] Exemplarily, for each transcoding video gear, the link delay corresponding to the transcoding video gear is compared with the set delay threshold, and when the link delay is less than or equal to the set delay threshold, the transcoding video gear is determined as an available video gear, and when the link delay is greater than the set delay threshold, there is no need to disable the corresponding transcoding video gear, and the transcoding video gear is determined as a disabled transcoding video gear. This solution determines the transcoding video gear as an available video gear when the link delay corresponding to the transcoding video gear is less than or equal to the set delay threshold, and when the link delay is greater than the set delay threshold, there is no need to disable the corresponding transcoding video gear, accurately determines the transcoding video gears that need to be disabled and optional, and the available transcoding video gears, effectively reduces the situation where adaptive gear switching is not smooth or the video buffer on the viewer side becomes smaller, and improves the anti-jitter capability of video playback and the stability of video playback on the viewer side.
[0066] In a possible embodiment, the video gear decision method provided by the present solution determines one or more optional video gears from one or more transcoding video gears based on the link delay and the set delay threshold, which can be: when the link delay corresponding to the transcoding video gear is less than or equal to the sum of the set delay threshold and the set buffer threshold, the transcoding video gear is determined as an available video gear.
[0067] Exemplarily, for each transcoding video gear, the link delay corresponding to the transcoding video gear is compared with the sum of a set delay threshold and a set buffer threshold. When the link delay is greater than the sum of the set delay threshold and the set buffer threshold, the transcoding video gear is determined as a disabled transcoding video gear. When the link delay is less than or equal to the sum of the set delay threshold and the set buffer threshold, the transcoding video gear is determined as an optional video gear, and there is no need to disable the corresponding transcoding video gear.
[0068] This solution prohibits some video gears according to the situation on the audience side. For example, if the link delay is too high at a certain video gear, and the SDK (Software Development Kit) buffer on the audience side is less than or equal to the delay, it will cause jamming. In order to ensure the smoothness of the user's video viewing, it is necessary to avoid selecting these video gears, that is, to notify the adaptive gear selection controller to prohibit the selection of these video gears when selecting the target video gear. However, low video clarity will also lead to a decline in user viewing experience. This solution introduces a set buffer threshold and sets different set buffer thresholds according to the resolution of different video gears. When the sum of the link delay and the set buffer threshold is less than or equal to the set delay threshold or the current SDK buffer size (the minimum of the two), the corresponding video gear is prohibited.
[0069] Optionally, the buffer threshold can be set based on online user data, such as observing the video viewing time, video playback freeze rate and other indicators of user groups under different difference values, and selecting the difference value with the highest user acceptance as the buffer threshold (or using ML models for data analysis and setting). Among them, the higher the resolution, the larger the corresponding buffer threshold, that is, the lower the resolution, the less likely it is to be banned, ensuring that users with poor device performance and network can maintain medium-definition viewing, balancing viewing clarity and smoothness.
[0070] This solution determines the transcoded video gear as an available video gear when the link delay corresponding to the transcoded video gear is less than or equal to the sum of the set delay threshold and the set buffer threshold, accurately determines the transcoded video gear that needs to be disabled and the optional transcoded video gear, effectively reduces the situation where adaptive gear switching is not smooth or the video buffer on the viewer side becomes smaller, and reduces frequent gear switching and gear disabling by setting the buffer threshold, avoiding the user experience being affected by the low clarity of the video gear, and better balancing the user's needs for clarity and smoothness, improving the anti-jitter capability of video playback and the stability of video playback on the viewer side.
[0071] In a possible embodiment, the video gear decision method provided by the present solution further includes: determining the set delay threshold corresponding to one or more transcoded video gears according to the resolution corresponding to the one or more transcoded video gears, before determining one or more optional video gears from one or more transcoded video gears according to the link delay and the set delay threshold, and the set delay threshold is negatively correlated with the resolution.
[0072] Optionally, different set delay thresholds can be pre-set for different resolutions, wherein different transcoding video gears correspond to different resolutions. For each transcoding video gear, determine the set delay threshold corresponding to the resolution of the transcoding video gear, compare the link delay corresponding to the transcoding video gear with the sum of the set delay threshold and the set buffer threshold, and when the link delay is greater than the sum of the set delay threshold and the set buffer threshold, determine the transcoding video gear as a disabled transcoding video gear, and when the link delay is less than or equal to the sum of the set delay threshold and the set buffer threshold, determine the transcoding video gear as an available video gear, and there is no need to disable the corresponding transcoding video gear. This solution determines the set delay threshold according to the resolution corresponding to the transcoding video gear, and determines the transcoding video gear as an available video gear when the link delay corresponding to the transcoding video gear is less than or equal to the set delay threshold, accurately determines the transcoding video gear that needs to be disabled and the optional one, effectively reduces the situation where the adaptive gear switching is not smooth or the video buffer at the viewer end becomes smaller, and improves the anti-jitter capability of video playback and the stability of video playback at the viewer end.
[0073] S240: Determine a target video gear from a source stream video gear and one or more optional video gears according to a network bandwidth and / or a video buffer size.
[0074] Exemplarily, based on the set adaptive bit rate, according to one or more combinations of network bandwidth, video buffer size, user device hardware information and decoding capability, the target video gear is determined from the source stream video gear and the one or more optional video gears determined above. It can also be that after determining one or more disabled video gears, one or more optional video gears are determined from one or more transcoded video gears according to the disabled video gears, that is, the non-disabled transcoded video gears in one or more transcoded video gears are used as optional video gears, and then according to the network bandwidth and / or video buffer size, the target video gear is determined from the source stream video gear and one or more optional video gears. This solution accurately determines the target video gear from the source stream video gear and one or more optional video gears according to one or more combinations of network bandwidth, video buffer size, user device hardware information and decoding capability, effectively reducing the situation where the adaptive gear switching is not smooth or the video buffer at the viewer end becomes smaller, thereby improving the anti-shake ability of video playback and the stability of video playback at the viewer end.
[0075] In the above, by determining one or more optional video gears from one or more transcoded video gears according to the link delay of the video stream of one or more transcoded video gears being transcoded on the transcoding server and downstream to the viewer video server and setting a delay threshold, and making an adaptive bit rate decision based on the optional video gears to obtain the target video gear, the optional video gear that can ensure the smooth progress of adaptive gear switching and reduce the size of the video buffer on the viewer end is accurately determined according to the link delay and the set delay threshold, thereby effectively improving the video gear decision effect, and enhancing the anti-jitter capability of video playback and the stability of video playback on the viewer end. At the same time, by matching the first key frame of the source stream image group with the second key frame of the transcoded image group corresponding to the transcoded video gear, the transcoded image group is a non-pre-pulled image group and the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group, the link delay is determined to ensure accurate calculation of the link delay of the video stream being transcoded on the transcoding server and downstream to the viewer's video server, thereby improving the anti-jitter capability of video playback and the stability of video playback on the viewer end, comprehensively considering the link delay and gear bit rate stratification, improving the versatility of the controller, being able to adapt to a variety of transcoding and encoding strategies, improving the user's viewing fluency, reducing the jamming caused by machine load problems, and improving the user's viewing experience.
[0076] Figure 3 is a structural diagram of a video gear decision device provided in an embodiment of the present application. Figure 3The video gear position decision device includes a delay determination module 31, a gear position determination module 32 and a gear position decision module 33.
[0077] Among them, the delay determination module 31 is configured to determine the link delay of the video stream of one or more transcoded video gears being transcoded in the transcoding server and downstream reaching the viewer video server; the gear determination module 32 is configured to determine one or more optional video gears from one or more transcoded video gears based on the link delay and the set delay threshold; the gear decision module 33 is configured to make an adaptive bit rate decision based on the optional video gear to obtain the target video gear.
[0078] In the above, by determining one or more optional video gears from one or more transcoded video gears according to the link delay of the video stream of one or more transcoded video gears being transcoded on the transcoding server and downstream to the viewer video server and setting a delay threshold, and making an adaptive bit rate decision based on the optional video gears to obtain the target video gear, the optional video gear that can ensure the smooth progress of adaptive gear switching and reduce the size of the video buffer on the viewer end is accurately determined according to the link delay and the set delay threshold, thereby effectively improving the video gear decision effect, and enhancing the anti-jitter capability of video playback and the stability of video playback on the viewer end.
[0079] In a possible embodiment, the delay determination module 31 determines the link delay of the video stream of one or more transcoded video gears being transcoded by the transcoding server and being downstream to the viewer video server, and is configured as follows:
[0080] Determine transcoded video time information of one or more transcoded video gears and source stream video time information of source stream video gears;
[0081] According to the difference between the transcoded video time information and the source stream video time information, the link delay of the video stream of one or more transcoded video gears being transcoded in the transcoding server and downstream reaching the viewer video server is determined.
[0082] In a possible embodiment, the delay determination module 31 determines the link delay of the video stream of one or more transcoded video gears being transcoded by the transcoding server and being downstream to the viewer video server, and is configured as follows:
[0083] When the first key frame of the source stream image group matches the second key frame of the transcoded image group corresponding to the transcoded video gear, the transcoded image group is a non-pre-pulled image group and the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group, determine the link delay of the transcoded video gear in transcoding on the transcoding server and downlink to the viewer video server.
[0084] In a possible embodiment, the gear determination module 32 determines one or more optional video gears from one or more transcoded video gears according to the link delay and the set delay threshold, and is configured as follows:
[0085] When the link delay corresponding to the transcoded video gear is less than or equal to the set delay threshold, the transcoded video gear is determined as an available video gear.
[0086] In a possible embodiment, the gear determination module 32 determines one or more optional video gears from one or more transcoded video gears according to the link delay and the set delay threshold, and is configured as follows:
[0087] When the link delay corresponding to the transcoded video gear is less than or equal to the sum of the set delay threshold and the set buffer threshold, the transcoded video gear is determined as an available video gear.
[0088] In a possible embodiment, before determining one or more optional video gears from one or more transcoded video gears according to the link delay and the set delay threshold, the gear determination module 32 is further configured to:
[0089] According to the resolutions corresponding to the one or more transcoded video gears, the set delay thresholds corresponding to the one or more transcoded video gears are determined, and the set delay threshold is negatively correlated with the resolution.
[0090] In a possible embodiment, the gear decision module 33 performs adaptive bit rate decision based on the optional video gear to obtain the target video gear, and is configured as follows:
[0091] Determine one or more optional video gears from one or more transcoded video gears according to the disabled video gear;
[0092] According to the network bandwidth and / or the video buffer size, a target video gear is determined from the source stream video gear and one or more optional video gears.
[0093] It is worth noting that in the embodiment of the above-mentioned video gear decision 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 achieved; 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 protection scope of the embodiments of the present application.
[0094] The embodiment of the present application also provides a video gear position decision device, which can integrate the video gear position decision device provided in the embodiment of the present application. Figure 4 Schematic diagram of a video gear decision device provided by an embodiment of the present application. Figure 4The video gear decision device includes: an input device 43, an output device 44, a memory 42 and one or more processors 41; the memory 42 is used to store one or more programs; when one or more programs are executed by one or more processors 41, the one or more processors 41 implement the video gear decision method provided in the above embodiment. The video gear decision device, equipment and computer provided above can be used to execute the video gear decision method provided in any of the above embodiments, and have corresponding functions and beneficial effects.
[0095] The embodiments of the present application also provide a non-volatile storage medium storing computer executable instructions, which are used to execute the video gear decision method provided in the above embodiments when executed by a computer processor. Of course, the non-volatile storage medium storing computer executable instructions provided in the embodiments of the present application, whose computer executable instructions are not limited to the video gear decision method provided above, can also execute the related operations in the video gear decision method provided in any embodiment of the present application. The video gear decision device, equipment and storage medium provided in the above embodiments can execute the video gear decision method provided in any embodiment of the present application. For technical details not described in detail in the above embodiments, please refer to the video gear decision method provided in any embodiment of the present application.
[0096] On the basis of the above embodiments, the embodiments of the present application also provide a computer program product. The essence of the technical solution of the present application or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer program product is stored in a storage medium, including a number of instructions for enabling a computer device, a mobile terminal or a processor therein to execute all or part of the steps of the video gear decision method provided in each embodiment of the present application.
Claims
1. A video gear decision method, characterized in that: include: Determine the link delay of the video stream of one or more transcoded video gears being transcoded by the transcoding server and downstream reaching the viewer video server; Determine one or more optional video gears from the one or more transcoded video gears according to the link delay and the set delay threshold; An adaptive bit rate decision is performed based on the optional video gear to obtain a target video gear.
2. The video gear decision method according to claim 1, characterized in that: The step of determining the link delay of a video stream of one or more transcoded video gears being transcoded by a transcoding server and then being downstream to a viewer video server comprises: Determine transcoded video time information of one or more transcoded video gears and source stream video time information of source stream video gears; According to the difference between the transcoded video time information and the source stream video time information, the link delay of the video stream of one or more transcoded video gears being transcoded in the transcoding server and downstream reaching the viewer video server is determined.
3. The video gear decision method according to claim 1, characterized in that: The step of determining the link delay of a video stream of one or more transcoded video gears being transcoded by a transcoding server and then being downstream to a viewer video server comprises: When the first key frame of the source stream image group matches the second key frame of the transcoded image group corresponding to the transcoded video gear, the transcoded image group is a non-pre-pulled image group and the second time information of the transcoded image group is greater than or equal to the first time information of the source stream image group, determine the link delay of the transcoded video gear in transcoding on the transcoding server and downlink to the viewer video server.
4. The video gear decision method according to claim 1, characterized in that: The determining one or more optional video gears from the one or more transcoded video gears according to the link delay and the set delay threshold comprises: When the link delay corresponding to the transcoding video gear is less than or equal to the set delay threshold, the transcoding video gear is determined as an optional video gear.
5. The video gear decision method according to claim 1, characterized in that: The determining one or more optional video gears from the one or more transcoded video gears according to the link delay and the set delay threshold comprises: When the link delay corresponding to the transcoded video gear is less than or equal to the sum of the set delay threshold and the set buffer threshold, the transcoded video gear is determined as an available video gear.
6. The video gear decision method according to claim 5, characterized in that: Before determining one or more optional video gears from the one or more transcoded video gears according to the link delay and the set delay threshold, the method further includes: According to the resolutions corresponding to the one or more transcoded video gears, the set delay thresholds corresponding to the one or more transcoded video gears are determined, and the set delay thresholds are negatively correlated with the resolutions.
7. The video gear decision method according to claim 1, characterized in that: The step of making an adaptive bit rate decision based on the optional video gear to obtain a target video gear includes: According to the network bandwidth and / or the video buffer size, the target video gear is determined from the source stream video gear and the one or more optional video gears.
8. A video gear decision device, characterized in that: It includes a delay determination module, a gear determination module and a gear decision module, wherein: The delay determination module is configured to determine the link delay of the video stream of one or more transcoded video gears being transcoded by the transcoding server and being downstream to the viewer video server; The gear determination module is configured to determine one or more optional video gears from the one or more transcoded video gears according to the link delay and a set delay threshold; The gear decision module is configured to perform an adaptive bit rate decision based on the optional video gear to obtain a target video gear.
9. A video gear decision device, characterized in that: include: memory and one or more processors; The memory is used to store 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 gear decision method as described in any one of claims 1-7.
10. A non-volatile storage medium storing computer executable instructions, characterized in that: The computer executable instructions are used to execute the video gear decision method as described in any one of claims 1-7 when executed by a computer processor.
11. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the video gear decision method according to any one of claims 1 to 7 is implemented.
