Data processing method, device, computer equipment and computer readable storage medium
By obtaining video staging decision data related to video playback requests, determining the video staging to be selected and generating indication information, the problem of low applicability of video staging methods in the prior art is solved, and the diversity and adaptive selection of video staging methods are realized, enriching the video staging methods and ensuring video quality.
Patent Information
- Application Number
- CN202311667428.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-06
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2043-12-06
AI Technical Summary
The existing video distribution method is carried out with fixed resolution and video gaps, with low applicability and cannot meet the diverse needs of different video playback requests.
By obtaining the video file decision data associated with the video playback request, M video file positions to be selected are determined. If the target resolution exists, the matching resolution decision data is determined from the resolution decision configuration, and indication information is generated to instruct the video sending device to issue videos according to the rules of the target video file.
It realizes the diversity and adaptive selection of video staircases, enriches the video distribution method, can adapt to various video on-demand business scenarios, and prioritizes the target resolution to ensure video quality.
Smart Images

Figure CN117768685B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a data processing method, a data processing device, a computer equipment, and a computer-readable storage medium. Background Art
[0002] With the development of computer technology, communication technology, video technology and other technologies, various video applications have emerged. People can watch videos such as movies, TV, short videos, etc. through video clients on computer devices. At present, when sending videos, the video application server usually sends videos to the video client according to the default resolution and fixed video level (such as fixed video encoding method, etc.). Such a single video sending method has low applicability. Summary of the invention
[0003] The embodiments of the present application provide a data processing method, an apparatus, a computer device, and a computer-readable storage medium, which can realize the diversity and adaptive selection of video gears, thereby enriching the video delivery method.
[0004] On the one hand, an embodiment of the present application provides a data processing method, the method comprising:
[0005] Obtaining video gear decision data associated with a video playback request;
[0006] Determine M to-be-selected video gears according to the video gear decision data; the to-be-selected video gears are used to indicate a video delivery rule, the M to-be-selected video gears correspond to M resolutions, and M is a positive integer;
[0007] If the M resolutions include a target resolution, determining matching resolution decision data that matches the video download time corresponding to the video playback request from the resolution decision configuration corresponding to the target resolution;
[0008] If it is determined according to the matching resolution decision data that the video of the target resolution is to be sent, first indication information is generated according to the target resolution and the target video gear; the target video gear is the to-be-selected video gear corresponding to the target resolution among the M to-be-selected video gears;
[0009] The first indication information is sent to a video sending device, where the first indication information is used to instruct the video sending device to send the video with the target resolution in response to the video playback request according to the video sending rule indicated by the target video level.
[0010] On the one hand, an embodiment of the present application provides a data processing device, the device comprising:
[0011] An acquisition unit, used to acquire video gear decision data associated with a video playback request;
[0012] A processing unit, configured to determine M to-be-selected video gears according to the video gear decision data; the to-be-selected video gears are used to indicate a video delivery rule, the M to-be-selected video gears correspond to M resolutions, and M is a positive integer;
[0013] The processing unit is further configured to determine, from the resolution decision configuration corresponding to the target resolution, matching resolution decision data that matches the video download time corresponding to the video playback request if the M resolutions include the target resolution;
[0014] The processing unit is further configured to generate first indication information according to the target resolution and a target video gear if it is determined to send the video of the target resolution according to the matching resolution decision data; the target video gear is a to-be-selected video gear corresponding to the target resolution among the M to-be-selected video gears;
[0015] The communication unit is used to send the first indication information to the video sending device, wherein the first indication information is used to instruct the video sending device to send the video with the target resolution in response to the video playback request according to the video sending rule indicated by the target video gear.
[0016] On the one hand, an embodiment of the present application provides a computer device, comprising: a processor, a communication interface and a memory, wherein the processor, the communication interface and the memory are interconnected, wherein the memory stores an executable program code, and the processor is used to call the executable program code to implement the data processing method provided in the embodiment of the present application.
[0017] Accordingly, an embodiment of the present application further provides a computer-readable storage medium, in which instructions are stored. When the computer-readable storage medium is executed on a computer, the computer implements the data processing method provided by the embodiment of the present application.
[0018] Accordingly, an embodiment of the present application also provides a computer program product, which includes a computer program or computer instructions, and the computer program or computer instructions are stored in a computer-readable storage medium; a processor of a computer device reads the computer program or computer instructions from the computer-readable storage medium, and the processor executes the computer program or computer instructions, so that the computer device implements the data processing method provided in the embodiment of the present application.
[0019] Using the data processing method provided in the embodiment of the present application, on the one hand, the M video gears used to indicate the video delivery rules are determined based on the video gear decision data associated with the video playback request, and do not use a fixed video gear, so that the diversity and adaptive selection of video gears can be achieved. The video gears used when delivering videos for different video playback requests will not be exactly the same, which can enrich the video delivery method and adapt to various video-on-demand business scenarios. On the other hand, when the M resolutions corresponding to the M video gears include the target resolution, the resolution decision data that matches the video delivery time is determined from the resolution decision configuration corresponding to the target resolution. If the target resolution is determined to be delivered based on the matching resolution decision data, the target resolution is determined to be selected for video delivery. In this way, when the preferentially selected target resolution meets the selection conditions, the target resolution can be preferentially selected for video delivery to meet the resolution selection requirements and ensure video quality. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0021] Figure 1a is a schematic diagram of the architecture of a data processing system exemplarily provided in this application;
[0022] Figure 1b is a schematic diagram of the architecture of another data processing system exemplarily provided by the present application;
[0023] Figure 2 It is a flowchart of a data processing method exemplarily provided in this application;
[0024] Figure 3 A video gear decision method exemplarily provided by the present application is shown;
[0025] Figure 4 A processing flow for determining resolution decision data provided by the present application is shown;
[0026] Figure 5 This is a schematic diagram of the architecture of a video gear distribution system exemplarily provided in this application;
[0027] Figure 6 A processing method of the dynamic rule engine exemplarily provided in this application is shown;
[0028] Figure 7Another processing method of the dynamic rule engine exemplarily provided in this application is shown;
[0029] Figure 8 is a structural schematic diagram of a data processing device provided in an embodiment of the present application;
[0030] Fig. 9 It is a structural diagram of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0031] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0032] The embodiment of the present application provides a data processing method to achieve the diversity and adaptive selection of video gears, thereby enriching the way of sending videos. The data processing method provided in the embodiment of the present application can be applied to a data processing system for videos. In one embodiment, if Figure 1a As shown, the data processing system includes: a video gear decision device 11, one or more video clients 12, and a video sending device 13, and the video gear decision device 11, the video client 12 and the video sending device 13 are connected through a network. In another embodiment, as Figure 1b As shown, the data processing system includes: a video gear decision device 11, one or more video clients 12, and a content delivery network (CDN) 10. The content delivery network 10 includes a source station 14, one or more video delivery devices 13, and the video delivery device 13 is a CDN node in the content delivery network 10.
[0033] The video client 12 is a video application that provides local services to users. It can be configured on portable devices such as smart phones, tablet computers, and laptops, and can also be configured on non-portable devices such as desktop computers and televisions (TV). The video gear decision device 11, the video sending device 13, and the source station 14 can be servers, such as cloud servers, data processing servers, application servers, and web servers, etc. It should be noted that the server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud storage, network services, cloud communications, CDN, and big data and artificial intelligence platforms.
[0034] When a user uses the video client 12 to watch a video (such as a movie, TV series, short video, etc.), the video client 12 sends a video playback request to the video application server according to the video information of the video to be watched selected by the user to request video data. The video application server requests the video gear decision device 11 to determine which video gear to send a video of which resolution according to the video playback request. The video gear is used to indicate the video sending rules, including indicating which encoding method is used to encode the video. The video gear decision device 11 obtains the video gear decision data associated with the video playback request, and determines M video gears to be selected according to the video gear decision data. The gear decision data is associated with the video on demand service scenario. The M video gears to be selected correspond to M resolutions, where M is a positive integer. If the M resolutions include the target resolution, the video gear decision device 11 determines the matching resolution decision data that matches the video delivery time corresponding to the video playback request from the resolution decision configuration corresponding to the target resolution. The resolution decision data is used to indicate the delivery benchmark of the video with the target resolution within a time period. If the target resolution video is determined to be delivered according to the matching resolution decision data, the video gear decision device 11 generates indication information according to the target resolution and the selected video gear corresponding to the target resolution, and sends the indication information to the video delivery device 13 to instruct the video delivery device to deliver the target resolution video to the video client 12 for the video playback request according to the video delivery rule indicated by the selected video gear corresponding to the target resolution. Among them, if it is applied to such as Figure 1b In the data processing system shown, the video sending device 13 that receives the indication information can be selected from the video sending devices included in the content distribution network 10 based on dimensional characteristics such as load, distance, network conditions, and video resource storage conditions.
[0035] By adopting the above method, on the one hand, the M video gears used to indicate the video delivery rules are determined according to the video gear decision data associated with the video playback request, and do not adopt a fixed video gear, so that the diversity and adaptive selection of video gears can be achieved, and the video gears used when delivering videos for different video playback requests will not be exactly the same, so that the delivery method of the video can be enriched and can be adapted to various video on demand business scenarios. On the other hand, when the target resolution selected first meets the selection conditions, the target resolution can be selected first for video delivery to meet the resolution selection requirements and ensure video quality.
[0036] The above briefly introduces the data processing method provided in the embodiment of the present application. The following is a detailed description of the specific implementation of the data processing method.
[0037] See also Figure 2 , Figure 2A flow chart of a data processing method provided in an embodiment of the present application. The data processing method provided in an embodiment of the present application can be implemented by the video gear decision device in the above data processing system, and the data processing method includes but is not limited to the following steps:
[0038] S201. Obtain video gear decision data associated with a video playback request.
[0039] In the embodiment of the present application, the video playback request is generated by the video client when the user uses it to watch a video (such as a movie, TV series, short video, etc.) according to the video information of the video to be watched selected by the user. The video client sends a video playback request to the video application server to request video data, and the video application server sends a video gear decision request to the video gear decision device in response to the video playback request to request the video gear decision device to determine which video gear to send what resolution video in response to the video playback request. The video gear is used to indicate the video sending rules, and may include one or more of the following indication information associated with the video sending: video encoding mode, video bit rate, super-resolution indication information, encryption indication information, and the like.
[0040] The video gear decision data is used to determine the video gear and resolution used when sending the video. The video gear decision data includes: one or more of the video metadata of the video requested to be played, the object metadata of the request object, the device metadata of the request device, and the network metadata of the request device. The video requested to be played is the video requested to be played by the video playback request, that is, the video to be watched selected by the user. The video metadata may include one or more of the video ID (Identity Document) of the video to be watched, the video name, the video category, the object information of the video publishing object, the video duration, and other information. The request object may refer to the user or the user account logged in on the client. The object metadata may include one or more of the object type of the request object (such as whether it is an important (VIP) object), the resolution selection habits, and other information. The request device includes the video client and / or the computer device where the client is located. The device metadata may include one or more of the following information: the operating system type of the computer device, the operating system version, the client version of the video client, and so on. The network metadata may include one or more of the network category (such as 4G, 5G, Wifi, etc.), network quality, network speed, network protocol, and other information of the request device.
[0041] In one embodiment, all data (or metadata) in the video gear decision data may be carried in the video play request, and the video gear decision device obtains the video gear decision data from the video play request. In another embodiment, in order to reduce the amount of data carried by the video play request and the repeated sending of part of the data (or metadata), all or part of the data that will not change in a short time (such as the operating system type) in the object metadata and device metadata may be stored in advance, and only the data that is easy to change, such as the video ID, network category, etc., need to be carried in the video play request. The video gear decision device obtains the video gear decision data from the video play request and the storage space.
[0042] S202. Determine M to-be-selected video gears according to the video gear decision data, wherein the M to-be-selected video gears correspond to M resolutions, where M is a positive integer.
[0043] In the embodiment of the present application, the video gear (including the selected video gear) is used to indicate the video delivery rule, and may include one or more of the following indication information associated with the video delivery: video encoding mode, video bit rate, super-resolution indication information, encryption indication information, etc. The video encoding mode refers to the method of converting the original video format file into another video format file through compression technology. In order to save network resources and improve the video transmission rate, the original video is usually encoded and compressed before delivery. The video encoding mode can be based on H.264 (Highly Compressed Digital Video Codec Standard) encoding mode, based on HEVC (High Efficiency Video Coding Standard, also known as H.265 or MPEG-H part 2) encoding mode, etc. The video bit rate refers to the number of data bits transmitted per unit time during data transmission. The video bit rate in the video gear may be the average bit rate, minimum bit rate or maximum bit rate in the process of indicating the video data delivery, etc. The super-resolution indication information is used to indicate whether to perform super-resolution processing on the video. Super-resolution refers to improving the resolution of the original video (or video image) by hardware or software methods. If the super-resolution indication information indicates super-resolution processing, the super-resolution indication information may also indicate the adopted super-resolution method. The encryption indication information is used to indicate whether to encrypt the video. If the encryption indication information indicates encryption processing, the encryption indication information may also indicate the adopted encryption method.
[0044] For example, the video gear includes the following information: HEVC encoding method, average bit rate 2000kbps (kilobits per second), no super-resolution processing, no encryption, that is, if it is determined to send the video according to this video gear, the original video data is encoded and compressed according to the HEVC encoding method, and the encoded and compressed video data is sent at an average bit rate of 2000kbps. For another example: the video gear includes the following information: H.264 encoding method, maximum bit rate 5000kbps, no super-resolution processing, asymmetric encryption, that is, if it is determined to send the video according to this video gear, the original video data is encoded and compressed according to the H.264 encoding method, the encoded and compressed video data is asymmetric encrypted, and the encoded, compressed and encrypted video data is sent at a bit rate not exceeding 5000kbps.
[0045] The M video gears to be selected determined by the video gear decision device according to the video gear decision data correspond to M resolutions, that is, one video gear to be selected corresponds to one resolution, and the resolutions corresponding to each video gear to be selected are different. For example, M is 3, and the M video gears to be selected include: a video gear corresponding to a 1080P resolution, a video gear corresponding to a 720P resolution, and a video gear corresponding to a 480P resolution.
[0046] In one embodiment, the video gear decision device may determine M video gears to be selected from N video gear decision configurations corresponding to N resolutions according to the video gear decision data. Each of the N resolutions corresponds to a video gear decision configuration, and the video gear decision configuration includes one or more video gears. The video gear decision configuration corresponding to each resolution may be pre-configured. N is a positive integer greater than 1, and M is a positive integer less than or equal to N. For example, N is 4, and the N resolutions include: 1080P resolution, 720P resolution, 480P resolution, and 270P resolution; M is 3, and the M resolutions include: 1080P resolution and 480P resolution. The N resolutions include a target resolution, and the target resolution may be a resolution that needs to be selected first. The target resolution may be the highest resolution among the N resolutions. The preferred selection of the target resolution is quality-first, which allows more users to watch high-quality videos. The M resolutions corresponding to the M video gears to be selected may include the target resolution, or may not include the target resolution.
[0047] In a feasible implementation, the video gear decision configuration includes one or more video gear decision strategies, and the video gear decision strategy includes a strategy expression, a video gear, and a strategy weight. The strategy expression is determined based on operators constructed for various metadata, and the metadata matches the metadata in the video gear decision data, including one or more of video metadata, object metadata, device metadata, and network metadata; Figure 3 As shown, the operator may include one or more of a two-dimensional operator, a logic operator, a hash operator, a comparison operator, etc. The strategy weight is used to indicate the priority of the corresponding video gear decision strategy.
[0048] The video gear decision device may determine M to-be-selected video gears from N video gear decision configurations corresponding to N resolutions according to the video gear decision data in the following manner:
[0049] For the target video gear decision configuration, the target video gear decision configuration is a video gear decision configuration corresponding to any resolution among N resolutions (for example, 720P resolution). According to the policy weights included in each video gear decision strategy in the target video gear decision configuration, the policy expressions included in the video gear decision strategy in the target video gear decision configuration are used in sequence to perform expression operations on the video gear decision data; the video gear included in the video gear decision strategy to which the policy expression having a first expression operation result that meets the result belongs is determined as the to-be-selected video gear corresponding to the any resolution (for example, 720P resolution); if no policy expression operation result is a meeting result, it is determined that there is no video gear matching the video gear decision data in the target video gear decision configuration, that is, there is no video gear matching the video gear decision data in the video gear corresponding to the any resolution (for example, 720P resolution).
[0050] After performing similar processing as above for the video gear decision configuration of each of the N resolutions, M to-be-selected video gears corresponding to the M resolutions may be obtained, where M is less than or equal to N.
[0051] For example, taking 720P resolution as an example, Figure 3As shown, the video gear decision configuration of 720P resolution includes video gear decision strategies 1-P with a total of P (P is a positive integer) video gear decision strategies, and the strategy weights corresponding to the video gear decision strategies 1-P are strategy weights 1-P, and the priorities indicated by the strategy weights 1-P decrease in sequence, that is, the priority indicated by strategy weight 1 is the highest, the priority indicated by strategy weight 2 is the second, and the priority indicated by strategy weight P is the lowest, that is, the priority of video gear decision strategy 1 is the highest, the priority of video gear decision strategy 2 is the second, and the priority of video gear decision strategy P is the lowest. Using strategy expression 1 in video gear decision strategy 1, expression operation is performed on the video gear decision data. If the operation result is not in compliance, then using strategy expression 2 in video gear decision strategy 2, expression operation is performed on the video gear decision data. If the operation result is in compliance, the video gear in video gear decision strategy 2 is determined as the to-be-selected video gear corresponding to the 720P resolution, and the processing flow is terminated. The processing method for other resolutions among the N resolutions is similar, and will not be repeated here.
[0052] For example, the video gear decision data includes: video duration 3min, VIP object, Andriod operating system, system version 8.0, client version 3.0, 5G network. The policy expression is: "video time≤300s"&&"user category=VIP"&&"OS=Andriod"&&"OS version≥6.0"&&"client version≥1.0"&&"network!=2G". In the above video gear decision data, the video duration 3min(180s) is less than 300s, the object is VIP, the operating system is Andriod, the system version 8.0 is greater than 6.0, the client version 3.0 is greater than 1.0, and it is a 5G network different from 2G. All the data meet the conditions indicated by the corresponding operators in the policy expression. The operation result obtained by performing the expression operation on the above video gear decision data using the above policy expression is "True", which means that the operation result is in compliance.
[0053] In other feasible implementations, no policy weight may be set for the video gear decision strategy in the video gear decision configuration, and the policy expressions in each video gear decision strategy may be used to perform expression operations on the video gear decision data respectively. If there are multiple policy expressions whose operation results are in compliance, a video gear is randomly selected from the multiple video gears corresponding to the multiple expressions to be determined as the video gear to be selected. The matching degree between the policy expressions in each video gear decision strategy and the video gear decision data may also be determined, and the video gear corresponding to the policy expression with the highest matching degree may be determined as the video gear to be selected.
[0054] S203: If the M resolutions include a target resolution, determining matching resolution decision data that matches the video delivery time corresponding to the video playback request from the resolution decision configuration corresponding to the target resolution.
[0055] In the embodiment of the present application, if there is a video gear that matches the video gear decision data in the video gear decision configuration corresponding to the target resolution among the N resolutions, then the M resolutions corresponding to the M selected video gears determined include the target resolution, otherwise, the target resolution is not included. The video delivery time corresponding to the video playback request may refer to the delivery time of the video data of the video requested to be played by the video playback request, and may be determined according to any one of the generation time, sending time and receiving time of the video playback request, and the delivery time may be the start delivery time, or the time period from the start of delivery to the completion of delivery.
[0056] The resolution decision configuration corresponding to the target resolution includes multiple sub-time periods and resolution decision data corresponding to each sub-time period, and the multiple sub-time periods are obtained by dividing the first time period. The first time period is associated with the video delivery time corresponding to the video playback request, or in other words, the video delivery time corresponding to the video playback request is included in the first time period. The video gear decision device determines the sub-time period including the video delivery time in the multiple sub-time periods, and the resolution decision data corresponding to the sub-time period including the video delivery time is the matching resolution decision data that matches the video delivery time corresponding to the video playback request.
[0057] In a feasible implementation, the multiple sub-time periods can be obtained by dividing the first time period into equal intervals according to a fixed duration. For example, the video is released at 13:02 on November 24, 2023 (or 13:02:30-13:02:50), and the first time period can be the day of November 24, 2023, or 00:00-24:00 on November 24, 2023; the day of November 24, 2023 can be divided into 288 sub-time periods at equal intervals of 5 minutes (min), including: 00:00-00:05, 00:05-00:10, 13:00-00:05, and so on. The resolution decision data corresponding to the sub-time period 13:00-00:05 is the matching resolution decision data that matches the video release time 13:02 (or 13:02:30-13:02:50).
[0058] The resolution decision data is used to indicate the benchmark for sending videos of target resolution in the corresponding sub-time period. For example, the resolution decision data corresponding to the sub-time period of 00:00-00:05 on November 24, 2023 is used to indicate the benchmark for sending videos of target resolution in the sub-time period of 00:00-00:05 on November 24, 2023. In one embodiment, the sending benchmark can be a sending ratio, that is, the feature data of the videos of target resolution sent in the corresponding sub-time period, and the ratio of the feature data of all videos sent in the corresponding sub-time period. The feature data can be the number of videos, the length of the videos, and so on. In another embodiment, the sending benchmark can be used to indicate whether to send videos of target resolution.
[0059] In a feasible embodiment, the resolution decision data is determined based on the predicted video bandwidth of the corresponding sub-time period, and the predicted video bandwidth is determined based on the video bandwidth calculation data in the reference time. The video bandwidth calculation data includes one or more of the duration of the video being sent, the average video bit rate, and the bandwidth utilization rate. The time corresponding to the first time period is later than the reference time, and the reference time includes multiple second time periods, and the duration of the second time period matches the duration of the first time period. For example, the first time period is November 24, 2023, and the reference time can be the seven days from November 17, 2023 to November 23, 2023, and any one of these seven days is the second time period. In a feasible implementation manner, the predicted video bandwidth can be determined based on the video bandwidth calculation data of the matching sub-time period in each second time period that matches the corresponding sub-time period. For example, the predicted video bandwidth of the sub-time period of 00:05-00:10 on November 24, 2023 is determined based on the video bandwidth calculation data of the time period of 00:05-00:10 on each of the seven days from November 17, 2023 to November 23, 2023. The method for determining the resolution decision data can be referred to the detailed description below and will not be repeated here.
[0060] S204: If it is determined to send the video with the target resolution according to the matching resolution decision data, first indication information is generated according to the target resolution and the target video level, where the target video level is the to-be-selected video level corresponding to the target resolution among the M to-be-selected video levels.
[0061] In a feasible embodiment, the matching resolution decision data is used to indicate the proportion of videos with target resolution that can be sent in the sub-time period including the time when the video is sent, hereinafter referred to as the sending proportion. A random value is generated according to the sending proportion. If the random value is included in the set value set, it is determined that the video with target resolution is sent; otherwise, it is determined that the video with target resolution is not sent; the set value set includes one or more set values, and the set value is used to indicate the sending of the video with target resolution. By adopting the above random method, it should be ensured that the characteristic data (number of videos or video duration) of the video with target resolution actually sent in the sub-time period (including the sub-time period when the video is sent) matches the proportion of the characteristic data of the video actually sent in the sub-time period. For example, if the sending proportion is 60% and the target resolution is 1080P, 5000 videos are actually sent in the sub-time period from 00:05 to 00:10 on November 24, 2023, then 3000 videos should be sent in 1080P.
[0062] In another feasible embodiment, the matching resolution decision data is used to indicate whether to send a video with a target resolution within a sub-time period including the time when the video is sent. If the matching resolution decision data indicates to send a video with a target resolution, it is determined to send the video with the target resolution; otherwise, it is determined not to send the video with the target resolution.
[0063] If it is determined to send a video with a target resolution according to the matching resolution decision data, first indication information is generated according to the target resolution and the target video level, and step S205 is executed. The target video level is the selected video level corresponding to the target resolution among the M selected video levels.
[0064] S205. Send the first indication information to a video sending device, where the first indication information is used to instruct the video sending device to send the video with the target resolution in response to the video playback request according to a video sending rule indicated by the target video level.
[0065] Accordingly, after receiving the first indication information sent by the video gear decision device, the video sending device obtains the video data of the video requested by the video playback request, the resolution of the video data is the target resolution, and processes the video data according to the video sending rules indicated by the target video gear, including encoding and compressing the video data according to the video encoding method indicated by the target video gear, encrypting the encoded and compressed video data, etc. After the processing of the video data is completed, the processed video data is sent to the requesting device (or the requesting client). After the requesting device (or the requesting client) performs corresponding processing on the received video data, the video with the target resolution is played on the video playback interface.
[0066] In one embodiment, if it is determined that the video of the target resolution is not to be sent according to the matching resolution decision data, a video gear to be selected can be randomly selected from the video gears to be selected except the video gear to be selected corresponding to the target resolution in the M video gears to be selected, so as to obtain a random video gear. The third indication information is generated according to the random video gear and the resolution corresponding to the random video gear. The third indication information is sent to the video sending device to instruct the video sending device to send the video of the resolution corresponding to the random video gear in response to the video playback request according to the video sending rule indicated by the random video gear. In this case, the processing method of the video sending device is similar to the above-mentioned related description, and will not be repeated here.
[0067] In one embodiment, the target resolution is the highest resolution among N resolutions. If it is determined not to send the video of the target resolution according to the matching resolution decision data, or if the M resolutions corresponding to the M video gears to be selected do not include the target resolution, then a resolution is selected from the M resolutions to obtain a selected resolution, and the selected resolution is any one of the following: the highest resolution among the M resolutions, the lowest resolution among the M resolutions, or a resolution randomly selected from the M resolutions; second indication information is generated according to the selected resolution and the selected video gear corresponding to the selected resolution among the M video gears to be selected; the second indication information is sent to the video sending device to instruct the video sending device to send the video of the selected resolution in response to the video playback request according to the video sending rules indicated by the selected video gear corresponding to the selected resolution. In this case, the processing method of the video sending device is similar to the above-mentioned related description, and will not be repeated here.
[0068] It should be noted that for short video application scenarios, the video length of short videos is short and the amount of video data is small. Usually, the video data can be sent down in a short time, that is, it can usually be sent down within the sub-time period that includes the video sending time corresponding to the matching resolution decision data. For short videos with large data volumes or movies, televisions, etc., if the video sending time is the time period from the start of video data sending to the completion of sending, and this time period spans two sub-time periods (including the first sub-time period and the second sub-time period), then it can be determined whether to send the video of the target resolution based on the resolution decision data of the first sub-time period. If it is determined to send the video of the target resolution, the video sending device is instructed to send the video in the third time period (that is, from the start of video data sending to the end of the first sub-time period) according to the video sending rules indicated by the selected video gear corresponding to the target resolution, for video playback. A video with a target resolution is sent out according to a request; whether to send out the video with the target resolution is determined according to the resolution decision data of the second sub-time period; if it is determined not to send out the video with the target resolution, the video sending device may be instructed to send out the video with a resolution corresponding to the random video gear in response to the video playback request according to the video sending rule indicated by the random video gear within the fourth time period (i.e., from the start time of the second sub-time period to the end time of sending out the video data); the random video gear is a video gear randomly selected from the M video gears to be selected except the video gear corresponding to the target resolution. The relevant processing methods can refer to the previous description, and the remaining situations can be combined according to the processing methods mentioned in the relevant descriptions above, which will not be repeated here.
[0069] Using the data processing method provided in the embodiment of the present application, on the one hand, the M video gears used to indicate the video delivery rules are determined based on the video gear decision data associated with the video playback request, and do not use a fixed video gear, so that the diversity and adaptive selection of video gears can be achieved. The video gears used when delivering videos for different video playback requests will not be exactly the same, which can enrich the video delivery method and adapt to various video-on-demand business scenarios. On the other hand, when the M resolutions corresponding to the M video gears include the target resolution, the resolution decision data that matches the video delivery time is determined from the resolution decision configuration corresponding to the target resolution. If the target resolution is determined to be delivered based on the matching resolution decision data, the target resolution is determined to be selected for video delivery. In this way, when the preferentially selected target resolution meets the selection conditions, the target resolution can be preferentially selected for video delivery to meet the resolution selection requirements and ensure video quality. On the other hand, the resolution decision data is used to indicate the benchmark for sending videos of target resolution within a time period. The resolution decision data is determined based on the predicted video bandwidth of the corresponding time period. That is to say, it is based on the predicted video bandwidth to determine whether the preferentially selected target resolution meets the selection conditions. This ensures that the bandwidth usage involved in video sending meets the set requirements.
[0070] As mentioned above, the target resolution can be the maximum resolution among N resolutions. The resolution decision configuration corresponding to the target resolution includes multiple sub-time periods and resolution decision data corresponding to each sub-time period. The multiple sub-time periods can be obtained by dividing the first time period into equal intervals according to a fixed duration. The reference time includes multiple second time periods, and the duration of the second time period matches the duration of the first time period. Figure 4 An exemplary method for determining resolution decision data is described in detail. The determination of resolution decision data (or resolution decision configuration) can be completed by the video gear decision device or by other devices. Figure 4 , Figure 4 An exemplary process for determining resolution decision data is shown, including but not limited to the following steps:
[0071] S401. For multiple second time periods included in a reference time, determine a matching sub-time period in each second time period that matches a target sub-time period. The target sub-time period is any sub-time period in multiple sub-time periods obtained by dividing a first time period.
[0072] For example, the first time period may be November 24, 2023, which is divided into 288 sub-time periods at intervals of 5 minutes, including 00:00-00:05, 00:05-00:10, 13:00-00:05, etc. The reference time may be three days from November 21, 2023 to November 23, 2023, and any day of these three days is the second time period. Taking the determination of the resolution decision data of the sub-time period of 00:05-00:10 on November 24, 2023 as an example, 00:05-00:10 on November 24, 2023 is the target sub-time period, and 00:05-00:10 on November 21, 2023, 00:05-00:10 on November 22, 2023, and 00:05-00:10 on November 23, 2023 are the matching sub-time periods.
[0073] S402: For any matching sub-time period among the multiple matching sub-time periods, obtain video bandwidth calculation data involved in the video played by the video client in the matching sub-time period.
[0074] In the embodiment of the present application, the video bandwidth calculation data includes: the duration of the video being sent, the average video bit rate, and the bandwidth utilization. For example, if the matching sub-time period is 00:05-00:10 on November 23, 2023, the video bandwidth calculation data involved in the video client playing the video within the five minutes from 00:05-00:10 on November 23, 2023 includes: the duration of the video being sent within these five minutes, or the duration of the video data being sent within these five minutes, the duration of the video being sent can also be the duration of the video playback, that is, the duration of the video playback within these five minutes; the average video bit rate of the video data being sent within these five minutes; and the bandwidth utilization within these five minutes.
[0075] In combination with the above example, the video bandwidth calculation data involved in the video client playing the video within the five minutes from 00:05 to 00:10 on November 21, 2023, the video bandwidth calculation data involved in the video client playing the video within the five minutes from 00:05 to 00:10 on November 22, 2023, and the video bandwidth calculation data involved in the video client playing the video within the five minutes from 00:05 to 00:10 on November 23, 2023 are needed.
[0076] S403: predicting the video bandwidth calculation data of the target sub-time period according to the video bandwidth calculation data corresponding to each of the multiple matching sub-time periods.
[0077] In an embodiment of the present application, based on the video bandwidth calculation data corresponding to each matching sub-time period in a plurality of matching sub-time periods, the video bandwidth calculation data of the target sub-time period is predicted, which may be: based on the video duration corresponding to each matching sub-time period in a plurality of matching sub-time periods, the duration of the video being sent in the target sub-time period is predicted; based on the average video bit rate corresponding to each matching sub-time period in a plurality of matching sub-time periods, the average video bit rate of the target sub-time period is predicted; based on the bandwidth utilization corresponding to each matching sub-time period in a plurality of matching sub-time periods, the bandwidth utilization of the target sub-time period is predicted.
[0078] In combination with the above example, the duration of video delivery in the time period of 00:05-00:10 on November 24, 2023 is predicted based on the duration of video delivery corresponding to the three time periods of 00:05-00:10 on November 21, 2023, 00:05-00:10 on November 22, 2023, and 00:05-00:10 on November 23, 2023; the average video bit rate in the time period of 00:05-00:10 on November 24, 2023 is predicted based on the average video bit rates corresponding to the above three time periods; and the bandwidth utilization in the time period of 00:05-00:10 on November 24, 2023 is predicted based on the bandwidth utilization corresponding to the above three time periods.
[0079] In a feasible implementation, the duration of the video to be sent in the target sub-time period is predicted based on the duration of the video to be sent corresponding to each of the multiple matching sub-time periods, which can be: linear programming is performed based on the duration of the video to be sent corresponding to each of the multiple matching sub-time periods, the result of the linear programming can indicate the changing trend of the duration of the video to be sent, and the duration of the video to be sent in the target sub-time period is predicted based on the result of the linear programming. In other feasible implementations, the average value of multiple durations of the videos to be sent corresponding to the multiple matching sub-time periods can be determined, or the weighted average value of multiple durations of the videos to be sent corresponding to the multiple matching sub-time periods can be determined, and the weight corresponding to the matching sub-time period closer to the target sub-time period is greater, and the duration of the video to be sent in the target sub-time period is determined based on the average value or the weighted average value. It should be noted that the prediction method of the average video bit rate and bandwidth utilization of the target sub-time period is similar, which will not be repeated here.
[0080] S404: Calculate data based on the predicted video bandwidth of the target sub-time period to determine the predicted video bandwidth of the target sub-time period.
[0081] In the embodiment of the present application, the video bandwidth calculation formula can be: video bandwidth = video sending duration (or video playback duration) × average video bit rate / bandwidth utilization / duration.
[0082] The duration refers to the duration of the target sub-time period. For example, if the target sub-time period is obtained by dividing a day into equal intervals of 5 minutes, the duration in the video bandwidth calculation formula is 5 minutes (or 360 seconds).
[0083] The duration of the delivered video, the average video bit rate and the bandwidth utilization rate of the target sub-time period predicted in step S403 are put into the above bandwidth calculation formula to obtain the predicted video bandwidth of the target sub-time period.
[0084] In a feasible embodiment, the bandwidth utilization rate may be set to a fixed value, such as 1, by default. In this case, steps S402 and S403 may not involve any processing related to the bandwidth utilization rate.
[0085] S405: Determine resolution decision data corresponding to the target sub-time period according to the predicted video bandwidth of the target sub-time period.
[0086] In an embodiment of the present application, based on the predicted video bandwidth of the target sub-time period, the proportion of videos with the target resolution that can be sent in the target sub-time period is determined without affecting the bandwidth billing, and based on the determined proportion of videos with the target resolution that can be sent in the target sub-time period, the resolution decision data corresponding to the target sub-time period is determined. Not affecting bandwidth billing may mean not exceeding the maximum available bandwidth, and an additional fee will be charged if the maximum available bandwidth is exceeded. Bandwidth billing may be in the form of 95 peak billing. The target resolution may be the maximum resolution among the above-mentioned N resolutions, such as 1080P.
[0087] In a feasible implementation manner, based on the predicted video bandwidth of the target sub-time period, the proportion of videos with the target resolution that can be sent within the target sub-time period without affecting the bandwidth billing is determined, which can be: estimating the number of videos to be sent based on the average bandwidth of videos of each resolution and the predicted video bandwidth; determining the consumed bandwidth for sending videos with the target resolution, and determining the proportion of videos with the target resolution that can be sent within the target sub-time period without affecting the bandwidth billing based on the maximum available bandwidth, the estimated number of videos to be sent, and the consumed bandwidth for sending videos with the target resolution.
[0088] For example, the maximum available bandwidth is 200Mbps, and the predicted video bandwidth for the time period of 00:05-00:10 on November 24, 2023 is 150Mbps. If the actual situation is in line with the prediction, there will be 50Mbps of bandwidth left unused, resulting in bandwidth waste. The reason for this situation may be that the number of videos sent during this time period is small and most of the videos sent are low-resolution (for example, 720P resolution, 480P resolution). At this time, while ensuring that the bandwidth billing is not affected, that is, the maximum available bandwidth of 200Mbps is not exceeded, the proportion of videos sent with high resolution (or target resolution, such as 1080P) can be appropriately increased, so that the actual video bandwidth during this time period approaches the maximum available bandwidth of 200Mbps. In this way, as many high-resolution videos as possible can be sent without adding additional costs, so as to improve the quality of the videos watched by users and improve the user experience.
[0089] This application can be applied to video on demand business scenarios, including short video on demand business scenarios. For complex video on demand business scenarios, from the user's dimension, the user's device (including: operating system type, operating system version, video client version, etc.), network environment, consumption time and the video to be watched are different. From the video processing dimension, there are various video gears (including: video encoding method, video bit rate, whether it is super-resolution, whether it is encrypted, etc.). This application can flexibly and intelligently match the most suitable video gear and resolution, and improve the quality of the video watched by the user as much as possible without adding additional costs, and improve the user experience. This application is based on intelligent rules to achieve video gear matching, and is mainly used in the video gear corresponding to 1080P resolution. Using a prediction algorithm, according to the historical (a period of time before the current time) video consumption (download video duration, average video bit rate, bandwidth utilization, etc.), predict the bandwidth of each time period in the future, and calculate how much proportion of 1080 resolution video can be sent without affecting bandwidth billing based on the predicted bandwidth. Based on this calculation result, the distribution rules for the video levels corresponding to 1080P resolution in different time periods are generated. The intelligent rule engine module will periodically load and understand the above generated rules, and control the distribution ratio of 1080P resolution videos in each time period in real time, so as to achieve the distribution of as many 1080P resolution videos as possible without affecting bandwidth billing.
[0090] See also Figure 5 , Figure 5 The schematic diagram of the architecture of the video gear distribution system provided in the embodiment of the present application. The video gear distribution system is proposed based on the data processing method provided in the embodiment of the present application. Figure 5 As shown, the video gear distribution system includes:
[0091] Control layer: responsible for the overall control of video delivery logic. The control layer includes metadata module, static rule engine module, intelligent rule engine module and CDN scheduling module.
[0092] Metadata module: used to encapsulate the multi-dimensional data required for video gear and resolution decision-making, including video metadata, object (or user) metadata, device metadata, and network metadata. After being processed by the metadata module, the input parameters of the rule engine are generated.
[0093] Static rule engine module: responsible for static rule management and pre-decision making based on metadata input. The processing method may correspond to the above step S202, including: according to the video gear decision data, determining M video gears to be selected from N video gear decision configurations corresponding to N resolutions. Each of the N resolutions corresponds to a video gear decision configuration, and the video gear decision configuration includes one or more video gears, and the video gear decision configuration corresponding to each resolution may be pre-configured.
[0094] Intelligent rule engine module: responsible for dynamically generating control rules based on the input historical data, and loading these rules into the decision submodule for the decision submodule to make decisions. The processing method can correspond to the above steps S401-S405 to determine the resolution decision data of each time period, and the above-mentioned step of determining whether to send the target resolution video according to the matching resolution decision data.
[0095] The intelligent rule engine module includes a dynamic rule engine. The main function of the dynamic rule engine is to dynamically load and parse the results of the prediction algorithm output into strategies, make matching decisions based on the strategies, and output the corresponding video gear and resolution delivery strategies. It mainly includes the Strategy Manager module and the Strategy Decision module. Figure 6 As shown in the figure, the input of the Strategy Manager module is the prediction data output by the prediction algorithm. After the module's dynamic rule loading, dynamic rule parsing, and strategy local cache construction, the strategy data structure that the Strategy Decision module can understand is output. The strategy data structure that the Strategy Manager module finally outputs is as follows:
[0096] public class StrategyInfo{
[0097] private long startTime; / / Strategy effective start time
[0098] private long endTime; / / The time when the policy takes effect
[0099] private double percentage; / / 1080P resolution delivery percentage
[0100] private int predictionType; / / Prediction type
[0101] }
[0102] like Figure 7 As shown in the figure, the Strategy Decision module will output the final delivery decision based on the input existing strategy and specific broadcast control request parameters. In specific application scenarios, it can output whether the request can be delivered at 1080P level. The 1080P level means delivering 1080P resolution video according to the video level corresponding to 1080P resolution.
[0103] CDN scheduling module: responsible for the final CDN scheduling of the video level and resolution to be delivered, including dynamic scheduling and fixed replacement of some business scenarios.
[0104] Data layer: responsible for providing various data required by the control layer and maintaining the cache.
[0105] Monitoring layer: responsible for full-link service quality and business logic monitoring and log reporting.
[0106] The video gear distribution system (or intelligent rule engine module) implemented in this application based on the prediction algorithm and dynamic rule engine can more intelligently and flexibly adjust the logic of video gear and resolution distribution, and iterate rules faster, thereby optimizing user consumption experience and cost.
[0107] See also Figure 8 , Figure 8 A structural diagram of a data processing device provided in an embodiment of the present application. The data processing device described in the embodiment of the present application corresponds to the video gear decision device described above, and the data processing device includes:
[0108] The acquisition unit 801 is used to acquire video gear decision data associated with the video playback request;
[0109] The processing unit 802 is used to determine M to-be-selected video gears according to the video gear decision data; the to-be-selected video gears are used to indicate a video delivery rule, and the M to-be-selected video gears correspond to M resolutions, where M is a positive integer;
[0110] The processing unit 802 is further configured to determine, from the resolution decision configuration corresponding to the target resolution, matching resolution decision data that matches the video download time corresponding to the video playback request if the M resolutions include the target resolution;
[0111] The processing unit 802 is further configured to generate first indication information according to the target resolution and the target video level if it is determined to send the video of the target resolution according to the matching resolution decision data; the target video level is the video level to be selected corresponding to the target resolution among the M video levels to be selected;
[0112] The communication unit 803 is used to send the first indication information to the video sending device, where the first indication information is used to instruct the video sending device to send the video with the target resolution in response to the video playback request according to the video sending rule indicated by the target video gear.
[0113] In one embodiment, the resolution decision configuration includes multiple sub-time periods and resolution decision data corresponding to each sub-time period, the resolution decision data is used to indicate a benchmark for sending the video of the target resolution in the corresponding sub-time period, the resolution decision data is determined based on a predicted video bandwidth of the corresponding sub-time period, and the predicted video bandwidth is determined based on video bandwidth calculation data in a reference time; the multiple sub-time periods are obtained by dividing a first time period, and the time corresponding to the first time period is later than the reference time.
[0114] In one embodiment, the reference time includes a plurality of second time periods, and the processing unit 802 is further configured to:
[0115] Determine a matching sub-time period in each of the second time periods that matches the target sub-time period, where the target sub-time period is any sub-time period in the multiple sub-time periods; for any matching sub-time period in the multiple matching sub-time periods, obtain video bandwidth calculation data involved in a video client playing a video in the any matching sub-time period; predict video bandwidth calculation data of the target sub-time period based on the video bandwidth calculation data corresponding to each of the multiple matching sub-time periods; determine a predicted video bandwidth of the target sub-time period based on the predicted video bandwidth calculation data of the target sub-time period; and determine resolution decision data corresponding to the target sub-time period based on the predicted video bandwidth calculation data of the target sub-time period.
[0116] In one embodiment, the video bandwidth calculation data includes: the duration of the sent video, the average video bit rate and the bandwidth utilization rate; the processing unit 802 is specifically used to:
[0117] According to the duration of the downloaded videos corresponding to each of the multiple matching sub-time periods, the duration of the downloaded videos in the target sub-time period is predicted; according to the average video bit rate corresponding to each of the multiple matching sub-time periods, the average video bit rate of the target sub-time period is predicted; according to the bandwidth utilization corresponding to each of the multiple matching sub-time periods, the bandwidth utilization of the target sub-time period is predicted.
[0118] In one embodiment, the processing unit 802 is specifically configured to:
[0119] According to the predicted video bandwidth of the target sub-time period, determine the proportion of videos with the target resolution that can be sent within the target sub-time period without affecting bandwidth billing; according to the proportion of videos with the target resolution that can be sent within the target sub-time period, determine the resolution decision data corresponding to the target sub-time period.
[0120] In one embodiment, the sub-time period corresponding to the matching resolution decision data is a sub-time period including the video delivery time among the multiple sub-time periods, and the matching resolution decision data is used to indicate the proportion of videos with the target resolution that can be delivered in the sub-time period including the video delivery time. The processing unit 802 is further used to:
[0121] A random value is generated based on the proportion of videos of the target resolution that can be sent in the sub-time period including the video sending time; if the random value is included in a set of set values, it is determined to send the video of the target resolution; the set of set values includes one or more set values, and the set values are used to indicate the sending of the video of the target resolution.
[0122] In one embodiment, the processing unit 802 is specifically configured to:
[0123] According to the video gear decision data, M video gears to be selected are determined from N video gear decision configurations corresponding to N resolutions; wherein the N resolutions include the target resolution, each of the N resolutions corresponds to a video gear decision configuration, and the video gear decision configuration includes one or more video gears; N is a positive integer greater than 1, and M is a positive integer less than or equal to N.
[0124] In one embodiment, the video gear decision data includes: one or more of the video metadata of the video requested to be played, the object metadata of the requested object, the device metadata of the requested device, and the network metadata of the requested device; the video gear decision configuration includes one or more video gear decision strategies, and the video gear decision strategy includes a strategy expression, a video gear and a strategy weight, and the strategy expression is determined according to the operator constructed for each type of metadata. The processing unit 802 is specifically used to:
[0125] According to the policy weights included in each video gear decision strategy in the target video gear decision configuration, the policy expressions included in the video gear decision strategy in the target video gear decision configuration are used in turn to perform expression operations on the video gear decision data; the target video gear decision configuration is a video gear decision configuration corresponding to any one of the N resolutions; the video gear included in the video gear decision strategy to which the policy expression having the first expression operation result meeting the result belongs is determined as the to-be-selected video gear corresponding to any one of the resolutions.
[0126] In one embodiment, the target resolution is the highest resolution among the N resolutions, and the processing unit 802 is further configured to:
[0127] If the target resolution is not included in the M resolutions, a resolution is selected from the M resolutions to obtain a selected resolution, where the selected resolution is any one of the following: the highest resolution among the M resolutions, the lowest resolution among the M resolutions, or a resolution randomly selected from the M resolutions; and second indication information is generated according to the selected resolution and the to-be-selected video gear corresponding to the selected resolution;
[0128] The communication unit 803 is also used to send the second indication information to the video sending device, and the second indication information is used to instruct the video sending device to send the video of the selected resolution in response to the video playback request according to the video sending rule indicated by the selected video gear corresponding to the selected resolution.
[0129] It can be understood that the functions of each functional unit of the data processing device proposed in the embodiment of the present application can be specifically implemented according to the method in the above method embodiment, and its specific implementation process can refer to the relevant description in the above method embodiment, which will not be repeated here.
[0130] In a feasible embodiment, the data processing device provided in the embodiment of the present application can be implemented by software or by a combination of software and hardware.
[0131] Using the data processing device provided by the embodiment of the present application, on the one hand, the M video gears used to indicate the video delivery rules are determined according to the video gear decision data associated with the video playback request, and do not use a fixed video gear, so that the diversity and adaptive selection of video gears can be achieved. The video gears used when delivering videos for different video playback requests will not be exactly the same, which can enrich the video delivery method and adapt to various video-on-demand business scenarios. On the other hand, when the M resolutions corresponding to the M video gears include the target resolution, the resolution decision data that matches the video delivery time is determined from the resolution decision configuration corresponding to the target resolution. If the target resolution is determined to be delivered according to the matching resolution decision data, the target resolution is determined to be selected for video delivery. In this way, when the preferentially selected target resolution meets the selection conditions, the target resolution can be preferentially selected for video delivery to meet the resolution selection requirements and ensure video quality.
[0132] See also Fig. 9 , Fig. 9 A schematic diagram of the structure of a computer device provided in an embodiment of the present application. The computer device described in the embodiment of the present application corresponds to the video gear decision device and data processing device described above, and the computer device includes: a processor 901, a communication interface 902, and a memory 903. Among them, the processor 901, the communication interface 902, and the memory 903 can be connected via a bus or other means, and the embodiment of the present application takes the connection via a bus as an example.
[0133] Among them, the processor 901 (or CPU (Central Processing Unit)) is the computing core and control core of the computer device, which can parse various instructions in the computer device and process various data of the computer device. For example, the CPU can transmit various interactive data between the internal structures of the computer device, and so on. The communication interface 902 may optionally include a standard wired interface, a wireless interface (such as Wi-Fi, a mobile communication interface, etc.), which is controlled by the processor 901 for sending and receiving data. The memory 903 (Memory) is a memory device in the computer device for storing programs and data. It can be understood that the memory 903 here can include both the built-in memory of the computer device and the extended memory supported by the computer device. The memory 903 provides a storage space, which stores the operating system of the computer device, which may include but is not limited to: Android system, iOS system, Windows Phone system, etc., and this application does not limit this.
[0134] In the embodiment of the present application, the processor 901 performs the following operations by running the executable program code in the memory 903:
[0135] The video gear decision data associated with the video playback request is obtained through the communication interface 902; M video gears to be selected are determined according to the video gear decision data; the video gears to be selected are used to indicate video sending rules, and the M video gears to be selected correspond to M resolutions, where M is a positive integer; if the M resolutions include a target resolution, then the matching resolution decision data that matches the video sending time corresponding to the video playback request is determined from the resolution decision configuration corresponding to the target resolution; if it is determined to send the video with the target resolution according to the matching resolution decision data, then the first indication information is generated according to the target resolution and the target video gear; the target video gear is the video gear to be selected corresponding to the target resolution among the M video gears to be selected; the first indication information is sent to the video sending device through the communication interface 902, and the first indication information is used to instruct the video sending device to send the video with the target resolution for the video playback request according to the video sending rules indicated by the target video gear.
[0136] In one embodiment, the resolution decision configuration includes multiple sub-time periods and resolution decision data corresponding to each sub-time period, the resolution decision data is used to indicate a benchmark for sending the video of the target resolution in the corresponding sub-time period, the resolution decision data is determined based on a predicted video bandwidth of the corresponding sub-time period, and the predicted video bandwidth is determined based on video bandwidth calculation data in a reference time; the multiple sub-time periods are obtained by dividing a first time period, and the time corresponding to the first time period is later than the reference time.
[0137] In one embodiment, the reference time includes multiple second time periods, and the processor 901 is further used to: determine a matching sub-time period in each of the second time periods that matches the target sub-time period, where the target sub-time period is any sub-time period in the multiple sub-time periods; for any matching sub-time period in the multiple matching sub-time periods, obtain video bandwidth calculation data involved in the video client playing the video in the any matching sub-time period; predict the video bandwidth calculation data of the target sub-time period based on the video bandwidth calculation data corresponding to each matching sub-time period in the multiple matching sub-time periods; determine the predicted video bandwidth of the target sub-time period based on the predicted video bandwidth calculation data of the target sub-time period; and determine the resolution decision data corresponding to the target sub-time period based on the predicted video bandwidth calculation data of the target sub-time period.
[0138] In one embodiment, the video bandwidth calculation data includes: a duration of a sent video, an average video bit rate, and a bandwidth utilization rate; when the processor 901 predicts the video bandwidth calculation data of the target sub-time period according to the video bandwidth calculation data corresponding to each matching sub-time period in the multiple matching sub-time periods, it is specifically used to: predict the duration of a sent video of the target sub-time period according to the duration of a sent video corresponding to each matching sub-time period in the multiple matching sub-time periods; predict the average video bit rate of the target sub-time period according to the average video bit rate corresponding to each matching sub-time period in the multiple matching sub-time periods; and predict the bandwidth utilization rate of the target sub-time period according to the bandwidth utilization rate corresponding to each matching sub-time period in the multiple matching sub-time periods.
[0139] In one embodiment, when the processor 901 determines the resolution decision data corresponding to the target sub-time period based on the predicted video bandwidth of the target sub-time period, it is specifically used to: determine the proportion of videos with the target resolution that can be sent within the target sub-time period without affecting bandwidth billing based on the predicted video bandwidth of the target sub-time period; determine the resolution decision data corresponding to the target sub-time period based on the proportion of videos with the target resolution that can be sent within the target sub-time period.
[0140] In one embodiment, the sub-time period corresponding to the matching resolution decision data is a sub-time period among the multiple sub-time periods that includes the video sending time, and the matching resolution decision data is used to indicate the proportion of videos with the target resolution that can be sent within the sub-time period that includes the video sending time. The processor 901 is also used to: generate a random value based on the proportion of videos with the target resolution that can be sent within the sub-time period that includes the video sending time; if the random value is included in a set value set, determine to send the video with the target resolution; the set value set includes one or more set values, and the set value is used to indicate the sending of the video with the target resolution.
[0141] In one embodiment, when the processor 901 determines M video gears to be selected according to the video gear decision data, it is specifically used to: determine M video gears to be selected from N video gear decision configurations corresponding to N resolutions according to the video gear decision data; wherein the N resolutions include the target resolution, each of the N resolutions corresponds to a video gear decision configuration, and the video gear decision configuration includes one or more video gears; N is a positive integer greater than 1, and M is a positive integer less than or equal to N.
[0142] In one embodiment, the video gear decision data includes: one or more of: video metadata of the video requested to be played, object metadata of the requested object, device metadata of the requested device, and network metadata of the requested device; the video gear decision configuration includes one or more video gear decision strategies, and the video gear decision strategy includes a strategy expression, a video gear, and a strategy weight, and the strategy expression is determined based on operators constructed for each type of metadata.
[0143] When the processor 901 determines M to-be-selected video gears from N video gear decision configurations corresponding to N resolutions according to the video gear decision data, it is specifically used to: perform expression operations on the video gear decision data according to the policy weights included in each video gear decision strategy in the target video gear decision configuration, using the policy expressions included in the video gear decision strategy in the target video gear decision configuration in sequence; the target video gear decision configuration is a video gear decision configuration corresponding to any one of the N resolutions; and the video gear included in the video gear decision strategy to which the policy expression having the first expression operation result meeting the result belongs is determined as the to-be-selected video gear corresponding to any one of the resolutions.
[0144] In one embodiment, the target resolution is the highest resolution among the N resolutions, and the processor 901 is also used to: if the target resolution is not included in the M resolutions, select a resolution from the M resolutions to obtain a selected resolution, and the selected resolution is any one of the following: the highest resolution among the M resolutions, the lowest resolution among the M resolutions, and a resolution randomly selected from the M resolutions; generate second indication information according to the selected resolution and the selected video gear corresponding to the selected resolution; send the second indication information to the video sending device through the communication interface 902, and the second indication information is used to instruct the video sending device to send the video of the selected resolution in response to the video playback request according to the video sending rule indicated by the selected video gear corresponding to the selected resolution.
[0145] In a specific implementation, the processor 901, communication interface 902 and memory 903 described in the embodiment of the present application can execute the implementation method of the video gear decision device described in the data processing method provided in the embodiment of the present application, and can also execute the implementation method of the data processing device provided in the embodiment of the present application, which will not be repeated here.
[0146] Using the computer device provided by the embodiment of the present application, on the one hand, the M video gears used to indicate the video delivery rules are determined according to the video gear decision data associated with the video playback request, and do not use a fixed video gear, so that the diversity and adaptive selection of video gears can be achieved. The video gears used when delivering videos for different video playback requests will not be exactly the same, so that the video delivery method can be enriched and can be adapted to various video-on-demand business scenarios. On the other hand, when the M resolutions corresponding to the M video gears include the target resolution, the resolution decision data that matches the video delivery time is determined from the resolution decision configuration corresponding to the target resolution. If the target resolution is determined to be delivered according to the matching resolution decision data, the target resolution is determined to be selected for video delivery. In this way, when the preferentially selected target resolution meets the selection conditions, the target resolution can be preferentially selected for video delivery to meet the resolution selection requirements and ensure video quality.
[0147] The embodiment of the present application also provides a computer-readable storage medium, in which computer instructions are stored, and when the computer is run on a computer, the computer implements the data processing method provided by the embodiment of the present application. The specific implementation method can be referred to the above description, and will not be repeated here.
[0148] The embodiment of the present application also provides a computer program product, which includes a computer program or a computer instruction, and the computer program or the computer instruction is stored in a computer-readable storage medium. The processor of the computer device reads the computer program or the computer instruction from the computer-readable storage medium, and the processor executes the computer program or the computer instruction, so that the computer device implements the data processing method provided in the embodiment of the present application. The specific implementation method can be referred to the above description, which will not be repeated here.
[0149] It should be noted that the relevant data collection and processing in this application should be strictly in accordance with the requirements of relevant laws and regulations when applied in examples, and the informed consent or separate consent of the subject of personal information should be obtained, and the subsequent data use and processing should be carried out within the scope of authorization of laws and regulations and the subject of personal information. For the aforementioned method embodiments, for the sake of simple description, they are all expressed as a series of action combinations, but those skilled in the art should be aware that this application is not limited by the described order of actions, because according to this application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by this application.
[0150] A person skilled in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0151] The above disclosure is only part of the embodiments of the present application, which certainly cannot be used to limit the scope of rights of the present application. Therefore, equivalent changes made according to the claims of the present application are still within the scope covered by the present application.
Claims
1. A data processing method, characterized in that: The method comprises: Obtaining video gear decision data associated with a video playback request; According to the strategy weights included in each video gear decision strategy in the target video gear decision configuration, the strategy expressions included in the video gear decision strategy in the target video gear decision configuration are used in sequence to perform expression operations on the video gear decision data; wherein the target video gear decision configuration is a video gear decision configuration corresponding to any one of N resolutions, the N resolutions include the target resolution, and N is a positive integer greater than 1; The video gear included in the video gear decision strategy to which the strategy expression to which the first expression operation result conforms is belongs is determined as the to-be-selected video gear corresponding to any one of the resolutions, so as to obtain M to-be-selected video gears; M is a positive integer less than or equal to N, the to-be-selected video gear is used to indicate a video delivery rule, and the M to-be-selected video gears correspond to M resolutions; If the M resolutions include the target resolution, determining matching resolution decision data that matches the video download time corresponding to the video playback request from the resolution decision configuration corresponding to the target resolution; If it is determined according to the matching resolution decision data that the video of the target resolution is to be sent, first indication information is generated according to the target resolution and the target video gear; the target video gear is the to-be-selected video gear corresponding to the target resolution among the M to-be-selected video gears; The first indication information is sent to a video sending device, where the first indication information is used to instruct the video sending device to send the video with the target resolution in response to the video playback request according to the video sending rule indicated by the target video level.
2. The method according to claim 1, characterized in that The resolution decision configuration includes multiple sub-time periods and resolution decision data corresponding to each sub-time period, the resolution decision data is used to indicate the benchmark for sending the video of the target resolution in the corresponding sub-time period, the resolution decision data is determined based on the predicted video bandwidth of the corresponding sub-time period, and the predicted video bandwidth is determined based on the video bandwidth calculation data in the reference time; the multiple sub-time periods are obtained by dividing the first time period, and the time corresponding to the first time period is later than the reference time.
3. The method according to claim 2, characterized in that The reference time includes a plurality of second time periods, and the method further includes: Determine a matching sub-time period in each of the second time periods that matches a target sub-time period, wherein the target sub-time period is any sub-time period in the plurality of sub-time periods; For any matching sub-time period among the multiple matching sub-time periods, obtaining video bandwidth calculation data involved in the video client playing the video in the any matching sub-time period; predicting the video bandwidth calculation data of the target sub-time period according to the video bandwidth calculation data corresponding to each matching sub-time period in the multiple matching sub-time periods; Determine the predicted video bandwidth of the target sub-time period according to the predicted video bandwidth calculation data of the target sub-time period; The resolution decision data corresponding to the target sub-time period is determined according to the predicted video bandwidth of the target sub-time period.
4. The method according to claim 3, characterized in that The video bandwidth calculation data includes: the duration of the video being sent, the average video bit rate and the bandwidth utilization rate; The predicting the video bandwidth calculation data of the target sub-time period according to the video bandwidth calculation data corresponding to each of the multiple matching sub-time periods includes: Predicting the duration of the video to be delivered in the target sub-time period according to the duration of the delivered video corresponding to each of the multiple matching sub-time periods; Predicting the average video bit rate of the target sub-time period according to the average video bit rate corresponding to each matching sub-time period in the multiple matching sub-time periods; The bandwidth utilization rate of the target sub-time period is predicted according to the bandwidth utilization rate corresponding to each matching sub-time period in the multiple matching sub-time periods.
5. The method according to claim 3 or 4, characterized in that The determining, according to the predicted video bandwidth of the target sub-time period, resolution decision data corresponding to the target sub-time period includes: Determining, based on the predicted video bandwidth of the target sub-time period, a proportion of videos of the target resolution that can be delivered within the target sub-time period without affecting bandwidth billing; The resolution decision data corresponding to the target sub-time period is determined according to the proportion of videos with the target resolution that can be delivered within the target sub-time period.
6. The method according to claim 5, characterized in that The sub-time period corresponding to the matching resolution decision data is a sub-time period including the video delivery time among the multiple sub-time periods, and the matching resolution decision data is used to indicate the proportion of videos with the target resolution that can be delivered in the sub-time period including the video delivery time. The method further includes: Generate a random value according to the proportion of videos with the target resolution that can be delivered in the sub-time period including the video delivery time; If the random value is included in the set of set values, it is determined to send the video with the target resolution; the set of set values includes one or more set values, and the set values are used to indicate to send the video with the target resolution.
7. The method according to any one of claims 1 to 4, characterized in that: Each of the N resolutions corresponds to a video gear decision configuration, and the video gear decision configuration includes one or more video gears.
8. The method according to claim 7, characterized in that The video gear decision data includes: one or more of: video metadata of the video requested to be played, object metadata of the requested object, device metadata of the requested device, and network metadata of the requested device; the video gear decision configuration includes one or more video gear decision strategies, and the video gear decision strategy includes a strategy expression, a video gear and a strategy weight, and the strategy expression is determined based on operators constructed for each type of metadata.
9. The method according to claim 1, characterized in that The target resolution is the highest resolution among the N resolutions, and the method further includes: If the target resolution is not included in the M resolutions, a resolution is selected from the M resolutions to obtain a selected resolution, where the selected resolution is any one of the following: the highest resolution among the M resolutions, the lowest resolution among the M resolutions, or a resolution randomly selected from the M resolutions; Generate second indication information according to the selected resolution and the to-be-selected video level corresponding to the selected resolution; The second indication information is sent to the video sending device, where the second indication information is used to instruct the video sending device to send the video with the selected resolution in response to the video playback request according to the video sending rule indicated by the selected video gear corresponding to the selected resolution.
10. A data processing device, characterized in that: The device comprises: An acquisition unit, used to acquire video gear decision data associated with a video playback request; A processing unit, configured to perform expression operations on the video gear decision data according to the strategy weights included in each video gear decision strategy in the target video gear decision configuration, and sequentially using the strategy expressions included in the video gear decision strategy in the target video gear decision configuration; wherein the target video gear decision configuration is a video gear decision configuration corresponding to any one of N resolutions, wherein the N resolutions include the target resolution, and N is a positive integer greater than 1; The processing unit is further used to determine the video gear included in the video gear decision strategy to which the strategy expression to which the first expression operation result conforms to the result belongs as the to-be-selected video gear corresponding to any one of the resolutions, so as to obtain M to-be-selected video gears; M is a positive integer less than or equal to N, and the M to-be-selected video gears correspond to M resolutions; The processing unit is further configured to determine, from the resolution decision configuration corresponding to the target resolution, matching resolution decision data that matches the video download time corresponding to the video playback request if the M resolutions include the target resolution; The processing unit is further configured to generate first indication information according to the target resolution and a target video gear if it is determined to send the video of the target resolution according to the matching resolution decision data; the target video gear is a to-be-selected video gear corresponding to the target resolution among the M to-be-selected video gears; The communication unit is used to send the first indication information to the video sending device, wherein the first indication information is used to instruct the video sending device to send the video with the target resolution in response to the video playback request according to the video sending rule indicated by the target video gear.
11. A computer device, characterized in that: include: A processor, a communication interface and a memory, wherein the processor, the communication interface and the memory are interconnected, wherein the memory stores an executable program code, and the processor is used to call the executable program code to implement the data processing method according to any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, which, when executed on a computer, enable the computer to implement the data processing method according to any one of claims 1 to 9.
13. A computer program product, characterized in that The computer program product includes a computer program or computer instructions, which are stored in a computer-readable storage medium; a processor of a computer device reads the computer program or computer instructions from the computer-readable storage medium, and the processor executes the computer program or computer instructions, so that the computer device implements the data processing method as described in any one of claims 1 to 9.
Citation Information
Patent Citations
Method, device and system for reducing peak video-on-demand CDN bandwidth
CN114422860A
Video issuing method and device, server and medium
CN115065846A