A video analysis method, device, electronic equipment and storage medium

By dynamically switching analysis modes in the intelligent video analysis system, the problem of uniform computing power consumption among different video streams is solved, computing power optimization based on the characteristics of objects in the video stream is achieved, and the utilization efficiency of the processor is improved.

CN114302100BActive Publication Date: 2025-11-28ZHEJIANG UNIVIEW TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202010997179.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-21
Publication Date
2025-11-28
Estimated Expiration
2040-09-21

AI Technical Summary

Technical Problem

In existing technologies, intelligent video analysis systems consume the same amount of computing power when processing different video streams, resulting in a waste of the system's analytical computing power.

Method used

By dynamically adjusting the analysis mode, combining the first and second analysis modes, and switching the analysis mode according to the characteristic objects in the video stream, the processor's computing power can be saved.

Benefits of technology

It enables dynamic adjustment of computing power based on actual business conditions, reducing processor computing power consumption and improving the utilization efficiency of processor computing power.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114302100B_ABST
    Figure CN114302100B_ABST
Patent Text Reader

Abstract

The application discloses a video analysis method and device, electronic equipment and storage medium. The method comprises the following steps: responding to a video analysis request sent by a video acquisition device; the video analysis request carries a video stream to be analyzed; a first analysis mode is used to analyze the video stream to be analyzed; if the video stream to be analyzed meets a first preset condition, the first analysis mode is switched to a second analysis mode; when the second analysis mode is used to analyze the video stream to be analyzed, if the video stream to be analyzed meets a second preset condition, the second analysis mode is switched to the first analysis mode, so that the first analysis mode and the second analysis mode are used to analyze the video stream to be analyzed. According to the technical scheme, the analysis mode of the video to be analyzed is dynamically switched according to the preset condition, so that the dynamic adjustment of the calculation power according to the actual business condition is realized.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present application relate to the technical field of computer, and particularly relate to a video analysis method and device, electronic equipment and storage medium. BACKGROUND

[0002] In recent years, video monitoring systems have been applied in urban traffic management, public security monitoring, community security and other fields. In order to realize efficient safety monitoring and detection management, intelligent video analysis technology has also developed rapidly.

[0003] The current intelligent video analysis process is generally as follows: first, open intelligent analysis for a certain road or several network cameras (IP Camera, IPC), send the video stream of the IPC opened for analysis to the intelligent software to start analysis, the intelligent software equally samples pictures in the video stream, intelligently analyzes each sampled picture, and then reports the feature results obtained by analysis.

[0004] However, the prior art uses the same analysis mode to analyze different video streams, and the same computing power is consumed for analyzing different video streams. The above analysis method will cause waste of system analysis computing power. SUMMARY

[0005] The present application provides a video analysis method, device, electronic equipment and storage medium to dynamically adjust the analysis mode of the video stream to be analyzed.

[0006] In a first aspect, the embodiments of the present application provide a video analysis method executed by a processor, comprising:

[0007] In response to a video analysis request sent by a video collection device, the video analysis request carrying a video stream to be analyzed;

[0008] The first analysis mode is used to analyze the video stream to be analyzed, and if the video stream to be analyzed meets a first preset condition, the first analysis mode is switched to a second analysis mode;

[0009] When the second analysis mode is used to analyze the video stream to be analyzed, if the video stream to be analyzed meets a second preset condition, the second analysis mode is switched to the first analysis mode, so as to analyze the video stream to be analyzed by using the first analysis mode and the second analysis mode.

[0010] In a second aspect, the embodiments of the present application further provide a video analysis device configured in a processor, comprising:

[0011] A response module is configured to respond to a video analysis request sent by a video collection device, the video analysis request carrying a video stream to be analyzed;

[0012] The first analysis module is configured to analyze the video stream to be analyzed by using a first analysis mode, and if the video stream to be analyzed meets a first preset condition, switch the first analysis mode to a second analysis mode.

[0013] The second analysis module is configured to, when analyzing the video stream to be analyzed by using the second analysis mode, if the video stream to be analyzed meets a second preset condition, switch the second analysis mode to the first analysis mode, so as to analyze the video stream to be analyzed by using the first analysis mode and the second analysis mode.

[0014] In a third aspect, an electronic device is provided, and the electronic device includes:

[0015] one or more processors;

[0016] a memory device configured to store one or more programs,

[0017] When the one or more programs are executed by the one or more processors, the one or more processors implement a video analysis method according to any of the embodiments of the present application.

[0018] In a fourth aspect, a computer readable storage medium is provided, and the computer readable storage medium stores a computer program, and the computer program is executed by a processor to implement a video analysis method according to any of the embodiments of the present application.

[0019] The present application analyzes the video stream to be analyzed carried in the video analysis request by using the first analysis mode in response to the video analysis request sent by the video acquisition device, switches the first video analysis mode to the second analysis mode when the video stream to be analyzed meets the first preset condition, and then continues to analyze the video stream to be analyzed by using the second analysis mode. In the process of analysis, if the video stream to be analyzed meets the second preset condition, the second analysis mode is switched to the first analysis mode again, so as to analyze the video stream to be analyzed by using the first analysis mode and the second analysis mode in combination. The technical solution of the embodiments of the present application dynamically switches the analysis mode of the video to be analyzed according to the preset condition, so as to realize the dynamic adjustment of the computing power according to the actual business situation. BRIEF DESCRIPTION OF DRAWINGS

[0020] Figure 1 A flowchart of a video analysis method is provided for the embodiments of the present application;

[0021] Figure 2 A schematic diagram of analysis by using the first analysis mode is provided for the embodiments of the present application;

[0022] Figure 3A schematic diagram of the video analysis method provided by the embodiment of the present application is shown in FIG. 1.

[0023] Figure 4 A flow chart of another video analysis method provided by the embodiment of the present application is shown in FIG. 2.

[0024] Figure 5 A structure schematic diagram of a video analysis device provided by the embodiment of the present application is shown in FIG. 3.

[0025] Figure 6 A structure schematic diagram of an electronic device provided by the embodiment of the present application is shown in FIG. 4. DETAILED DESCRIPTION

[0026] The present application will be further described below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application. In addition, it should be noted that, for the convenience of description, only the parts related to the present application are shown in the drawings, but not all the structures.

[0027] Figure 1 A flow chart of a video analysis method provided by the embodiment of the present application is shown in FIG. 1. The embodiment can be applied to the case of analyzing a video. The method is executed by a processor, and can be executed by a video analysis device. The device can be realized by software and / or hardware. The processor in the embodiment can be a chip or other hardware device providing computing power.

[0028] Referring to FIG. 1, the method specifically includes the following steps. Figure 1

[0029] S110, responding to a video analysis request sent by a video collection device. The video analysis request carries a video stream to be analyzed.

[0030] The video collection device can be any video collection device, for example, an IPC for collecting monitoring video.

[0031] For example, when the video analysis function is started for one or more IPCs, the corresponding IPCs will upload the collected video stream as the video stream to be analyzed.

[0032] S120, analyzing the video stream to be analyzed by using a first analysis mode. If the video stream to be analyzed meets a first preset condition, the first analysis mode is switched to a second analysis mode.

[0033] For example, the first analysis mode can be feature object contour sampling detection and video segment analysis on the video stream to be analyzed, and the second analysis mode can be a video stream analysis mode.

[0034] ​Generally, the feature object contour sampling detection in the first analysis mode occupies less processor computing power than the second analysis mode, so the first analysis mode is used to analyze the video to be analyzed in this embodiment to save processor computing power.

[0035] Referring to Figure 2 , the first analysis mode is used to analyze the video stream to be analyzed, including: sampling the video stream to be analyzed at a preset sampling interval to generate a sequence of pictures to be analyzed; performing contour analysis on the pictures in the sequence of pictures to be analyzed, and regarding the pictures in the sequence of pictures to be analyzed that have target contour information as target pictures; marking the video in a certain time range at the corresponding time position of each target picture in the video stream to be analyzed as a video segment to be analyzed; and analyzing each video segment to be analyzed to obtain target feature information in the video stream to be analyzed. In this embodiment, when the first analysis mode is used to sample the video stream to be analyzed, only the sampled pictures are subjected to simple contour analysis, and then the video segments to be analyzed are determined according to the results of the contour analysis.

[0036] The target feature information is feature information of a feature object contained in the video to be analyzed, and exemplary, can be feature information such as a face and a license plate in the video stream to be analyzed. The collection time range corresponding to the above-mentioned video segment to be analyzed can be determined according to the actual video collection scene. For example, if the current video collection device collects video information of pedestrians crossing the road, the collection time range of the video segment to be analyzed can be set to be small if the pedestrians pass through the current road in a very short time, and vice versa.

[0037] Further, after the video segment to be analyzed is determined, the video segment to be analyzed is read out and added to a video segment to be analyzed queue. When the processor is idle, the queue continuously sends the video segment to be analyzed in the queue to the processor for analysis.

[0038] Further referring to Figure 3 , the second analysis mode is used to analyze the video stream to be analyzed, including: equally spaced picture sampling of the video stream to be analyzed; and performing feature analysis on each picture sampled to obtain target feature information of the video stream to be analyzed. In this embodiment, when the second analysis mode is used to analyze the video stream to be analyzed, detailed feature analysis is performed on the sampled pictures, and then the target feature information of the video stream to be analyzed is obtained according to the results of the feature analysis.

[0039] The first preset condition can be determined according to the time length of the video stream to be analyzed that is marked as a video segment to be analyzed. When the video analysis is performed by using the first analysis mode, if there are more videos marked as the video segment to be analyzed, the video analysis by using the first analysis mode not only consumes more calculation power for analyzing the video segment to be analyzed, but also consumes certain calculation power for detecting the contour sampling of the feature object. Therefore, when there are more feature objects in the video to be analyzed, the first analysis mode consumes more calculation power, and the first analysis mode needs to be switched to the second analysis mode, so as to select a suitable analysis mode according to the actual situation of the feature objects in the video to be analyzed, thereby achieving the purpose of saving the calculation power of the processor.

[0040] In S130, when the video stream to be analyzed is analyzed by using the second analysis mode, if the video stream to be analyzed meets the second preset condition, the second analysis mode is switched to the first analysis mode, so as to analyze the video stream to be analyzed by using the first analysis mode and the second analysis mode.

[0041] In this embodiment, when the video stream to be analyzed meets the first preset condition, the first analysis mode is switched to the second analysis mode, and the video stream to be analyzed after the analysis by the first analysis mode is continuously analyzed by using the second analysis mode.

[0042] The second preset condition is also determined according to the number of feature objects contained in the video stream to be analyzed. When the feature objects in the video stream to be analyzed are not detected in a time period exceeding a certain threshold, it is indicated that the feature objects in the current video stream to be analyzed are less. The second analysis mode is to analyze all video streams, and if the second analysis mode is continued to be used, the calculation power of the processor will be wasted. Therefore, the second analysis mode needs to be switched to the first analysis mode.

[0043] Typically, the analysis mode combined by using two analysis modes in the embodiment of the present application can obviously save the calculation power of the processor when the feature objects in the video stream to be analyzed are less.

[0044] For example, the total calculation power of a single processor is 1, the calculation power of single-channel feature object contour sampling detection is 1 / M, the calculation power of video stream analysis is 1 / N, and it is assumed that the time length of the feature object appearing in the video stream of an average single-channel image acquisition device in one day accounts for E% of the total time length.

[0045] Therefore, when the video stream analysis mode in the prior art is used, the calculation power A of single-channel video analysis is 1 / N.

[0046] When the two analysis mode combined mode in the present solution is used, the total calculation power of single-channel video analysis is B = (E / 100 (1 / N) + 1 / M) = (E / 100 + N / M) (1 / N)。

[0047] Therefore, the smaller E is or N / M is, the smaller B is. When (E / 100 + N / M) < 1, B < A, that is, when the feature information in the video stream is less or the proportion of the single-channel feature object contour sampling detection to the single-channel video stream analysis is low, the technical solution of the embodiment can consume less computing power than the video stream (second analysis mode) analysis alone.

[0048] In actual application, the total time in the proportion of the time of the feature object to the total time can be several hours to tens of hours according to different user requirements for the analysis result delay, so that the analysis task is distributed to the time period, the peak demand for computing power is smoothed, and the total computing power required by the user is also lower.

[0049] Further, in the embodiment, when the total computing power required by the video stream to be analyzed is greater than the computing power that can be provided by the current processor, the analysis task can be automatically accumulated and processed when the processor computing power is idle.

[0050] The technical solution of the embodiment of the application, in response to the video analysis request sent by the video acquisition device, first analyzes the video stream to be analyzed carried in the video analysis request by using the first analysis mode, switches the first video analysis mode to the second analysis mode when the video stream to be analyzed meets the first preset condition, and then continues to analyze the video stream to be analyzed by using the second analysis mode. In the process of analysis, if the video stream to be analyzed meets the second preset condition, the second analysis mode is switched to the first analysis mode, so as to analyze the video stream to be analyzed by combining the first analysis mode and the second analysis mode. The technical solution of the embodiment of the application dynamically switches the analysis mode of the video to be analyzed according to the preset condition, so as to dynamically adjust the computing power according to the actual business situation.

[0051] Further, on the basis of the above embodiment, the preset sampling interval is determined according to the available computing power of the processor. The greater the available computing power of the processor is, the smaller the preset sampling interval is. For example, when the processor computing power is idle, the sampling interval of the sampling time of the feature object contour sampling detection in the first analysis mode can be automatically reduced. When the computing power is fully loaded, the sampling interval of the sampling time of the feature object contour sampling detection in the first analysis mode can be automatically reduced, so as to realize dynamic scheduling of computing power.

[0052] More specifically, the total computing power of the processor is S, and in this embodiment, the computing power of the processor can be divided into two parts, the first part is used for feature object contour sampling detection, and in the case of setting the maximum sampling interval T1, the required minimum computing power is represented as S1, wherein T1 is the sampling interval set by the user, and the actual analysis sampling interval will be less than or equal to T1; the second part is used for analyzing the video segment to be analyzed, and the occupied computing power is represented as S2, S1+S2 is always less than or equal to the total computing power S.

[0053] When the analysis accuracy is inclined, the computing power S2 occupied by the analysis of the video segment to be analyzed is reduced, and S1 is increased at the same time, so that the sampling analysis interval is less than the original maximum sampling interval T1 due to the increase of S1, and stronger sampling analysis intensity is obtained. When the analysis real-time performance is inclined, S1 remains unchanged, and S2=S-S1 is set, so that all the computing power except the minimum computing power required for feature object contour sampling detection is used for the analysis of the video segment to be analyzed, so as to obtain the fastest processing speed and realize the demand for video real-time processing.

[0054] Figure 4 Another flowchart of the video analysis method provided by the embodiment of the application is provided, and the first preset condition and the second preset condition are further refined on the basis of the above-mentioned embodiment, and the specific implementation of the first preset condition and the second preset condition is provided, as shown in Figure 4 The method comprises the following steps.

[0055] S210, in response to the video analysis request sent by the video acquisition device; the video analysis request carries the video stream to be analyzed.

[0056] S220, using the first analysis mode to analyze the video stream to be analyzed, and judging whether the video stream to be analyzed has a video stream that is continuously longer than the first time threshold and is marked as a video segment to be analyzed.

[0057] In this embodiment, in the process of using the first analysis mode to analyze the video stream to be analyzed, if the video stream to be analyzed has a video stream that is continuously longer than the first time threshold and is marked as a video segment to be analyzed, it indicates that the feature object contained in the video stream to be analyzed is more, and at this time, the video analysis using the first analysis mode not only consumes more computing power for the analysis of the video segment to be analyzed, but also consumes a certain computing power for the feature object contour sampling detection, and the computing power consumed by using the first analysis mode is greater than that consumed by using the second analysis mode. Therefore, when the first analysis mode is used to analyze the video to be analyzed, the above-mentioned conversion condition needs to be judged to realize the dynamic adjustment of the analysis mode.

[0058] S230, if yes, switching the first analysis mode to a second analysis mode.

[0059] S240, when analyzing the video stream to be analyzed by using the second analysis mode, judging whether the video stream to be analyzed has a video whose duration exceeds a second duration threshold and in which no target feature information is detected.

[0060] In the embodiment, when analyzing the video to be analyzed by using the second analysis mode, if the video to be analyzed has a video whose duration exceeds the second duration threshold and in which no target feature information is detected, it indicates that the video to be analyzed contains less feature objects, and analyzing the video to be analyzed by using the second analysis mode will waste the processing power of the processor. Therefore, when analyzing the video to be analyzed by using the second analysis mode, the duration in which no target feature information is detected in the video to be analyzed is collected to determine whether the analysis mode needs to be switched.

[0061] S250, if yes, switching the second analysis mode to the first analysis mode.

[0062] The technical solution of the embodiment of the application, when analyzing the video to be analyzed by using the first analysis mode, if the video to be analyzed has a video whose duration exceeds the first duration threshold, the first analysis mode is switched to the second analysis mode; when analyzing the video to be analyzed by using the second analysis mode, if the video stream to be analyzed has a video whose duration exceeds the continuous duration threshold and in which no target feature information is detected, the second analysis mode is switched to the first analysis mode, the analysis mode is dynamically switched in the process of video analysis according to the set condition, the dynamic adjustment of the processing power is realized, and the utilization efficiency of the processing power is improved.

[0063] Figure 5 A structural schematic diagram of a video analysis device provided by the embodiment of the application is configured in a processor. The video analysis device provided by the embodiment of the application can execute the video analysis method provided by any embodiment of the application. Referring to FIG. 5, Figure 5 The device includes a response module 510, a first analysis module 520, and a second analysis module 530.

[0064] The response module 510 is configured to respond to a video analysis request sent by a video collection device, and the video analysis request carries a video stream to be analyzed.

[0065] The first analysis module 520 is configured to analyze the video stream to be analyzed by using a first analysis mode, and if the video stream to be analyzed meets a first preset condition, the first analysis mode is switched to a second analysis mode.

[0066] The second analysis module 530 is configured to switch the second analysis mode to the first analysis mode when the second analysis mode is used to analyze the video stream to be analyzed, and the second preset condition is met, so as to analyze the video stream to be analyzed by using the first analysis mode and the second analysis mode.

[0067] Further, the first analysis module 520 is specifically configured to sample the video stream to be analyzed at a preset sampling interval to generate a sequence of pictures to be analyzed.

[0068] The pictures to be analyzed in the sequence of pictures to be analyzed that contain target feature information are regarded as target pictures.

[0069] The video in a certain time range of the target pictures at corresponding time positions in the video stream to be analyzed is marked as a video segment to be analyzed.

[0070] The video segments to be analyzed are analyzed to obtain target feature information in the video stream to be analyzed.

[0071] The second analysis module 530 is specifically configured to sample the video stream to be analyzed at equal intervals.

[0072] Each picture sampled is analyzed to obtain target feature information in the video stream to be analyzed.

[0073] Further, the first analysis module 520 is specifically configured to determine whether there is video that continuously exceeds a first time threshold and is marked as a video segment to be analyzed in the video stream to be analyzed.

[0074] If yes, the first analysis mode is switched to the second analysis mode.

[0075] The second analysis module 530 is specifically configured to determine whether there is video that continuously exceeds a second time threshold and no target feature information is detected in the video stream to be analyzed.

[0076] If yes, the second analysis mode is switched to the first analysis mode.

[0077] Optionally, the preset sampling interval is determined according to the available computing power of a processor.

[0078] The video analysis device provided in the embodiment of the application can execute the video analysis method provided in any embodiment of the application, and has the corresponding function modules and beneficial effects of the execution method.

[0079] Figure 6 A structural schematic diagram of an electronic device provided in the embodiment of the application. Figure 6A block diagram is shown of an exemplary electronic device 12 suitable for implementing embodiments of the present invention. Figure 6 The electronic device 12 shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of the present invention.

[0080] like Figure 6 As shown, the electronic device 12 is represented in the form of a general-purpose computing device. The components of the electronic device 12 may include, but are not limited to: one or more processors or processing units 16, system memory 28, and bus 18 connecting different system components (including system memory 28 and processing unit 16).

[0081] Bus 18 represents one or more of several bus architectures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration port, a processor, or a local bus using any of the various bus architectures. For example, these architectures include, but are not limited to, the Industry Standard Architecture (ISA) bus, the Micro Channel Architecture (MAC) bus, the Enhanced ISA bus, the Video Electronics Standards Association (VESA) local bus, and the Peripheral Component Interconnect (PCI) bus.

[0082] Electronic device 12 typically includes a variety of computer system readable media. These media can be any available media that can be accessed by electronic device 12, including volatile and non-volatile media, removable and non-removable media.

[0083] System memory 28 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) 30 and / or cache memory 32. Electronic device 12 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, storage system 34 may be used to read and write non-removable, non-volatile magnetic media (… Figure 6 Not shown; usually referred to as a "hard drive"). Although ​ Not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk") and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 18 via one or more data media interfaces. Memory 28 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of the embodiments of the present invention.

[0084] Program / utility 40 having a set of program modules 42 can be stored in memory 28 by way of example, such program modules 42 include an operating system, one or more application programs, other program modules, and program data, each or some combination thereof, which can include implementation of the network environment as in each of the above examples or some combination thereof. Program modules 42 generally carry out the functions and / or methodologies of embodiments of the application as described herein.

[0085] Electronic device 12 can also communicate with one or more external devices 14 such as a keyboard or pointing device, a display 24, etc. ; other devices such as are well known in the art. Communication with such devices can be effected by input / output (I / O) interfaces 22. Additionally, electronic device 12 can communicate with one or more networks such as a local area network (LAN), a wide area network (WAN), and / or a public network such as the Internet, by way of network adapter 20. As pictured, network adapter 20 communicates with the other components of electronic device 12 by way of bus 18. It should be appreciated that other hardware and / or software modules can be used in conjunction with electronic device 12 such as, but not limited to, microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data archival storage systems, etc. without deviating from the spirit of the present application.

[0086] Processing unit 16 performs various function applications and data processing by running programs stored in system memory 28, such as implementing a video analysis method provided by embodiments of the present application.

[0087] Embodiments of the present application also provide a computer readable storage medium, having stored thereon a computer program, which when executed by a processor, implements a video analysis method as any of the embodiments of the present application, wherein the method comprises:

[0088] in response to a video analysis request sent by a video collection device; the video analysis request carrying a video stream to be analyzed;

[0089] analyzing the video stream to be analyzed by using a first analysis mode, and if the video stream to be analyzed meets a first preset condition, switching the first analysis mode to a second analysis mode;

[0090] when analyzing the video stream to be analyzed by using the second analysis mode, if the video stream to be analyzed meets a second preset condition, switching the second analysis mode to the first analysis mode, so as to analyze the video stream to be analyzed by using the first analysis mode and the second analysis mode.

[0091] The computer storage media of embodiments of the present application can be any available media that is accessible by a computer. The computer readable media can be a computer readable signal medium or a computer readable storage medium. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples (a non-exhaustive list) of the computer readable storage medium include the following: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In this document, the computer readable storage medium can be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.

[0092] A computer readable signal medium can include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated signal can take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium can be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.

[0093] Program code embodied on a computer readable medium can be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.

[0094] Computer program code for carrying out operations of the present application can be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider). These implementations can provide for a great deal of flexibility, portability, and adaptability as well as the convenience

[0095] Note that the above merely describes preferred embodiments of the present application and the principles of the technology applied. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and that various obvious changes, modifications and substitutions can be made without departing from the scope of the present application. Therefore, although the present application has been described in detail through the above embodiments, the present application is not limited to the above embodiments, and can include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the claims.

Claims

1. A method of video analytics, characterized by, executed by a processor, comprising: in response to a video analysis request sent by a video collection device; the video analysis request carrying a video stream to be analyzed; using a first analysis mode to analyze the video stream to be analyzed, if the video stream to be analyzed meets a first preset condition, switching the first analysis mode to a second analysis mode; wherein the first analysis mode is to sample the video stream to be analyzed, to perform contour analysis on the sampled pictures, and to determine video segments to be analyzed according to the results of the contour analysis; the second analysis mode is to sample the video stream to be analyzed at equal intervals; to perform feature analysis on each picture sampled to obtain target feature information of the video stream to be analyzed; when the second analysis mode is used to analyze the video stream to be analyzed, if the video stream to be analyzed meets a second preset condition, switching the second analysis mode to the first analysis mode to analyze the video stream to be analyzed by dynamically switching the first analysis mode and the second analysis mode; wherein the first preset condition is determined according to the length of the video stream to be analyzed that is marked as a video segment to be analyzed, and the second preset condition is determined according to the length of the video stream to be analyzed that is not detected as a feature object; the video stream to be analyzed meets the first preset condition if more than a first time threshold of continuous video in the video stream to be analyzed is marked as a video segment to be analyzed; and the video stream to be analyzed meets the second preset condition if more than a second time threshold of continuous video in the video stream to be analyzed is not detected as target feature information.

2. The method of claim 1, wherein, using the first analysis mode to analyze the video stream to be analyzed, comprising: sampling the video stream to be analyzed at a preset sampling interval to generate a sequence of pictures to be analyzed; performing contour analysis on the pictures in the sequence of pictures to be analyzed, and taking the pictures in the sequence of pictures to be analyzed that have target contour information as target pictures; marking the video within a certain time range of the corresponding time position of each target picture in the video stream to be analyzed as a video segment to be analyzed; analyzing each video segment to be analyzed to obtain target feature information in the video stream to be analyzed.

3. The method of claim 2, wherein, The preset sampling interval is determined according to the available computing power of the processor; The greater the available computing power of the processor, the smaller the preset sampling interval.

4. A video analytics apparatus, characterized by, configured in a processor, comprising: a response module, configured to respond to a video analysis request sent by a video collection device; the video analysis request carrying a video stream to be analyzed; a first analysis module, configured to use a first analysis mode to analyze the video stream to be analyzed, if the video stream to be analyzed meets a first preset condition, switching the first analysis mode to a second analysis mode; wherein the first analysis mode is to sample the video stream to be analyzed, to perform contour analysis on the sampled pictures, and to determine video segments to be analyzed according to the results of the contour analysis; the second analysis mode is to sample the video stream to be analyzed at equal intervals; to perform feature analysis on each picture sampled to obtain target feature information of the video stream to be analyzed; The second analysis module is configured to, when the second analysis mode is used to analyze the video stream to be analyzed, if the video stream to be analyzed meets a second preset condition, switch the second analysis mode to a first analysis mode, so as to analyze the video stream to be analyzed by dynamically switching the first analysis mode and the second analysis mode. The first preset condition is determined according to a time length of a video segment to be analyzed marked in the video stream to be analyzed, and the second preset condition is determined according to a time length of a feature object not detected in the video stream to be analyzed. The video stream to be analyzed meets the first preset condition if a video segment to be analyzed that is continuously longer than a first time length threshold is marked in the video stream to be analyzed. The video stream to be analyzed meets the second preset condition if a video that is continuously longer than a second time length threshold does not detect target feature information in the video stream to be analyzed.

5. The apparatus of claim 4, wherein, The first analysis module is specifically configured to: sample the video stream to be analyzed at a preset sampling interval to generate a sequence of pictures to be analyzed; mark a picture to be analyzed in the sequence of pictures to be analyzed as a target picture if the picture to be analyzed contains target feature information; mark a video in a certain time range of a corresponding time position of each target picture in the video stream to be analyzed as a video segment to be analyzed; analyze each video segment to be analyzed to obtain target feature information in the video stream to be analyzed.

6. An electronic device, comprising: The electronic device comprises: one or more processors; a storage device configured to store one or more programs, when the one or more programs are executed by the one or more processors, the one or more processors implement a video analysis method according to any one of claims 1-3.

7. A computer-readable storage medium having stored thereon a computer program, characterized in that The program is executed by the processor to implement a video analysis method according to any one of claims 1-3.

Citation Information

Patent Citations

  • Multi-mode video event indexing

    CN103069434A

  • Distributed video analysis method and system thereof

    CN104333732A