Video code flow exception monitoring method, device and equipment and storage medium
By monitoring the video stream at a preset sampling frequency and creating diagnostic frames in the terminal or server, the problem of rapid processing of abnormal video bitstreams is solved, the efficiency of video information recovery is improved, and the server load is reduced.
Patent Information
- Application Number
- CN202210275675.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-21
- Publication Date
- 2026-03-03
- Estimated Expiration
- 2042-03-21
AI Technical Summary
Existing technologies are unable to quickly identify and process video stream anomalies, leading to video information loss and the inability to recover it in a timely manner.
By acquiring video streams at a preset sampling frequency in the terminal or server, monitoring the sampling results, and creating diagnostic frames based on preset abnormal conditions, the system can promptly transmit these frames to the client to assist in handling video stream anomalies.
It enables rapid identification and handling of video stream anomalies, reduces server load, and improves video information recovery efficiency.
Smart Images

Figure CN114885150B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of surveillance technology, and in particular to a method, apparatus, device, and storage medium for monitoring abnormal video stream loss. Background Technology
[0002] Currently, bitrate is a crucial factor in the field of streaming media monitoring, specifically including video bitrate, audio bitrate, and alarm frames. Among these, video bitrate is the most important information in monitoring. When video bitrate malfunctions, the monitoring system cannot process video data, leading to the loss of critical video information for users. Therefore, it is necessary to be able to provide real-time alarm notifications to maintenance personnel and quickly diagnose video encoding anomalies to restore video capture and encoding as soon as possible, thereby minimizing video loss.
[0003] Existing technologies can only issue simple alarms when a video stream has no bitstream, or have regional technical support personnel collect screenshots of the problem and provide them to R&D personnel for analysis. However, neither of these technologies can quickly respond to the anomaly, and the information provided is not real-time or complete enough, thus making it impossible to quickly understand and handle video stream anomalies.
[0004] There is currently no effective solution to the problem of being unable to quickly understand and process video stream anomalies in related technologies. Summary of the Invention
[0005] This embodiment provides a method, apparatus, device, and storage medium for monitoring video stream anomalies, in order to solve the problem in related technologies that cannot quickly understand and process video stream anomalies.
[0006] Firstly, this embodiment provides a method for detecting video stream loss anomalies, including:
[0007] Obtain the corresponding video streams for each monitored area;
[0008] The video stream is sampled based on a preset sampling frequency, and the sampling results are monitored.
[0009] In response to the monitoring results, a corresponding diagnostic frame is created based on preset abnormal conditions; and the diagnostic frame is transmitted to the client through the server.
[0010] In some embodiments, prior to sampling the video stream based on a preset sampling frequency, the method further includes:
[0011] The preset sampling frequency is dynamically adjusted based on CPU load conditions;
[0012] The CPU utilization rate is statistically analyzed based on the preset utilization rate threshold and the preset number of times.
[0013] If the number of times the CPU utilization rate is lower than the utilization rate threshold reaches the preset number, then the preset sampling frequency is increased, and the preset sampling frequency is kept below the frame rate of the video stream.
[0014] If the number of times the CPU occupancy rate exceeds the occupancy rate threshold reaches the preset number, then the preset sampling frequency is reduced.
[0015] In some embodiments, sampling the video stream based on a preset sampling frequency and monitoring the sampling results includes:
[0016] The video stream is sampled at the preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp;
[0017] The monitoring results are obtained by monitoring the bitstream values.
[0018] In some embodiments, the step of creating a corresponding diagnostic frame based on preset anomaly conditions in response to monitoring results includes:
[0019] If the number of zero-bitstream occurrences in the monitoring results meets the abnormal condition, it is determined to be an anomaly with no bitstream; the abnormal condition is that the number of consecutive occurrences of zero bitstream reaches a preset abnormal threshold.
[0020] The auxiliary information is used to create a corresponding diagnostic frame with the timestamp.
[0021] In some embodiments, the step of creating a corresponding diagnostic frame based on preset anomaly conditions in response to monitoring results further includes:
[0022] If the number of zero-bitstream occurrences in the monitoring results does not meet the abnormal condition, the sampling results are discarded, and the video stream is sampled again.
[0023] In some embodiments, prior to acquiring the corresponding video streams for each monitored area, the method further includes:
[0024] The corresponding video data is collected by sensors in the monitored area;
[0025] The video data is compressed and encoded to obtain the video stream.
[0026] Secondly, this embodiment provides a method for detecting video stream loss anomalies, including:
[0027] Acquire video streams for the corresponding monitoring areas of each terminal device;
[0028] The video stream is sampled based on a preset sampling frequency, and the sampling results are monitored.
[0029] In response to the monitoring results, a corresponding diagnostic frame is created based on preset abnormal conditions; and the diagnostic frame is transmitted to the client.
[0030] Thirdly, this embodiment provides a video no-stream anomaly monitoring device, characterized in that it includes: a first acquisition module, a first sampling module, and a first diagnostic module;
[0031] The first acquisition module is used to acquire the corresponding video streams of each monitoring area;
[0032] The first sampling module is used to sample the video stream based on a preset sampling frequency and monitor the sampling results;
[0033] The first diagnostic module is used to create a corresponding diagnostic frame based on preset abnormal conditions in response to the monitoring results; and to transmit the diagnostic frame to the client through the server.
[0034] Fourthly, this embodiment provides a video no-bitstream anomaly monitoring device, including: a second acquisition module, a second sampling module, and a second diagnostic module;
[0035] The acquisition module acquires video streams of the corresponding monitoring areas of each terminal device;
[0036] The sampling module is used to sample the video stream based on a preset sampling frequency and monitor the sampling results;
[0037] The diagnostic module is used to respond to monitoring results, create corresponding diagnostic frames based on preset abnormal conditions, and transmit the diagnostic frames to the client via the server.
[0038] Fifthly, this embodiment provides a computer device including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the video no-bitstream anomaly monitoring method described in the first or second aspect above.
[0039] In a sixth aspect, this embodiment provides a storage medium storing a computer program that, when executed by a processor, implements the video no-stream anomaly monitoring method described in the first or second aspect above.
[0040] Compared with related technologies, the video stream no-bitrate anomaly monitoring method, apparatus, system, device, and storage medium provided in this embodiment acquire the corresponding video streams of each monitoring area; sample the video streams based on a preset sampling frequency and monitor the sampling results; in response to the monitoring results, create corresponding diagnostic frames based on preset anomaly conditions; and transmit the diagnostic frames to the client through a server. This solves the problem of not being able to quickly understand and process video stream anomalies, and achieves the effect of quickly understanding and processing video stream anomalies based on the diagnostic frame information corresponding to the no-bitrate anomaly.
[0041] Details of one or more embodiments of this application are set forth in the following drawings and description to make other features, objects and advantages of this application more readily apparent. Attached Figure Description
[0042] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0043] Figure 1 This is a hardware structure block diagram of a video no-bitstream anomaly detection method in one embodiment;
[0044] Figure 2 This is a flowchart of a video no-bitstream anomaly detection method in one embodiment;
[0045] Figure 3 This is a schematic diagram illustrating the process of dynamically adjusting a preset sampling frequency in one embodiment;
[0046] Figure 4 This is a flowchart of a video no-stream anomaly detection method in another embodiment;
[0047] Figure 5 Here is a flowchart of a preferred embodiment of a video stream no-bit anomaly detection method;
[0048] Figure 6 This is a structural block diagram of a video no-bitstream anomaly monitoring device in one embodiment;
[0049] Figure 7 This is a structural block diagram of a video no-stream anomaly monitoring device in another embodiment;
[0050] Figure 8 This is a block diagram of a video no-bitstream anomaly monitoring system in one embodiment;
[0051] Figure 9 This is a schematic diagram illustrating the process of a client receiving and processing video frames and diagnostic frames in one embodiment.
[0052] In the diagram: 610, First acquisition module; 620, First sampling module; 630, First diagnostic module; 710, Second acquisition module; 720, Second sampling module; 730, Second diagnostic module; 800, Video no-stream anomaly monitoring system; 810, Client; 820, Server; 830, Terminal device. Detailed Implementation
[0053] To better understand the purpose, technical solution, and advantages of this application, the application is described and illustrated below in conjunction with the accompanying drawings and embodiments.
[0054] Unless otherwise defined, the technical or scientific terms used in this application shall have the general meaning as understood by one of ordinary skill in the art to which this application pertains. Words such as “a,” “an,” “an,” “the,” “the,” and “these,” used in this application, do not indicate quantitative limitation and may be singular or plural. The terms “comprising,” “including,” “having,” and any variations thereof used in this application are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or device that comprises a series of steps or modules (units) is not limited to the listed steps or modules (units) but may include steps or modules (units) not listed, or may include other steps or modules (units) inherent to such processes, methods, products, or devices. The terms “connected,” “linked,” and “coupled,” used in this application, are not limited to physical or mechanical connections but may include electrical connections, whether direct or indirect. The term “multiple” used in this application refers to two or more. The "and / or" operator describes the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: A alone, A and B simultaneously, and B alone. Typically, the character " / " indicates that the objects before and after it are in an "or" relationship. The terms "first," "second," and "third," etc., used in this application are merely for distinguishing similar objects and do not represent a specific ordering of the objects.
[0055] The method embodiments provided in this example can be executed on a terminal, computer, or similar computing device. For example, it can run on a terminal. Figure 1 This is a hardware structure block diagram of the terminal for the video no-stream anomaly detection method in this embodiment. (See diagram for example.) Figure 1 As shown, a terminal may include one or more ( Figure 1 Only one is shown in the diagram. A processor 102 and a memory 104 for storing data are also included. The processor 102 may be, but is not limited to, a microprocessor (MCU) or a programmable logic device (FPGA). The terminal may also include a transmission device 106 for communication functions and an input / output device 108. Those skilled in the art will understand that… Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the terminal described above. For example, the terminal may also include components that are larger than... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown are illustrated.
[0056] The memory 104 can be used to store computer programs, such as application software programs and modules, like the computer program corresponding to the video no-bitstream anomaly monitoring method in this embodiment. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, thereby implementing the above-described method. The memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the terminal via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0057] The transmission device 106 is used to receive or send data via a network. This network includes a wireless network provided by the terminal's communication provider. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 106 can be a Radio Frequency (RF) module used for wireless communication with the Internet.
[0058] This embodiment provides a method for detecting video stream loss anomalies. Figure 2 The corresponding flowchart, such as Figure 2 As shown, the method includes the following steps:
[0059] Step S210: Obtain the corresponding video stream for each monitored area.
[0060] Specifically, the corresponding video streams are acquired from the corresponding terminals in each monitoring area. These terminals can be embedded front-end monitoring devices or other terminal devices with monitoring functions, such as network cameras or camera pan-tilt units. After processing the acquired video data in the terminals, the corresponding video streams for each terminal's monitoring area are generated.
[0061] Step S220: Sample the video stream based on a preset sampling frequency and monitor the sampling results.
[0062] Specifically, the acquired video stream is sampled in the terminal at a preset sampling frequency, and the sampling results are also in units of sampling frequency. The sampling results may include data information such as the bit rate of the video stream. The sampling results are further monitored to detect abnormalities in the video bit rate.
[0063] Step S230: In response to the monitoring results, a corresponding diagnostic frame is created based on preset abnormal conditions; and the diagnostic frame is transmitted to the client through the server.
[0064] Specifically, based on preset abnormal conditions, the system responds to the no-stream anomaly in the monitoring results and creates a diagnostic frame for the corresponding anomaly according to the data information in the sampling results. The diagnostic frame includes detailed diagnostic auxiliary information for the no-stream anomaly. Each terminal then transmits the created diagnostic frame to the client through the server. The client parses the received diagnostic frame to obtain detailed diagnostic auxiliary information for the anomaly.
[0065] In addition, when the monitoring results show an abnormal situation of no bitstream, the terminal can also transmit the abnormal event of no bitstream to the client through the server via alarm information. The alarm information includes preliminary diagnostic information of the abnormal situation, so that maintenance personnel can obtain information about the abnormal situation in real time and perform preliminary location of the abnormal situation.
[0066] Existing anomaly detection methods can only issue simple alarms when a video stream has no bitstream, or have regional technical support personnel collect screenshots of the problem and provide them to R&D personnel for analysis. However, neither method can quickly respond to anomalies, and the information provided is not real-time or complete enough. This embodiment effectively supplements existing technologies. The above steps sample the video stream at a preset sampling frequency on the terminal, monitor the sampling results, and obtain the anomalies in the video stream from the monitoring results based on preset anomaly conditions. A corresponding diagnostic frame containing detailed diagnostic auxiliary information is then created and sent to the client through the server. This allows the user to quickly understand and handle video stream anomalies based on the information contained in the diagnostic frame, thereby solving the problem of not being able to quickly understand and handle video stream anomalies when they occur.
[0067] Furthermore, by acquiring the video stream and analyzing and diagnosing the absence of bitstream anomalies in each terminal device in this embodiment, the server load can be reduced, avoiding the problem of high server load caused by centralized diagnosis on the server.
[0068] In some embodiments, prior to sampling the video stream based on a preset sampling frequency, the method further includes:
[0069] The preset sampling frequency is dynamically adjusted based on CPU load conditions.
[0070] Specifically, by monitoring CPU load, the preset sampling frequency is dynamically adjusted based on the actual CPU occupancy during operation. Figure 3 This is a schematic diagram illustrating the process of dynamically adjusting a preset sampling frequency, including the following steps:
[0071] The CPU utilization rate is statistically analyzed based on the preset utilization rate threshold and the preset number of times.
[0072] Specifically, the number of times the CPU utilization rate is higher or lower than the utilization rate threshold during CPU operation is counted, and it is determined whether the preset number of times has been reached.
[0073] If the number of times the CPU utilization rate is lower than the utilization rate threshold reaches a preset number, the preset sampling frequency will be increased, and the preset sampling frequency will not exceed the frame rate of the video stream.
[0074] If the number of times the CPU utilization rate exceeds the utilization rate threshold reaches a preset number, the preset sampling frequency will be reduced.
[0075] Preferably, a 40% CPU utilization rate is used as the preset utilization rate threshold, and the frame rate of the video stream is used as the default sampling frequency. If the number of times the CPU utilization rate is higher than 40% reaches a preset number of 50, the preset sampling frequency is reduced by a factor of two. If the number of times the CPU utilization rate is lower than 40% reaches a preset number of 50, the preset sampling frequency is increased by a factor of two, ensuring that the preset sampling frequency does not exceed the frame rate of the video stream. For example, when the CPU utilization rate is higher than 40% for 50 times, the preset sampling frequency is reduced by a factor of two from the default sampling frequency until the CPU utilization rate is not lower than 40%. Then, when the CPU utilization rate is lower than 40% for 50 times, the preset sampling frequency is increased by a factor of two, but the maximum cannot exceed the frame rate of the video stream.
[0076] By dynamically adjusting the preset sampling frequency based on CPU load in this embodiment, sampling efficiency can be improved during the sampling process, and sampling can be performed with higher CPU utilization.
[0077] In some embodiments, the above-described sampling of the video stream based on a preset sampling frequency and monitoring of the sampling results includes the following steps:
[0078] The video stream is sampled at a preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp.
[0079] The monitoring results are obtained by monitoring the bitstream values.
[0080] Specifically, the sampling results of the video stream are obtained by sampling at a preset sampling frequency. The sampling results include bitstream values, auxiliary information, and timestamps of the sampling time. By monitoring the bitstream values, monitoring results including bitstream values at multiple preset sampling frequencies are obtained.
[0081] The auxiliary information refers to the real-time status information of the terminal device, providing detailed diagnostic assistance for diagnosing abnormal situations. Specifically, it includes: SDK information, memory status, bandwidth, sensor information, and CPU utilization. SDK information refers to encoder anomaly information, such as the encoder being in an idle state; memory status refers to the mmz memory log; bandwidth refers to encoding bandwidth fluctuations caused by DSP crashes or application anomalies; sensor information refers to the initialization failure of the VIN module in the sensor that acquires video data; and CPU utilization refers to the CPU usage during operation, such as the occurrence of CPU_busy alarms or soft interrupts.
[0082] In this embodiment, the video stream bitrate value is collected during sampling for monitoring to obtain abnormal states in the video stream. Auxiliary information and corresponding timestamps are also sampled. After detecting an abnormal state, auxiliary information at the time of the abnormality is obtained. The auxiliary information can help technicians analyze and diagnose abnormal states more quickly.
[0083] In some embodiments, the above-mentioned response to monitoring results, creating a corresponding diagnostic frame based on preset anomaly conditions, includes the following steps:
[0084] If the number of zero-bitstream occurrences in the monitoring results meets the abnormal conditions, it is determined to be an abnormality of no bitstream; the abnormal condition is that the number of consecutive occurrences of zero bitstream reaches the preset abnormal threshold; the auxiliary information is used to create a corresponding diagnostic frame with timestamps.
[0085] Specifically, based on preset abnormal conditions, when the sampling frequency of consecutive zero bitstream values in the monitoring results reaches a preset abnormal threshold, it is determined to be a no-bitstream abnormality. Preferably, the abnormal threshold is set to 50 times. Further, the corresponding auxiliary information for the no-bitstream abnormality is used to create a corresponding diagnostic frame using the timestamp of the sampling time. By interpolating frames and combining them, while maintaining the temporal order of the auxiliary information, the diagnostic frame and streaming media data are mixed according to the streaming media protocol. Then, based on the streaming media protocol, the diagnostic frame is sent to the client via the server. This allows for the rapid transmission of the diagnostic frame using the current timestamp of the auxiliary information upon detecting a no-bitstream abnormality, thus enabling timely detection and location of the abnormal state.
[0086] If the number of zero-bitstream occurrences in the monitoring results does not meet the abnormal conditions, the sampling results are discarded, and sampling of the video stream continues.
[0087] Specifically, if the number of consecutive occurrences of no bitstream in the monitoring results does not reach the preset abnormal threshold, or if there is no occurrence of no bitstream with a bitstream value of zero, then the auxiliary information and timestamp sampled within the sampling frequency are discarded, and the video stream continues to be sampled at the sampling frequency.
[0088] By responding to the no-stream anomaly in the monitoring results in this embodiment, a diagnostic frame containing auxiliary information can be sent to the client in a timely manner with the current timestamp when the no-stream anomaly occurs. This allows for immediate analysis and diagnosis of the no-stream anomaly based on the information in the diagnostic frame, thus facilitating the repair of video information.
[0089] In some embodiments, before acquiring the corresponding video streams for each monitored area, the following steps are included:
[0090] The corresponding video data is collected through sensors in the monitored area;
[0091] The video data is compressed and encoded to obtain a video stream.
[0092] Specifically, video data is periodically collected from sensors in the corresponding monitoring area. Depending on the terminal device, the video data has a corresponding data format. In this embodiment, the YUV data is compressed and encoded according to parameters to generate I-frame and P-frame data streams. Furthermore, information such as frame type and timestamp is filled into the video stream to obtain the corresponding video stream.
[0093] By collecting video data from the front-end device and compressing and encoding it to obtain monitoring video streams for different monitoring areas in this embodiment, users can monitor each monitoring area uniformly on the client side in order to obtain abnormal information more quickly.
[0094] This embodiment also provides a method for monitoring video stream loss anomalies. Figure 4 This is a flowchart of another video stream no-bitstream anomaly detection method in this embodiment, such as... Figure 4 As shown, the method includes the following steps:
[0095] Step S410: Obtain the video stream of the corresponding monitoring area of each terminal device.
[0096] Specifically, the server acquires video stream information collected by each terminal device. These terminal devices can be embedded front-end monitoring devices or other network cameras or camera pan-tilt units with monitoring capabilities. After processing the acquired video data on the terminal, corresponding video streams for each terminal's monitoring area are generated.
[0097] Step S420: Sample the video stream based on a preset sampling frequency and monitor the sampling results.
[0098] Specifically, the video stream is sampled on the server, and the sampling results can include data information such as the bitrate value of the video stream. The sampling results are then monitored to detect any abnormalities in the video bitrate.
[0099] Step S430: In response to the monitoring results, a corresponding diagnostic frame is created based on preset abnormal conditions; and the diagnostic frame is transmitted to the client.
[0100] Specifically, based on preset abnormal conditions, the system responds to the absence of bitstream abnormality in the monitoring results, and creates diagnostic frames for the corresponding abnormality based on the data information in the sampling results. The server then transmits the diagnostic frames to the client in a unified manner.
[0101] In addition, when the monitoring results show an abnormal situation of no bitstream, the server can also transmit the no bitstream abnormal event to the client through alarm information. The alarm information includes preliminary diagnostic information of the abnormal situation, so that maintenance personnel can obtain information about the abnormal situation in real time and perform preliminary location of the abnormal situation.
[0102] The above steps involve sampling the video stream at a preset sampling frequency on the server, monitoring the sampling results, obtaining abnormal situations in the video stream from the monitoring results based on preset abnormal conditions, and creating corresponding diagnostic frames containing detailed diagnostic auxiliary information to send to the client. This allows users on the client to quickly understand and handle video stream abnormalities based on the information contained in the diagnostic frames, thereby solving the problem of not being able to quickly understand and handle video stream abnormalities when they occur.
[0103] The present embodiment will now be described and illustrated through preferred embodiments.
[0104] Figure 5 This is a flowchart of the video no-bitstream anomaly detection method in this preferred embodiment, as follows: Figure 5 As shown, the method includes the following steps:
[0105] Step S510: Collect relevant video data through sensors in the monitored area; compress and encode the video data to obtain a video stream.
[0106] Step S520: Obtain the corresponding video streams for each monitored area in the terminal device.
[0107] Step S530: Determine whether the CPU utilization rate has been above or below 40% for 50 consecutive times. If the CPU utilization rate has been below 40% for 50 consecutive times, proceed to step S531; if the CPU utilization rate has been above 40% for 50 consecutive times, proceed to step S532.
[0108] Step S531: Increase the preset sampling frequency by a factor of two, and ensure that the preset sampling frequency does not exceed the frame rate of the video stream.
[0109] Step S532: Reduce the preset sampling frequency by a factor of two.
[0110] Step S540: Sample the video stream at a preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp; obtain the monitoring result by monitoring the bitstream value.
[0111] Step S550: Determine whether there is a no-stream anomaly based on the monitoring results. If the number of zero-stream occurrences reaches 50 consecutive times, it is determined to be a no-stream anomaly, and step S551 is executed; if the number of zero-stream occurrences does not reach 50 consecutive times or no zero-stream occurrence occurs, there is no no-stream anomaly, and step S552 is executed.
[0112] Step S551: Issue an alarm message and create a corresponding diagnostic frame based on the timestamp of the auxiliary information.
[0113] Step S552: Discard the sampling results.
[0114] In step S560, based on the streaming media protocol, the diagnostic frame is sent to the client via the server.
[0115] It should be noted that the steps shown in the above process or in the flowchart of the accompanying figures can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0116] In another preferred embodiment, the server acquires the video streams of the monitored areas collected by each terminal device, and further executes steps S530-S552 in the above embodiment on the server, and finally sends the created diagnostic frames from the server to the client.
[0117] This embodiment also provides a video stream no-database anomaly monitoring device, which is used to implement the above embodiments and preferred embodiments, and will not be repeated as described previously. The terms "module," "unit," "subunit," etc., used below can refer to a combination of software and / or hardware that performs a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0118] Figure 6 This is a structural block diagram of the video no-bitstream anomaly monitoring device in this embodiment, as shown below. Figure 6 As shown, the device includes: a first acquisition module 610, a first sampling module 620, and a first diagnostic module 630;
[0119] The first acquisition module 610 is used to acquire the corresponding video streams of each monitoring area.
[0120] The first sampling module 620 is used to sample the video stream based on a preset sampling frequency and monitor the sampling results.
[0121] The first diagnostic module 630 is used to respond to the monitoring results, create a corresponding diagnostic frame based on preset abnormal conditions, and transmit the diagnostic frame to the client through the server.
[0122] The device provided in this embodiment can sample the video stream at a preset sampling frequency in the terminal, and then monitor the sampling results. Based on preset abnormal conditions, it can obtain abnormal situations in the video stream from the monitoring results, create corresponding diagnostic frames containing detailed diagnostic auxiliary information, and send the diagnostic frames to the client through the server. This allows the user to quickly understand and handle video stream abnormalities on the client based on the information contained in the diagnostic frames, thereby solving the problem of not being able to quickly understand and handle video stream abnormalities when they occur.
[0123] Furthermore, by acquiring video streams and analyzing and diagnosing no-bitstream anomalies on various terminal devices, the server load can be reduced, avoiding the problem of high server load caused by centralized diagnosis on the server.
[0124] Figure 7 This is a structural block diagram of a video no-stream anomaly monitoring device in another embodiment, such as... Figure 7 As shown, the device includes: a second acquisition module 710, a second sampling module 720, and a second diagnostic module 730;
[0125] The acquisition module 710 acquires the video stream of the corresponding monitoring area of each terminal device.
[0126] The sampling module 720 is used to sample the video stream based on a preset sampling frequency and monitor the sampling results.
[0127] The diagnostic module 730 is used to create a corresponding diagnostic frame based on preset abnormal conditions in response to monitoring results; and to transmit the diagnostic frame to the client through the server.
[0128] The device provided in this embodiment samples the video stream at a preset sampling frequency in the server, and then monitors the sampling results. Based on preset abnormal conditions, it obtains abnormal situations in the video stream from the monitoring results and creates corresponding diagnostic frames containing detailed diagnostic auxiliary information, which are then sent to the client. This allows the user to quickly understand and handle video stream abnormalities based on the information contained in the diagnostic frames, thereby solving the problem of not being able to quickly understand and handle video stream abnormalities when they occur.
[0129] It should be noted that the above modules can be functional modules or program modules, and can be implemented through software or hardware. For modules implemented through hardware, the above modules can reside in the same processor; or the above modules can be located in different processors in any combination.
[0130] This embodiment provides a video no-stream anomaly monitoring system. Figure 8 This is the corresponding structural block diagram of the video no-bitstream anomaly monitoring system, such as... Figure 8 As shown, the video stream no-bit anomaly monitoring system 800 adopts a network topology, including: client 810, server 820, and multiple terminal devices 830. Figure 9 This is a schematic diagram illustrating the process by which the client receives and processes video frames and diagnostic frames.
[0131] In a system corresponding to the above method embodiments, wherein:
[0132] Client 810 is used to receive video frames and diagnostic frames, and perform corresponding parsing to obtain auxiliary information about abnormal states.
[0133] Specifically, the client can also be a browser or other device capable of monitoring video streams. In the client, users log in to the server and manage multiple terminal devices through the server.
[0134] Server 820 is used to send diagnostic frames sent by terminal devices to the client via a streaming media protocol.
[0135] Terminal device 830 is used to acquire the corresponding video streams of each monitoring area; sample the video streams based on a preset sampling frequency and monitor the sampling results; in response to the monitoring results, create corresponding diagnostic frames based on preset abnormal conditions; and transmit the diagnostic frames to the client through the server.
[0136] In another system corresponding to the above method embodiment, wherein:
[0137] Client 810 is used to receive video frames and diagnostic frames, and perform corresponding parsing to obtain auxiliary information about abnormal states.
[0138] Server 820 is used to acquire video streams from terminal devices, sample the video streams based on a preset sampling frequency, and monitor the sampling results; in response to the monitoring results, it creates corresponding diagnostic frames based on preset abnormal conditions; and transmits the diagnostic frames to the client.
[0139] Terminal device 830 is used to acquire the corresponding video streams of each monitored area.
[0140] This embodiment also provides a computer device, including a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to perform the steps in any of the above method embodiments.
[0141] Optionally, the computer device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.
[0142] It should be noted that the specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementations, and will not be repeated in this embodiment.
[0143] Furthermore, in conjunction with the video no-stream anomaly monitoring method provided in the above embodiments, this embodiment can also provide a storage medium for implementation. This storage medium stores a computer program; when executed by a processor, the computer program implements any of the video no-stream anomaly monitoring methods described in the above embodiments.
[0144] It should be understood that the specific embodiments described herein are merely illustrative of the application and not intended to limit it. All other embodiments derived by those skilled in the art based on the embodiments provided in this application without inventive effort are within the scope of protection of this application.
[0145] Obviously, the accompanying drawings are merely some examples or embodiments of this application. Those skilled in the art can apply this application to other similar situations based on these drawings without any creative effort. Furthermore, it is understood that although the work done in this development process may be complex and lengthy, for those skilled in the art, certain design, manufacturing, or production modifications made based on the technical content disclosed in this application are merely conventional technical means and should not be considered as insufficient disclosure of this application.
[0146] The term "embodiment" in this application refers to a specific feature, structure, or characteristic described in connection with an embodiment that may be included in at least one embodiment of this application. The appearance of this phrase in various places in the specification does not necessarily imply the same embodiment, nor does it imply that it is mutually exclusive with or independent of other embodiments. It will be clearly or implicitly understood by those skilled in the art that the embodiments described in this application may be combined with other embodiments without conflict.
[0147] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of patent protection. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the appended claims.
Claims
1. A method for detecting video stream loss anomalies, characterized in that, include: Obtain the corresponding video streams for each monitored area; The video stream is sampled based on a preset sampling frequency, and the sampling results are monitored. This includes the following steps: The video stream is sampled at the preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp; By monitoring the bitstream values, monitoring results are obtained; In response to monitoring results, a corresponding diagnostic frame is created based on preset abnormal conditions; and the diagnostic frame is transmitted to the client via the server; wherein the process includes the following steps: If the number of zero-bitstream occurrences in the monitoring results meets the abnormal condition, it is determined to be an anomaly with no bitstream; the abnormal condition is that the number of consecutive occurrences of zero bitstream reaches a preset abnormal threshold. The auxiliary information is used to create a corresponding diagnostic frame with the timestamp; and the diagnostic frame is sent to the client via the server based on the streaming media protocol by means of frame interpolation.
2. The video no-stream anomaly monitoring method according to claim 1, characterized in that, Before sampling the video stream based on a preset sampling frequency, the method further includes: The preset sampling frequency is dynamically adjusted based on CPU load conditions; The CPU utilization rate is statistically analyzed based on the preset utilization rate threshold and the preset number of times. If the number of times the CPU utilization rate is lower than the utilization rate threshold reaches the preset number, then the preset sampling frequency is increased, and the preset sampling frequency is kept below the frame rate of the video stream. If the number of times the CPU occupancy rate exceeds the occupancy rate threshold reaches the preset number, then the preset sampling frequency is reduced.
3. The video no-stream anomaly monitoring method according to claim 1, characterized in that, The step of creating a corresponding diagnostic frame based on preset abnormal conditions in response to monitoring results also includes: If the number of zero-bitstream occurrences in the monitoring results does not meet the abnormal condition, the sampling results are discarded, and the video stream is sampled again.
4. The video no-stream anomaly monitoring method according to claim 1, characterized in that, Before acquiring the corresponding video streams for each monitored area, the method further includes: The corresponding video data is collected by sensors in the monitored area; The video data is compressed and encoded to obtain the video stream.
5. A method for detecting video stream loss anomalies, characterized in that, include: Acquire video streams for the corresponding monitoring areas of each terminal device; The video stream is sampled based on a preset sampling frequency, and the sampling results are monitored. This includes the following steps: The video stream is sampled at the preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp; By monitoring the bitstream values, monitoring results are obtained; In response to monitoring results, a corresponding diagnostic frame is created based on preset abnormal conditions; and the diagnostic frame is transmitted to the client; wherein the process includes the following steps: If the number of zero-bitstream occurrences in the monitoring results meets the abnormal condition, it is determined to be an anomaly with no bitstream; the abnormal condition is that the number of consecutive occurrences of zero bitstream reaches a preset abnormal threshold. The auxiliary information is used to create a corresponding diagnostic frame with the timestamp; and the diagnostic frame is sent to the client based on the streaming media protocol by combining interpolated frames.
6. A video stream no-bitrate anomaly monitoring device, characterized in that, include: The system comprises a first acquisition module, a first sampling module, and a first diagnostic module. The first acquisition module is used to acquire the corresponding video streams of each monitoring area; The first sampling module is used to sample the video stream based on a preset sampling frequency and monitor the sampling results; This includes the following steps: The video stream is sampled at the preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp; the monitoring result is obtained by monitoring the bitstream value. The first diagnostic module is used to create a corresponding diagnostic frame based on preset abnormal conditions in response to monitoring results; and to transmit the diagnostic frame to the client through the server; wherein the following steps are included: If the number of zero-bitstream occurrences in the monitoring results meets the abnormal condition, it is determined to be an anomaly with no bitstream; the abnormal condition is that the number of consecutive occurrences of zero bitstream reaches a preset abnormal threshold. The auxiliary information is used to create a corresponding diagnostic frame with the timestamp; and the diagnostic frame is sent to the client via the server based on the streaming media protocol by means of frame interpolation.
7. A video stream no-bitrate anomaly monitoring device, characterized in that, include: The second acquisition module, the second sampling module, and the second diagnostic module; The second acquisition module acquires the video stream of the corresponding monitoring area of each terminal device; The second sampling module is used to sample the video stream based on a preset sampling frequency and monitor the sampling results; This includes the following steps: The video stream is sampled at the preset sampling frequency to obtain the bitstream value, auxiliary information, and timestamp; the monitoring result is obtained by monitoring the bitstream value. The second diagnostic module is used to create a corresponding diagnostic frame based on preset abnormal conditions in response to monitoring results; and to transmit the diagnostic frame to the client; wherein the following steps are included: If the number of zero-bitstream occurrences in the monitoring results meets the abnormal condition, it is determined to be an anomaly with no bitstream; the abnormal condition is that the number of consecutive occurrences of zero bitstream reaches a preset abnormal threshold. The auxiliary information is used to create a corresponding diagnostic frame with the timestamp; and the diagnostic frame is sent to the client based on the streaming media protocol by combining interpolated frames.
8. A computer device, comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to run the computer program to perform the video no-stream anomaly monitoring method according to any one of claims 1 to 4 or 5.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the video no-bitstream anomaly monitoring method according to any one of claims 1 to 4 or 5.
Citation Information
Patent Citations
Abnormal behavior monitoring method, apparatus, computer device, and storage medium
CN109241946A