CN112040090A - Video stream processing method and device, electronic equipment and storage medium - Google Patents

Video stream processing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112040090A
CN112040090A CN202010794486.6A CN202010794486A CN112040090A CN 112040090 A CN112040090 A CN 112040090A CN 202010794486 A CN202010794486 A CN 202010794486A CN 112040090 A CN112040090 A CN 112040090A
Authority
CN
China
Prior art keywords
video stream
target
target objects
processing
processing parameters
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010794486.6A
Other languages
Chinese (zh)
Inventor
李伟
郑佳
马东星
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Dahua Technology Co Ltd
Original Assignee
Zhejiang Dahua Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Dahua Technology Co Ltd filed Critical Zhejiang Dahua Technology Co Ltd
Priority to CN202010794486.6A priority Critical patent/CN112040090A/en
Publication of CN112040090A publication Critical patent/CN112040090A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/14Picture signal circuitry for video frequency region
    • H04N5/144Movement detection
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/18Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The disclosure discloses a video stream processing method, a video stream processing device, an electronic device and a storage medium. To solve the following problems: when a plurality of tasks run simultaneously, the quantity of key target information contained in video streams received by each channel is different, and the resource coordination among the channels is achieved. In the embodiment of the disclosure, an access module is accessed to a plurality of front-end devices, simultaneously pulls in a code stream, and decodes the code stream through a code stream decoding module, a code stream analysis module counts and analyzes the number of target objects detected by each frame of image in the code stream within a period of time, and different sampling rates and image resolutions are selected through a sampling module and a resolution module according to different numbers of the target objects; on the basis of the traditional scheme, the processing parameters of the target video stream are dynamically determined and adjusted according to the number of the target objects between the analysis of the number of the target objects contained in the target video stream and the determination of the processing parameters of the target video stream, so that the utilization rate of processing resources is improved.

Description

Video stream processing method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of monitoring technologies, video analysis, event detection, and intelligent analysis technologies, and in particular, to a method and an apparatus for processing a video stream, an electronic device, and a storage medium.
Background
In the field of video monitoring, because video resources occupy a large amount and the number of paths is large, a resource coordination method is often used to realize load balancing, so that the resource utilization rate of equipment is improved.
At present, in the related art, load balancing is mostly achieved in how to distribute and assign multiple tasks to which processing node for processing, or when the processing flow of the same task is complex, different processing nodes may be responsible for different processing flows, and multiple processing nodes cooperatively process the same task.
However, the load balancing problem of the related art still needs to be optimized, and the resource utilization rate also needs to be improved.
Disclosure of Invention
The present disclosure aims to provide a video stream processing method, apparatus, electronic device and storage medium, so as to solve the following problems: when a plurality of tasks run simultaneously, the number of key target information contained in the video stream received by each channel is different, and the resources of each channel are coordinated.
In a first aspect, an embodiment of the present disclosure provides a video stream processing method:
receiving a target video stream;
analyzing the number of target objects contained in the target video stream;
determining processing parameters of the target video stream according to the number of the target objects, wherein the processing parameters comprise the sampling rate of the target video stream and/or the resolution of pictures;
and processing the target video stream based on the processing parameters.
In one embodiment, the number of target objects is positively correlated with both the sampling rate and the resolution in the processing parameters.
In one embodiment, the determining the processing parameters of the target video stream according to the number of the target objects includes:
if the number of the target objects is changed, determining the change proportion of the number of the target objects;
if the number of the target objects is increased, increasing the processing parameter value by the change proportion;
if the number of the target objects is reduced, reducing the processing parameter value by the change proportion.
In one embodiment, the determining the processing parameters of the target video stream according to the number of the target objects includes:
determining an interval range corresponding to the number of the target objects;
and acquiring the processing parameters corresponding to the interval range.
In one embodiment, the processing the target video stream based on the processing parameter includes:
acquiring images from the video stream based on the processing parameters;
performing target object detection on the image to obtain the number of the target objects in the image;
the analyzing the number of target objects contained in the target video stream includes:
and accumulating the number of the target objects in the images to the total number of the target objects detected from the video stream in a specified time length, and calculating the number of the target objects averagely contained in each frame of image in the specified time length as the number of the target objects contained in the target video stream.
In a second aspect, an embodiment of the present disclosure further provides a video stream processing apparatus, including:
an access module for receiving a target video stream;
a target detection module for analyzing the number of target objects contained in the target video stream;
the code stream analysis module is used for determining processing parameters of the target video stream according to the number of the target objects, wherein the processing parameters comprise the sampling rate of the target video stream and/or the resolution of pictures;
and the parameter processing module is used for processing the target video stream based on the processing parameters.
In one embodiment, the video stream processing apparatus further includes:
and the parameter determining unit is used for determining the sampling rate and the resolution in the processing parameters according to the number of the target objects.
The number of target objects is positively correlated with both sampling rate and resolution in the processing parameters.
In one embodiment, the code stream analysis module includes:
if the number of the target objects is changed, determining the change proportion of the number of the target objects;
if the number of the target objects is increased, increasing the processing parameter value by the change proportion;
if the number of the target objects is reduced, reducing the processing parameter value by the change proportion.
In one embodiment, the code stream analysis module further includes:
determining an interval range corresponding to the number of the target objects;
and acquiring the processing parameters corresponding to the interval range.
In one embodiment, the object detection module further comprises:
acquiring images from the video stream based on the processing parameters;
performing target object detection on the image to obtain the number of the target objects in the image;
the analyzing the number of target objects contained in the target video stream includes:
and accumulating the number of the target objects in the images to the total number of the target objects detected from the video stream in a specified time length, and calculating the number of the target objects averagely contained in each frame of image in the specified time length as the number of the target objects contained in the target video stream.
In a third aspect, another embodiment of the present disclosure also provides an electronic device, including at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform any one of the methods provided by the embodiments of the first aspect of the present disclosure.
In a fourth aspect, another embodiment of the present disclosure further provides a computer storage medium, where the computer storage medium stores a computer program, and the computer program is used to make a computer execute any one of the methods provided in the embodiments of the first aspect of the present disclosure.
Compared with the prior art, the method and the device can realize the multi-channel concurrency of conventional processing, process more channels under the condition that the detection targets of all the channels appear less at the same time, and fully utilize software and hardware resources of the system.
Additional features and advantages of the disclosure will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by the practice of the disclosure. The objectives and other advantages of the disclosure may be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
Fig. 1 is an application scene diagram of a video stream processing method provided by an embodiment of the present disclosure;
fig. 2 is a schematic flow chart of a video stream processing method according to an embodiment of the present disclosure;
FIG. 3 is a schematic diagram illustrating an embodiment of the present disclosure for determining a change ratio of a processing parameter according to a change ratio of a key target average N;
FIG. 4 is a schematic diagram illustrating an exemplary process parameter interval range determined according to an interval range of a key target average N according to an embodiment of the present disclosure;
fig. 5 is a schematic diagram of a video stream processing method provided by an embodiment of the present disclosure;
fig. 6 is a schematic structural diagram of an apparatus of a video stream processing method according to an embodiment of the present disclosure;
fig. 7 is a schematic view of an electronic device according to an embodiment of the disclosure.
Detailed Description
The inventor researches and discovers that in the field of video monitoring, due to the fact that video resources occupy large and the number of paths is large, a resource coordination method is often used for assisting load balancing, and therefore resource utilization rate of equipment is improved. Although load balancing can increase the utilization of processing resources to some extent. However, how to better utilize processing resources is still a concern in the industry.
The inventor researches and discovers that although in the related art, a plurality of tasks can be distributed to different processing nodes for processing through load balancing, and the same task can be cooperatively processed among different processing nodes to improve the resource utilization rate, the same processing node has an optimized aspect when processing video streams.
The inventor researches and discovers that the prior art provides a method for realizing serial processing to parallel processing through horizontal extension when simultaneously processing multitask (namely, multi-channel) intelligent analysis, and the method is only a simple parallel distribution scheme; in the prior art, a plurality of links of the same analysis task are clustered transversely, and the time limit resource of task clustering processing which needs to consume the same resource is maximized; the prior art only provides a method for overall resource allocation, and does not solve the problem of resource cooperation among tasks.
For example, in an application scenario of video stream processing, one task processing node in the prior art can process multiple video streams, and one video stream can be processed by multiple channels (one task, one channel) simultaneously. However, the inventor researches and finds that the related art does not solve the problem of resource coordination among channels when a plurality of tasks run simultaneously and the amount of key target information contained in video streams received by the channels is different. It becomes necessary how to realize resource coordination between the channels.
In view of the above, the present disclosure provides a video stream processing method, apparatus, electronic device and storage medium to solve the above problems.
The same processing node is accessed to a plurality of front-end devices, each front end simultaneously pulls in a code stream, and for the same code stream or different code streams, the fixed sampling rate and resolution ratio can not realize more fine dynamic adjustment and allocation of processing resources, so the inventive concept of the disclosure is as follows: on the basis of the traditional scheme, the processing parameters of the target video stream are dynamically determined and adjusted according to the number of the target objects between the analysis of the number of the target objects contained in the target video stream and the determination of the processing parameters of the target video stream, so that the utilization rate of processing resources is improved. For example, the problem that when the number of key targets is large, the accuracy is low due to the fact that the sampling rate is large or the picture resolution is small can be solved; when the number of the key targets is small, the extraction sample rate is small, the picture resolution is large, and system resources are wasted.
The video stream processing method provided by the present disclosure is applicable to various electronic devices, such as, but not limited to, computers, laptops, tablets, etc., or other types of electronic devices.
The following describes a video stream processing method in the embodiments of the present disclosure in detail with reference to the drawings.
Referring to fig. 1, an application scenario diagram of a video stream processing method according to an embodiment of the present disclosure is shown.
As shown in fig. 1, the application environment may include, for example, a network 10, a server 20, at least one monitoring device 30, a terminal device 40, and a database 50. Wherein:
the monitoring device 30 is used for collecting images in a monitoring range, transmitting the collected video stream to the server 20 through the network 10, and storing the video stream in the database 50 by the server 20.
The terminal device 40 may send a monitoring image obtaining request to the server 20, and the server 20 obtains a corresponding image from the database 50 in response to the monitoring image obtaining request and returns the corresponding image to the terminal device 40 for display.
In the present disclosure, in order to enable adaptive adjustment of processing parameters, the number of target objects to be acquired can be determined by an image analysis technique, and then processing parameters are determined according to the number of target objects, thereby enabling adaptive adjustment of processing parameters.
In the application scenario shown in fig. 1, the video stream processing may be performed by the monitoring devices 30 individually, and when the processing performance of the monitoring devices is insufficient for various reasons, the video stream may be acquired by the monitoring devices 30 and then sent to the server through the network 10, and the processing of the video stream is realized by the server in a centralized manner.
Only a single server or terminal device is detailed in the description of the present disclosure, but it will be understood by those skilled in the art that the monitoring device 30, the terminal device 40, the server 20 and the database 50 are shown to be intended to represent the operation of the monitoring device, the terminal device, the server and the storage system to which the technical aspects of the present disclosure relate. The discussion of a single server and storage system is at least for convenience of description and is not meant to imply limitations on the number, type, or location of end devices and servers. It should be noted that the underlying concepts of the example embodiments of the present disclosure may not be altered if additional modules are added or removed from the illustrated environments. In addition, although fig. 1 shows a bidirectional arrow from the database 50 to the server 20 for convenience of explanation, those skilled in the art will understand that the above-mentioned data transmission and reception also need to be implemented through the network 10.
It should be noted that the storage system in the embodiment of the present disclosure may be, for example, a cache system, or may also be a hard disk storage, a memory storage, and the like.
In addition, the monitoring device 30 provided by the present disclosure acquires the monitoring screen, transmits the monitoring screen to the server 20 through the network 10, and the server 20 calls the stored data in the database 50 to perform statistical calculation.
The video stream processing method provided by the present disclosure is not only applicable to the monitoring system shown in fig. 1, but also applicable to any image capturing device capable of image capturing, for example, an image capturing device of an intelligent terminal.
For a processing node, the processing node may receive and process multiple video streams. The processing method is the same for each video stream, and therefore, the video stream processing method provided by the embodiment of the present application is described in the following with respect to one video stream. As shown in fig. 2, a schematic flow chart of a video stream processing method provided in the embodiment of the present disclosure includes the following steps:
in step 201, a target video stream is received;
in step 202, analyzing the number of target objects contained in the target video stream;
in one embodiment, the target object may be at least one or a combination of a pedestrian, a vehicle, a dangerous area, and the like in the monitored scene. Of course, the target object may be set according to actual requirements in specific implementation, which is not limited in this application.
When counting the number of target objects, the total number of target objects detected per frame of image in a period of time may be counted or the number of target objects detected per frame of image may be averaged over a period of time.
Based on the above statistical manner of analyzing the number of target objects by using the average value, the embodiment of analyzing the number of target objects in the embodiment of the present application may be:
carrying out target object detection on the image to obtain the number of the target objects in the image;
and accumulating the number of the target objects in the image to the total number of the target objects detected from the video stream in the specified time length, and calculating the number of the target objects averagely contained in each frame of image in the specified time length as the number of the target objects contained in the target video stream.
In this embodiment, the number of target objects in each frame of image is simply and statistically averaged, so that the density of the target object to be detected can be simply and directly reflected, which can be understood as the density condition of the target object in the time domain, and thus the required resolution of one frame of image and whether the number of frames required to be extracted needs to be increased or decreased can be reflected according to the number of the target objects.
In step 203, determining processing parameters of the target video stream according to the number of the target objects, wherein the processing parameters comprise a sampling rate of the target video stream and/or a resolution of a picture;
in one embodiment, in order to dynamically and reasonably adjust the processing parameters of the target video stream according to the number of target objects, in the embodiment of the present disclosure, the number of target objects may be set to be positively correlated with both the sampling rate and the resolution in the processing parameters. For example, the target object is a pedestrian in a monitored scene, the total number of people detected in each frame of image in a period of time or the number of people detected in each frame of image in an average period of time is counted, when the number of pedestrians increases, the sampling rate and the resolution also increase, and when the number of pedestrians decreases, the sampling rate and the resolution also decrease. The sampling rate and the resolution ratio are self-adaptive according to the code stream, and the problem that when the number of target objects is large, the accuracy is low due to the fact that the sampling rate is large or the picture resolution ratio is small is avoided; when the number of the target objects is small, the sampling rate is small, the picture resolution is large, and system resources are wasted.
In some embodiments, determining the processing parameters of the target video stream according to the number of the target objects based on the positive correlation relationship can be implemented in two ways, including:
mode 1: linear functional relation, if the number of the target objects changes, determining the change proportion of the number of the target objects;
if the number of the target objects is increased, increasing the processing parameter value by the change proportion;
if the number of the target objects is reduced, reducing the processing parameter value by the change proportion.
For example, as shown in fig. 3, when the number of target objects is N, the specified threshold u0 is used, and the processing parameters use the specified sampling rate c0 and resolution s 0;
when N is increased to N1, determining the increasing proportion of N as (N1-N)/N, and increasing the sampling rate c0 and the resolution s0 of the processing parameters by the (N1-N)/N proportion;
when N is reduced to N2, the reduction ratio of N is determined to be (N-N2)/N, and the processing parameter sampling rate c0 and the resolution s0 are reduced by (N-N2)/N.
Mode 2: based on the way of interval division, in one embodiment, the interval range corresponding to the number of the target objects is determined;
and acquiring the processing parameters corresponding to the interval range.
The range of treatment parameters is shown in table 1 below:
TABLE 1
Figure BDA0002625028230000081
For example, as shown in fig. 4, the number of target objects is N, N is compared with a specified threshold u0, when N is smaller than a specified threshold u0, it is determined that N is within u0, and the processing parameters adopt a sampling rate c0 and a resolution s0 within u 0; when the number of the target objects is increased from N to N1, comparing N1 with given thresholds u1, u2 and u3, determining a range of the number of the target objects N1, and if N1 is in the u1 range, adopting a sampling rate c1 and a resolution s1 in the u1 range as processing parameters; if N1 is in the u2 range, the processing parameters adopt a sampling rate c2 and a resolution s2 in the u2 range; if N1 is within the u3 range, the processing parameters use a sampling rate c3 and a resolution s3 within the u3 range. In step 204, the target video stream is processed based on the processing parameters.
In order to further understand the technical solution provided in the present application, the overall flow of the solution is described below. In one embodiment, as shown in fig. 5, a schematic diagram of a video stream processing method provided for an embodiment of the present disclosure:
different functions can be realized by corresponding functional modules, for example, in the present application, the functions of each module can be included as follows:
an access module: receiving a code stream input by equipment;
a code stream decoding module: decoding the input code stream;
a code stream analysis module: counting the number of target objects;
a sampling module: selecting a proper sampling rate according to the number of the target objects;
a resolution module: selecting proper resolution according to the number of the target objects;
an algorithm module: and performing intelligent analysis on the results after sampling and distinguishing, such as detection and identification of target objects, alarm processing of dangerous events and the like.
As shown in fig. 6, which is a schematic structural diagram of the apparatus, the apparatus includes:
an access module: analyzing the number of target objects contained in the target video stream;
a target detection module: analyzing the number of target objects contained in the target video stream;
a code stream analysis module: determining processing parameters of the target video stream according to the number of the target objects, wherein the processing parameters comprise the sampling rate of the target video stream and/or the resolution of the picture;
a parameter processing module: the target video stream is processed based on the processing parameters.
Having described a video stream processing method and apparatus according to an exemplary embodiment of the present disclosure, an electronic device according to another exemplary embodiment of the present disclosure is described next.
As will be appreciated by one skilled in the art, aspects of the present disclosure may be embodied as a system, method or program product. Accordingly, various aspects of the present disclosure may be embodied in the form of: an entirely hardware embodiment, an entirely software embodiment (including firmware, microcode, etc.) or an embodiment combining hardware and software aspects that may all generally be referred to herein as a "circuit," module "or" system.
In some possible implementations, an electronic device in accordance with the present disclosure may include at least one processor, and at least one memory. Wherein the memory stores program code which, when executed by the processor, causes the processor to perform the steps of the information processing method of the intelligent terminal according to various exemplary embodiments of the present disclosure described above in the present specification. For example, the processor may perform the steps shown in FIG. 5.
The electronic device 130 according to this embodiment of the present disclosure is described below with reference to fig. 7. The electronic device 130 shown in fig. 7 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
As shown in fig. 7, the electronic device 130 is represented in the form of a general electronic device. The components of the electronic device 130 may include, but are not limited to: the at least one processor 131, the at least one memory 132, and a bus 133 that connects the various system components (including the memory 132 and the processor 131).
Bus 133 represents one or more of any of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a processor, or a local bus using any of a variety of bus architectures.
The memory 132 may include readable media in the form of volatile memory, such as Random Access Memory (RAM)1321 and/or cache memory 1322, and may further include Read Only Memory (ROM) 1323.
Memory 132 may also include a program/utility 1325 having a set (at least one) of program modules 1324, such program modules 1324 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment.
The electronic device 130 may also communicate with one or more external devices 134 (e.g., keyboard, pointing device, etc.), with one or more devices that enable a user to interact with the electronic device 130, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 130 to communicate with one or more other electronic devices. Such communication may occur via input/output (I/O) interfaces 135. Also, the electronic device 130 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network, such as the internet) via the network adapter 136. As shown, network adapter 136 communicates with other modules for electronic device 130 over bus 133. It should be understood that although not shown in the figures, other hardware and/or software modules may be used in conjunction with electronic device 130, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
In some possible embodiments, various aspects of a video stream processing method provided by the present disclosure may also be implemented in the form of a program product including program code for causing a computer device to perform the steps in a video stream processing method according to various exemplary embodiments of the present disclosure described above in this specification when the program product is run on the computer device, for example, an intelligent terminal device may perform the steps as shown in fig. 1.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, 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.
A program product for video stream processing of embodiments of the present disclosure may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on an electronic device. However, the program product of the present disclosure is not limited thereto, and in this document, a readable storage medium may 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.
A readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a 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.
Program code embodied on a readable medium may 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.
Program code for carrying out operations for the present disclosure may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the consumer electronic device, partly on the consumer electronic device, as a stand-alone software package, partly on the consumer electronic device and partly on a remote electronic device, or entirely on the remote electronic device or server. In the case of remote electronic devices, the remote electronic devices may be connected to the consumer electronic device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external electronic device (e.g., through the internet using an internet service provider).
It should be noted that although several units or sub-units of the apparatus are mentioned in the above detailed description, such division is merely exemplary and not mandatory. Indeed, the features and functions of two or more units described above may be embodied in one unit, in accordance with embodiments of the present disclosure. Conversely, the features and functions of one unit described above may be further divided into embodiments by a plurality of units.
Further, while the operations of the disclosed methods are depicted in the drawings in a particular order, this does not require or imply that these operations must be performed in this particular order, or that all of the illustrated operations must be performed, to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step execution, and/or one step broken down into multiple step executions.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present application without departing from the spirit and scope of the application. Thus, if such modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is intended to include such modifications and variations as well.

Claims (12)

1. A method for processing a video stream, the method comprising:
receiving a target video stream;
analyzing the number of target objects contained in the target video stream;
determining processing parameters of the target video stream according to the number of the target objects, wherein the processing parameters comprise the sampling rate of the target video stream and/or the resolution of pictures;
and processing the target video stream based on the processing parameters.
2. The method of claim 1,
the number of target objects is positively correlated with both sampling rate and resolution in the processing parameters.
3. The method of claim 2, wherein determining the processing parameters of the target video stream according to the number of the target objects comprises:
if the number of the target objects is changed, determining the change proportion of the number of the target objects;
if the number of the target objects is increased, increasing the processing parameter value by the change proportion;
if the number of the target objects is reduced, reducing the processing parameter value by the change proportion.
4. The method of claim 2, wherein determining the processing parameters of the target video stream according to the number of the target objects comprises:
determining an interval range corresponding to the number of the target objects;
and acquiring the processing parameters corresponding to the interval range.
5. The method of claim 1, wherein the processing the target video stream based on the processing parameter comprises:
acquiring images from the video stream based on the processing parameters;
performing target object detection on the image to obtain the number of the target objects in the image;
the analyzing the number of target objects contained in the target video stream includes:
and accumulating the number of the target objects in the images to the total number of the target objects detected from the video stream in a specified time length, and calculating the number of the target objects averagely contained in each frame of image in the specified time length as the number of the target objects contained in the target video stream.
6. A video stream processing apparatus, comprising:
an access module for receiving a target video stream;
the target detection module is used for analyzing the number of target objects contained in the target video stream;
the code stream analysis module is used for determining processing parameters of the target video stream according to the number of the target objects, wherein the processing parameters comprise the sampling rate of the target video stream and/or the resolution of pictures;
and the parameter processing module is used for processing the target video stream based on the processing parameters.
7. The apparatus of claim 6, wherein:
a parameter determination unit for determining a sampling rate and a resolution among the processing parameters according to the number of the target objects;
the number of target objects is positively correlated with both sampling rate and resolution in the processing parameters.
8. The apparatus of claim 7, wherein the codestream analysis module is configured to:
if the number of the target objects is changed, determining the change proportion of the number of the target objects;
if the number of the target objects is increased, increasing the processing parameter value by the change proportion;
if the number of the target objects is reduced, reducing the processing parameter value by the change proportion.
9. The apparatus of claim 7, wherein the codestream analysis module is configured to:
determining an interval range corresponding to the number of the target objects;
and acquiring the processing parameters corresponding to the interval range.
10. The apparatus of claim 6, wherein the target detection module is configured to:
acquiring images from the video stream based on the processing parameters;
performing target object detection on the image to obtain the number of the target objects in the image;
the analyzing the number of target objects contained in the target video stream includes:
and accumulating the number of the target objects in the images to the total number of the target objects detected from the video stream in a specified time length, and calculating the number of the target objects averagely contained in each frame of image in the specified time length as the number of the target objects contained in the target video stream.
11. An electronic device, comprising:
a processor;
a memory configured to store the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the video stream processing method of any of claims 1-5.
12. A video stream storage medium storing a computer program, characterized in that the computer program is configured to perform the video stream processing method according to any one of claims 1 to 5.
CN202010794486.6A 2020-08-10 2020-08-10 Video stream processing method and device, electronic equipment and storage medium Pending CN112040090A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010794486.6A CN112040090A (en) 2020-08-10 2020-08-10 Video stream processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010794486.6A CN112040090A (en) 2020-08-10 2020-08-10 Video stream processing method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112040090A true CN112040090A (en) 2020-12-04

Family

ID=73576783

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010794486.6A Pending CN112040090A (en) 2020-08-10 2020-08-10 Video stream processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112040090A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113221706A (en) * 2021-04-30 2021-08-06 西安聚全网络科技有限公司 Multi-process-based multi-channel video stream AI analysis method and system
WO2023024791A1 (en) * 2021-08-27 2023-03-02 上海商汤智能科技有限公司 Frame rate adjustment method and apparatus, electronic device, storage medium, and program

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TW201201571A (en) * 2010-06-18 2012-01-01 Altek Corp Resolution adjustment method
CN102761739A (en) * 2011-04-26 2012-10-31 联发科技股份有限公司 Apparatus for dynamically adjusting video decoding complexity, and associated method
US8767825B1 (en) * 2009-11-30 2014-07-01 Google Inc. Content-based adaptive video transcoding framework
US20150334298A1 (en) * 2012-12-24 2015-11-19 Yulong Computer Telecommunication Scientific (Shenzhen) Co., Ltd. Dynamic adjustment device for recording resolution and dynamic adjustment method and terminal
WO2020080139A1 (en) * 2018-10-19 2020-04-23 ソニー株式会社 Sensor device and parameter setting method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8767825B1 (en) * 2009-11-30 2014-07-01 Google Inc. Content-based adaptive video transcoding framework
TW201201571A (en) * 2010-06-18 2012-01-01 Altek Corp Resolution adjustment method
CN102761739A (en) * 2011-04-26 2012-10-31 联发科技股份有限公司 Apparatus for dynamically adjusting video decoding complexity, and associated method
US20150334298A1 (en) * 2012-12-24 2015-11-19 Yulong Computer Telecommunication Scientific (Shenzhen) Co., Ltd. Dynamic adjustment device for recording resolution and dynamic adjustment method and terminal
WO2020080139A1 (en) * 2018-10-19 2020-04-23 ソニー株式会社 Sensor device and parameter setting method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113221706A (en) * 2021-04-30 2021-08-06 西安聚全网络科技有限公司 Multi-process-based multi-channel video stream AI analysis method and system
CN113221706B (en) * 2021-04-30 2024-03-22 西安聚全网络科技有限公司 AI analysis method and system for multi-process-based multi-path video stream
WO2023024791A1 (en) * 2021-08-27 2023-03-02 上海商汤智能科技有限公司 Frame rate adjustment method and apparatus, electronic device, storage medium, and program

Similar Documents

Publication Publication Date Title
Ali et al. RES: Real-time video stream analytics using edge enhanced clouds
CN108062499B (en) Face recognition method, system and platform
CN113542795B (en) Video processing method and device, electronic equipment and computer readable storage medium
WO2005091639A1 (en) Pipeline architecture for analyzing multiple video streams
CN113220715B (en) Data processing method, system, computer and readable storage medium
CN112040090A (en) Video stream processing method and device, electronic equipment and storage medium
CN102724385A (en) Intelligent video analysis method and device
CN110740293A (en) data transmission method, system, device and computer storage medium
CN110336888B (en) Server distribution method, device, system and medium
CN113079062B (en) Resource adjusting method and device, computer equipment and storage medium
KR20160107417A (en) Method and apparatus for detecting harmful video
CN109831673B (en) Live broadcast room data processing method, device, equipment and storage medium
CN111160283B (en) Data access method, device, equipment and medium
KR101553923B1 (en) Apparatus and method for analyzing system usage
CN112637538A (en) Smart tag method, system, medium, and terminal for optimizing video analysis
Tsai et al. Distributed multimedia content processing in ONVIF surveillance system
CN116132623A (en) Intelligent analysis method, system and equipment based on video monitoring
CN115297332B (en) Cloud streaming media hard decoding method and device
CN112533004B (en) Program information publishing method, system, computer equipment and storage medium
CN115242735B (en) Real-time voice stream slice analysis method, system and computer equipment
US11087103B2 (en) Adaptive spatial granularity based on system performance
CN114553775B (en) Flow control method and device
CN107979778B (en) Video analysis method, device and system
CN110110170B (en) Data processing method, device, medium and electronic equipment
CN114302100A (en) Video analysis method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20201204

RJ01 Rejection of invention patent application after publication