Event live broadcast delay acquisition method and device, medium and electronic equipment
By obtaining the event live broadcast latency through client-side frame decoding and structural similarity calculation, the problem of unmonitored live broadcast latency was solved, thus improving viewer retention rate.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-09
- Publication Date
- 2026-03-24
AI Technical Summary
In live game tournaments, the inability to effectively monitor and test live stream latency leads to a decrease in viewer retention rates on live streaming platforms.
By acquiring the live stream and data stream from the client, decomposing frames using a preset frame rate and calculating structural similarity, the frame difference is obtained to determine the live stream latency.
It effectively tested the latency of live event broadcasts, improved the audience retention rate of the live streaming platform, and saved manpower without the need for manual intervention.
Smart Images

Figure CN115883863B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of network live streaming technology, and in particular to a method, apparatus, medium, and electronic device for obtaining the latency of live sports events. Background Technology
[0002] Live streaming refers to the technology by which streamers share live audio and video streams with viewers online through live streaming platforms. With the help of open and shared live streaming platforms, people can more easily showcase their talents. During talent shows, viewers can express their appreciation for the streamer by participating in live stream interactions. Streamers who are popular with viewers can receive a share of the revenue from the live streaming platform and earn income. Because live streaming is not limited by the streamer's education level or the location of the live stream, ordinary people can find employment through live streaming, effectively boosting social employment.
[0003] In online live streaming, hosts can broadcast events, such as game tournaments. In game tournament live streams, real-time performance is particularly crucial because high latency reduces viewer retention on the streaming platform. Therefore, monitoring and testing of latency is necessary. However, since streaming platforms cannot pinpoint the source of the game tournament broadcast, they cannot effectively test latency, thus hindering effective monitoring and adjustment of real-time performance, which also reduces viewer retention. Summary of the Invention
[0004] To overcome the problems existing in related technologies, this application provides a method, device, medium and electronic device for obtaining the latency of live sports events, which can effectively test the latency of live sports events and improve the audience retention rate of live streaming platforms.
[0005] According to a first aspect of the embodiments of this application, a method for obtaining the delay of live sports broadcasts is provided, comprising the following steps:
[0006] When the client plays the live event footage of the event data stream for a period of time longer than a preset time, the first live event footage currently being played by the client and the first live event data stream that has been retrieved are obtained; the first live event data stream is the live event data stream accessed by the broadcast control station.
[0007] The first event live stream data stream is deframed according to a preset frame rate to obtain several frames of the second event live stream.
[0008] Calculate the structural similarity between the first live event frame and each frame of the second live event frame in the first live event data stream; select the second live event frame with the greatest structural similarity as the third live event frame;
[0009] The frame difference between the third live event frame and the last frame of the second live event frame in the first live event data stream is obtained, and the live event delay is obtained based on the frame difference and the preset frame rate.
[0010] According to a second aspect of the embodiments of this application, a device for obtaining the delay of live sports broadcasts is provided, comprising:
[0011] The live data acquisition module is used to acquire the first live event frame currently being played by the client and the first live event data stream that has already been retrieved when the time for the client to play the live event frame of the live event data stream exceeds a preset time; the first live event data stream is the live event data stream accessed by the broadcast control station.
[0012] The data stream deframe module is used to deframe the first event live data stream according to a preset frame rate to obtain several frames of the second event live screen.
[0013] The image matching module is used to calculate the structural similarity between the first live event image and each frame of the second live event image in the first live event data stream; and to select the second live event image with the greatest structural similarity as the third live event image.
[0014] The live broadcast latency acquisition module is used to acquire the frame difference between the third live broadcast frame and the last frame of the second live broadcast frame in the first live broadcast data stream, and to obtain the live broadcast latency based on the frame difference and the preset frame rate.
[0015] According to a third aspect of the embodiments of this application, an electronic device is provided, including a processor and a memory; the memory stores a computer program adapted to be loaded by the processor and executed as described above for obtaining the live event delay.
[0016] According to a fourth aspect of the embodiments of this application, a computer-readable storage medium is provided, on which a computer program is stored, characterized in that, when the computer program is executed by a processor, it implements the event live broadcast delay acquisition method as described above.
[0017] In this embodiment, when the time for the client to play the live event footage of the event data stream exceeds a preset time, the system acquires the first live event footage currently being played by the client and the first live event data stream that has already been retrieved; it then deframes the first live event data stream according to a preset frame rate to obtain several frames of the second live event footage; it compares the first live event footage with each frame of the second live event footage in the first live event data stream to obtain the second live event footage that best matches the first live event footage, which is then used as the third live event footage; it obtains the frame difference between the third live event footage and the last frame of the second live event footage in the first live event data stream; and based on the frame difference and the preset frame rate, it obtains the event live event latency, thereby achieving effective testing of the event live event latency. Furthermore, it requires no manual intervention, saving manpower and improving the audience retention rate of the live streaming platform. It also eliminates the need for additional development for the broadcaster and viewer clients, making it applicable to various live streaming products.
[0018] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application.
[0019] To better understand and implement this invention, the following detailed description is provided in conjunction with the accompanying drawings. Attached Figure Description
[0020] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 A schematic block diagram illustrating the application environment of the method for obtaining live event latency provided in this application embodiment;
[0022] Figure 2 A flowchart of the method for obtaining live sports broadcast delay provided in the first embodiment of this application;
[0023] Figure 3 This is a schematic block diagram of the event live broadcast delay acquisition device provided in the second embodiment of this application;
[0024] Figure 4 This is a schematic block diagram of the structure of an electronic device provided in the third embodiment of this application. Detailed Implementation
[0025] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.
[0026] It should be understood that the described embodiments are merely some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without creative effort are within the scope of protection of the embodiments of this application.
[0027] In the following description, when referring to the accompanying drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. In the description of this application, it should be understood that the terms "first," "second," "third," etc., are used only to distinguish similar objects and are not necessarily used to describe a specific order or sequence, nor should they be construed as indicating or implying relative importance. Those skilled in the art can understand the specific meaning of the above terms in this application according to the specific circumstances. The singular forms "a," "the," and "the" used in this application and the appended claims are also intended to include the plural forms, unless the context clearly indicates otherwise. The word "if" as used herein can be interpreted as "when," "when," or "in response to determination."
[0028] Furthermore, in the description of this application, unless otherwise stated, "multiple" means two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, or B alone. The character " / " generally indicates that the preceding and following related objects have an "or" relationship.
[0029] Those skilled in the art will understand that the terms "client," "terminal," and "terminal device" as used in this application include not only devices that are wireless signal transmitters, devices that are wireless signal transmitters with only transmitting capabilities, and devices that are wireless signal receivers, devices that are wireless signal receivers with only receiving capabilities, but also devices with receiving and transmitting hardware, and devices with receiving and transmitting hardware capable of bidirectional communication on a bidirectional communication link. Such devices may include: cellular or other communication devices such as personal computers or tablets, having a single-line display, a multi-line display, or no multi-line display; PCS (Personal Communications Service), which may combine voice, data processing, fax, and / or data communication capabilities; PDA (Personal Digital Assistant), which may include a radio frequency receiver, pager, Internet / intranet access, web browser, notepad, calendar, and / or GPS (Global Positioning System) receiver; and conventional laptop and / or handheld computers or other devices, having and / or including a radio frequency receiver. As used herein, "client," "terminal," and "terminal device" can be portable, transportable, installed in a means of transportation (air, sea, and / or land), or suitable and / or configured to operate locally and / or in a distributed manner, operating in any other location on Earth and / or in space. "Client," "terminal," and "terminal device" as used herein can also be a communication terminal, an internet access terminal, or a music / video playback terminal, such as a PDA, a MID (Mobile Internet Device), and / or a mobile phone with music / video playback capabilities, or a smart TV, set-top box, etc.
[0030] The hardware referred to by the names "server," "client," and "service node" in this application is essentially a computer device with the equivalent capabilities of a personal computer. It is a hardware device with the necessary components revealed by the von Neumann architecture, such as a central processing unit (including an arithmetic logic unit and a control unit), memory, input devices, and output devices. The computer program is stored in its memory, and the central processing unit loads the program stored in secondary storage into memory to run, execute the instructions in the program, and interact with the input and output devices to complete specific functions.
[0031] It should be noted that the concept of "server" used in this application can also be extended to the case of server clusters. Based on the network deployment principles understood by those skilled in the art, the servers should be logically divided. Physically, these servers can be independent of each other but accessible through interfaces, or they can be integrated into a single physical computer or a computer cluster. Those skilled in the art should understand this flexibility and should not use it to constrain the implementation of the network deployment method in this application.
[0032] Please see Figure 1 , Figure 1 This is a schematic diagram of an application scenario for the method for obtaining the delay of live sports broadcasts provided in this application embodiment. The application scenario includes a broadcaster client 110, a viewer client 120, and a server 130.
[0033] The broadcaster client 110 and the viewer client 120 interact through the server 130. Specifically, both the broadcaster client 110 and the viewer client 120 can access the Internet via a network access method to establish a data communication link with the server 130. The network can be any type of communication medium capable of enabling communication between the broadcaster client 110 and the server 130, and between the viewer client 120 and the server 130, such as a wired communication link, a wireless communication link, or a fiber optic cable, etc., and this application does not impose any limitations on this.
[0034] It should be noted that the client proposed in this application embodiment includes a broadcaster client 110 and a viewer client 120.
[0035] It should be noted that there are multiple interpretations of the concept of "client" in the existing technology. For example, it can be understood as an application installed on a computer device, or it can be understood as a hardware device corresponding to a server.
[0036] In the embodiments of this application, the term "client" refers to a hardware device corresponding to a server, and more specifically, to a computer device, such as a smartphone, a smart interactive whiteboard, and a personal computer.
[0037] When the client is a mobile device such as a smartphone or smart interactive whiteboard, users can install a matching mobile application on the client or access a web application on the client.
[0038] When the client is a non-mobile device such as a personal computer (PC), the user can install the matching PC application on the client, and can also access the web application on the client.
[0039] Among them, mobile applications refer to applications that can be installed on mobile devices, PC applications refer to applications that can be installed on non-mobile devices, and web applications refer to applications that need to be accessed through a browser.
[0040] Specifically, web applications can be divided into mobile and PC versions depending on the client type, and the page layout and server support provided may differ between the two.
[0041] In this embodiment, the live streaming applications provided to users are categorized into mobile live streaming applications, PC live streaming applications, and web live streaming applications. Users can choose their preferred method of participating in live streaming based on the type of client they use.
[0042] This application categorizes clients into broadcast client 110 and viewer client 130 based on the user's identity when entering the live streaming room. It should be noted that in practical applications, the same client can execute the functions of both viewer client 120 and broadcast client 110 at different times. Therefore, the same client can act as viewer client 120 when watching a live stream and as broadcast client 110 when publishing a live video.
[0043] The broadcaster client 110 refers to the end that sends live video feeds online, typically the client used by the broadcaster in a live stream. The hardware referred to by the broadcaster client 110 essentially refers to computer equipment, specifically, such as... Figure 1 As shown, it can be a computer device such as a smartphone, smart interactive whiteboard, or personal computer.
[0044] The viewer client 120 refers to the end that receives and watches live online video, typically the client used by viewers during a live stream. The hardware referred to by the viewer client 120 essentially refers to computer equipment, specifically, such as... Figure 1 As shown, it can be a computer device such as a smartphone, smart interactive whiteboard, or personal computer.
[0045] The server 130 can function as a service server, responsible for further connecting to related audio data servers, video streaming servers, and other servers providing related support, thereby forming a logically interconnected service cluster to serve related terminal devices, such as… Figure 1 The broadcaster client 110 and the viewer client 120 shown provide services.
[0046] In this embodiment, the broadcaster client 110 and the viewer client 120 can join the same live room (i.e., live channel). The aforementioned live room refers to a chat room implemented using Internet technology and the server 130, which typically has audio and video playback control functions. The broadcaster user conducts live broadcasts in the live room through the broadcaster client 110, and the viewer user of the viewer client 120 can log in to the server 130 to enter the live room to watch the live broadcast.
[0047] Within the live streaming room, the host and viewers can interact through well-known online interaction methods such as voice, video, and text. Generally, the host performs programs for the viewers in the form of audio and video streams, while the viewers can interact with the host by text or by sending virtual gifts. Economic transactions can also occur during the interaction. Of course, the application of live streaming rooms is not limited to online entertainment and can be extended to other related scenarios.
[0048] Specifically, the process of a viewer watching a live stream is as follows: A viewer can click to access the live streaming application installed on the viewer client 120 and select to enter any live stream room. This triggers the viewer client 120 to load the live stream room interface for the viewer. The live stream room interface includes several interactive components, such as video components, virtual gift bar components, and public screen components. By loading these interactive components, viewers can watch the live stream in the live stream room and engage in various online interactions. The online interaction methods include, but are not limited to, sending virtual gifts, participating in live stream activities, and chatting in the public screen.
[0049] It is worth mentioning that, Figure 1 The application scenario described above is merely an exemplary scenario and is not intended to limit the solution of this invention. The solution of this invention can also be applied to other forms of online live streaming application scenarios, which will not be described in detail here.
[0050] With increasing public attention to various sporting events such as football and esports, live streaming of these events has become increasingly popular. Taking game esports as an example, the organizers typically collect the game event live stream data. Various live streaming platforms then access this data stream through their control panels and broadcast the corresponding game footage on their respective platforms. This allows viewers to watch the game on their own clients and share and discuss their viewing experiences, thereby increasing viewer retention on the live streaming platforms.
[0051] In live gaming tournament broadcasts, real-time performance is paramount, as high latency reduces viewer retention on the streaming platform. Therefore, monitoring and testing latency is essential. However, since each streaming platform obtains its game tournament live stream data directly from the organizers, the source of the live stream cannot be determined. This prevents effective latency testing and further reduces viewer retention.
[0052] To address the aforementioned issues, this application provides a method for obtaining live sports event latency. Please refer to... Figure 2 , Figure 2 This is a flowchart illustrating the method for obtaining live sports broadcast latency provided in the first embodiment of this application. The method for obtaining live sports broadcast latency in this embodiment includes the following steps:
[0053] Step S101: When the time for the client to play the live event data stream exceeds the preset time, obtain the first live event screen currently being played by the client and the first live event data stream that has already been retrieved.
[0054] The application scenario of the event live broadcast latency acquisition method in this application embodiment may also include an event live broadcast latency acquisition device; the event live broadcast latency acquisition device is used to acquire and save the first event live broadcast data stream from the organizer accessed by the broadcast control station. The event live broadcast latency acquisition device can also be connected to a client to acquire the first event live broadcast screen played by the client.
[0055] In this application, the method for obtaining live event latency is executed by a live event latency acquisition device. The hardware referred to as the live event latency acquisition device essentially refers to computer equipment, specifically, it can be a type of computer equipment such as a smartphone, smart interactive whiteboard, or personal computer.
[0056] It is understood that the method for obtaining the delay of live event broadcasts in this application can also be executed by other entities, such as servers, and this application does not impose any restrictions on it.
[0057] In the process of realizing this invention, the inventors discovered that although the source of the live broadcast cannot be seen during the live broadcast of the event, the live broadcast data stream accessed by the broadcast control station can be used as the broadcaster's data stream, and the live broadcast screen viewed by the client can be used as the viewer's client data stream. In this way, the live broadcast latency of the broadcaster and the viewer can be obtained. That is, the time delay between the time when the broadcast control station of the live broadcast platform accesses the live broadcast data stream and the time when the client of the live broadcast platform views the corresponding live broadcast screen is obtained. In other words, the live broadcast latency of the live broadcast platform.
[0058] The preset time can be set according to actual needs, and this application does not impose any restrictions on it.
[0059] In an optional embodiment, when the time for playing the live event data stream exceeds a preset time, the client can directly capture the currently playing live event frame to obtain the first live event frame, and the live event delay acquisition device can then directly obtain the first live event frame from the client.
[0060] In another optional embodiment, when the time for playing the live event data stream exceeds a preset time, the live event delay acquisition device can directly capture the live event currently being played by the client to obtain the first live event image.
[0061] In an optional embodiment, the event live broadcast latency acquisition device can save the event live broadcast data stream accessed by the broadcast control station to its local machine in real time. Specifically, this can be achieved using FFmpeg (Fast Forward MPEG). When the duration of playing the event live broadcast data stream exceeds a preset time, the event live broadcast latency acquisition device stops fetching and saving the event live broadcast data stream accessed by the broadcast control station, thereby obtaining the saved event live broadcast data stream locally as the first event live broadcast data stream.
[0062] Step S102: Deframe the first event live data stream according to the preset frame rate to obtain several frames of the second event live screen.
[0063] Understandably, the preset frame rate is greater than or equal to the encoding frame rate of the first live event data stream in order to improve the accuracy of the live event latency.
[0064] Step S103: Compare the first event live stream frame with each frame of the second event live stream frame in the first event live stream data stream, and obtain the second event live stream frame that best matches the first event live stream frame, which will be used as the third event live stream frame.
[0065] In an optional embodiment, the first live broadcast frame can be compared with each frame of the second live broadcast frame in the first live broadcast data stream to obtain the second live broadcast frame that best matches the first live broadcast frame, which is then used as the third live broadcast frame.
[0066] In another optional embodiment, the second live broadcast frame in the first live broadcast data stream can be compared with the first live broadcast frame in chronological order from back to front. If there is a second live broadcast frame that exceeds a preset threshold, the comparison is stopped, and the second live broadcast frame that exceeds the preset threshold is used as the third live broadcast frame.
[0067] In the process of comparing the first live broadcast frame with each frame of the second live broadcast frame in the first live broadcast data stream to obtain the second live broadcast frame that best matches the first live broadcast frame, relevant image matching methods can be used, such as feature matching methods, deep learning matching methods, SSIM (Structural Similarity) methods, etc., to determine the best matching second live broadcast frame.
[0068] Step S104: Obtain the frame difference between the third event live stream and the last frame of the second event live stream in the first event live stream data stream. Based on the frame difference and the preset frame rate, obtain the event live stream delay.
[0069] In an optional embodiment, the frames of the second event live broadcast in the first event live broadcast data stream are arranged in chronological order, and then the number of frames between the frame containing the third event live broadcast and the last frame of the second event live broadcast in the first event live broadcast data stream can be directly calculated to obtain the frame difference.
[0070] In another optional embodiment, each frame of the second event live broadcast in the first event live broadcast data stream is arranged in chronological order and labeled with numbers 1, 2, 3...n. Then, the frame number of the last frame of the second event live broadcast in the first event live broadcast data stream is subtracted from the frame number of the third event live broadcast to obtain the frame difference.
[0071] In this embodiment, when the time for fetching and playing the live event data stream exceeds a preset time, the following steps are taken: First, the currently captured and played first live event frame and the currently fetched first live event data stream are obtained. The first live event data stream is then deframed according to a preset frame rate to obtain several frames of second live event frames. The first live event frames are compared with each frame of the second live event frames in the first live event data stream to obtain the second live event frame that best matches the first live event frame, which is then used as the third live event frame. The frame difference between the third live event frame and the last frame of the second live event frame in the first live event data stream is obtained. Based on the frame difference and the preset frame rate, the live event latency is determined, thus achieving effective testing of the live event latency. This method requires no manual intervention, saving manpower and improving viewer retention on the live streaming platform. It also eliminates the need for additional development for the broadcaster and viewer ends, making it applicable to various live streaming products.
[0072] In an optional embodiment, step S101, when the client plays the live event footage of the live event data stream for a period longer than a preset time, involves obtaining the first live event footage currently being played by the client and the first live event data stream already retrieved. This includes: when the client plays the live event footage of the live event data stream for a period longer than the preset time, capturing the currently playing live event footage as the first live event footage, stopping the retrieval of the broadcast console's access stream, and obtaining the currently retrieved live event data stream as the first live event data stream. This embodiment of the application, by capturing the currently playing first live event footage and obtaining the currently retrieved first live event data stream, ensures that delay-related data is obtained simultaneously, thereby improving the accuracy of delay calculation.
[0073] In an optional embodiment, step S103, which compares the first live broadcast frame with each frame of the second live broadcast frame in the first live broadcast data stream to obtain the second live broadcast frame that best matches the first live broadcast frame, and uses it as the third live broadcast frame, includes: calculating the structural similarity between the first live broadcast frame and each frame of the second live broadcast frame in the first live broadcast data stream; and using the second live broadcast frame with the greatest structural similarity as the third live broadcast frame.
[0074] Structural similarity (SSIM) is a metric that measures the similarity between two images. The SSIM ranges from -1 to 1. The higher the SSIM, the more similar the two images are. When two images are exactly the same, the SSIM value is equal to 1.
[0075] This application embodiment uses the second live broadcast frame with the greatest similarity as the third live broadcast frame, which can quickly and accurately obtain the frame in the first live broadcast data stream that is consistent with the first live broadcast frame, thereby obtaining the live broadcast delay.
[0076] In an optional embodiment, step S102, which involves deframing the first live event data stream at a preset frame rate to obtain several frames of the second live event footage, further includes: obtaining the total number of frames of the second live event footage in the first live event data stream; and step S104, which involves obtaining the frame difference between the third live event footage and the last frame of the live event footage in the first live event data stream, includes: using the difference between the total number of frames and the number of frames in which the third live event footage is located as the frame difference.
[0077] In this context, each frame of the second event live broadcast obtained from the frame decoding can be understood as a frame image with a frame number arranged in chronological order. For example, if each frame of the second event live broadcast is arranged in chronological order and labeled with the numbers 1, 2, 3...n, the frame number of the last frame is the total number of frames. Subtracting the frame number of the third event live broadcast from the total number of frames yields the frame difference. For example, if the frame number of the third event live broadcast is 100 and the frame number of the last frame is 120, then the frame difference is 120 - 100 = 20 frames.
[0078] In this embodiment of the application, by obtaining the total number of frames in the first event live stream, the frame difference can be obtained quickly and conveniently based on the difference between the total number of frames and the frame number of the third event live stream.
[0079] In an optional embodiment, step S105, which involves obtaining the live broadcast delay based on the frame difference and the preset frame rate, includes: dividing the frame difference by the preset frame rate to obtain the live broadcast delay.
[0080] When the frame rate is 60, the method for calculating the live broadcast latency is: Latency = (total-n)*1000 / 60; where total is the total number of frames, n is the frame number of the third live broadcast screen, (total-n) is the frame difference; 60 is the frame rate, indicating that 60 frames are transmitted per second; 1000 is the time unit conversion, used to indicate that the calculated live broadcast latency is converted to frames per millisecond as the unit.
[0081] The embodiments of this application can quickly obtain the latency of live event broadcasts by using frame difference and preset frame rate, thereby reducing the amount of computation.
[0082] Please see Figure 3 This is a schematic diagram of the structure of the event live broadcast delay acquisition device provided in the second embodiment of this application. The device 200 includes:
[0083] The live data acquisition module 201 is used to acquire the first live event frame currently being played by the client and the first live event data stream already retrieved when the time for the client to play the live event frame of the live event data stream exceeds a preset time.
[0084] The data stream deframe module 202 is used to deframe the first event live data stream according to a preset frame rate to obtain several frames of the second event live screen.
[0085] The image matching module 203 is used to compare the first live broadcast image with each frame of the second live broadcast image in the first live broadcast data stream, and obtain the second live broadcast image that best matches the first live broadcast image, which is then used as the third live broadcast image.
[0086] The live broadcast latency acquisition module 204 is used to acquire the frame difference between the third event live broadcast and the last frame of the second event live broadcast in the first event live broadcast data stream, and to obtain the event live broadcast latency based on the frame difference and the preset frame rate.
[0087] It should be noted that the sports live broadcast latency acquisition device provided in the second embodiment of this application is only illustrated by the above-described division of functional modules when executing the sports live broadcast latency acquisition method. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the sports live broadcast latency acquisition device provided in the second embodiment of this application and the sports live broadcast latency acquisition method in the first embodiment of this application belong to the same concept, and its implementation process is detailed in the method embodiment, which will not be repeated here.
[0088] The embodiment of the event live broadcast delay acquisition device of the second embodiment of this application can be applied to electronic devices, such as client devices. This device embodiment can be implemented by software, hardware, or a combination of software and hardware. Taking software implementation as an example, as a logical device, it is formed by a processor that processes files to read the corresponding computer program instructions from non-volatile memory into memory for execution. From a hardware perspective, the electronic device may include a processor, network interface, memory, and non-volatile memory, interconnected through a data bus or other known means.
[0089] Please see Figure 4 This is a schematic diagram of the structure of the electronic device provided in the fourth embodiment of this application. Figure 4 As shown, the electronic device 16 may include: a processor 160, a memory 161, and a computer program 162 stored in the memory 161 and capable of running on the processor 160, such as an application for a method of obtaining delays in live sports broadcasts; when the processor 160 executes the computer program 162, it implements the steps in the first embodiment described above.
[0090] The processor 160 may include one or more processing cores. The processor 160 connects to various parts within the electronic device 16 using various interfaces and lines. It executes various functions and processes data by running or executing instructions, programs, code sets, or instruction sets stored in the memory 161, and by calling data from the memory 161. Optionally, the processor 160 may be implemented using at least one hardware form of Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), or Programmable Logic Array (PLA). The processor 160 may integrate one or a combination of several of the following: Central Processing Unit (CPU), Graphics Processing Unit (GPU), and modem. The CPU primarily handles the operating system, user interface, and applications; the GPU is responsible for rendering and drawing the content required for the touch screen; and the modem handles wireless communication. It is understood that the modem may also be implemented as a separate chip without being integrated into the processor 160.
[0091] The memory 161 may include random access memory (RAM) or read-only memory. Optionally, the memory 161 may include a non-transitory computer-readable storage medium. The memory 161 may be used to store instructions, programs, code, code sets, or instruction sets. The memory 161 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as touch instructions), instructions for implementing the various method embodiments described above, etc.; the data storage area may store data involved in the various method embodiments described above, etc. Optionally, the memory 161 may also be at least one storage device located remotely from the aforementioned processor 160.
[0092] This application also provides a computer storage medium that can store multiple instructions. These instructions are applicable to being loaded by a processor and executed by the method steps of the above embodiments. For details of the execution process, please refer to the specific description of the above embodiments, which will not be repeated here.
[0093] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. In the embodiments, each functional unit and module can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. In addition, the specific names of each functional unit and module are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0094] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0095] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0096] In the embodiments provided by this invention, it should be understood that the disclosed apparatus / terminal devices and methods can be implemented in other ways. For example, the apparatus / terminal device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0097] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0098] Furthermore, in the various embodiments of the present invention, the functional units can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0099] If integrated modules / units are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms.
[0100] This invention is not limited to the above-described embodiments. If any modifications or variations to this invention do not depart from the spirit and scope of this invention, and if such modifications and variations fall within the scope of the claims and equivalent technologies of this invention, then this invention also intends to include such modifications and variations.
Claims
1. A method for obtaining the latency of a live sports event, characterized in that, The method is applied to a device for acquiring the latency of live sports broadcasts; the device is connected to a viewer client and a broadcast control console; the method includes the following steps: When the time for the audience client to play the live event data stream exceeds a preset time, the first live event image currently being played by the audience client and the first live event data stream currently being pulled from the broadcast control station are obtained. The first event live stream data stream is deframed according to a preset frame rate to obtain several frames of the second event live stream. Calculate the structural similarity between the first live event frame and each frame of the second live event frame in the first live event data stream; The second event live stream image with the greatest structural similarity will be used as the third event live stream image. The frame difference between the third live event frame and the last frame of the second live event frame in the first live event data stream is obtained, and the live event delay is obtained based on the frame difference and the preset frame rate.
2. The method for obtaining live event delay according to claim 1, characterized in that: The step of deframing the first event live data stream according to a preset frame rate to obtain several frames of the second event live screen further includes: obtaining the total number of frames of the second event live screen in the first event live data stream. The step of obtaining the frame difference between the third event live stream and the last frame of the second event live stream in the first event live stream data stream includes: taking the difference between the total number of frames and the number of frames in which the third event live stream is located as the frame difference.
3. The method for obtaining live event delay according to claim 1, characterized in that: The step of obtaining the live broadcast delay based on the frame difference and the preset frame rate includes: Divide the frame difference by the preset frame rate to obtain the event live broadcast delay.
4. The method for obtaining live event delay according to any one of claims 1 to 3, characterized in that: The preset frame rate is greater than or equal to the encoding frame rate of the first live event data stream.
5. The method for obtaining live event delay according to any one of claims 1 to 3, characterized in that: The step of obtaining the first live event footage currently being played by the viewer's client and the first live event data stream already retrieved when the time for the viewer's client to play the live event footage exceeds a preset time includes: When the time for which the viewer's client plays the live event data stream exceeds a preset time, the live event screen currently being played by the viewer's client is captured as the first live event screen, the access stream from the broadcast control room is stopped, and the currently retrieved live event data stream is obtained as the first live event data stream.
6. A device for acquiring the delay of live sports broadcasts, characterized in that, The event live broadcast latency acquisition device is connected to a viewer client and a broadcast control console; the device includes: The live data acquisition module is used to acquire the first live event screen currently being played by the viewer client and the first live event data stream currently being pulled from the control room when the time for the viewer client to play the live event screen of the live event data stream exceeds a preset time. The data stream deframe module is used to deframe the first event live data stream according to a preset frame rate to obtain several frames of the second event live screen. The image matching module is used to calculate the structural similarity between the first live event image and each frame of the second live event image in the first live event data stream; and to select the second live event image with the greatest structural similarity as the third live event image. The live broadcast latency acquisition module is used to acquire the frame difference between the third live broadcast frame and the last frame of the second live broadcast frame in the first live broadcast data stream, and to obtain the live broadcast latency based on the frame difference and the preset frame rate.
7. The live broadcast latency acquisition device according to claim 6, characterized in that: The data stream deframe module is also used to obtain the total number of frames of the second event live broadcast in the first event live broadcast data stream; The live broadcast latency acquisition module is also used to take the difference between the total number of frames and the number of frames in which the third event live broadcast is located as the frame difference.
8. An electronic device comprising a processor and a memory; characterized in that, The memory stores a computer program adapted to be loaded by the processor and executed as described in any one of claims 1 to 5 for obtaining the live event delay.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the method for obtaining the delay of live event broadcast as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Method and device for determining delay time of live video and electronic equipment
CN111654690A
Video playing control method and system
CN112752109A