Road end camera driving delay time calculation method and device, electronic equipment and storage medium
By monitoring the exposure time, frame rate, and decoding status of roadside cameras in real time, and dynamically compensating for the driving delay time of the roadside cameras, the problem of inaccurate camera delay adjustment in existing technologies is solved, thereby improving the accuracy and adaptability of the roadside perception system.
Patent Information
- Application Number
- CN202211612537.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-07
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2042-12-07
AI Technical Summary
In the existing technology, the driving delay time adjustment method of the roadside camera fails to take into account the changes in camera exposure time, frame rate and device decoding time, resulting in a large difference between the video stream output and real-world time, which affects the accuracy of perception algorithm processing.
The camera parameters of the roadside camera under different shooting environments are monitored in real time, including exposure time, frame rate and decoding status. The second drive delay time of the camera is calculated by a dynamic compensation algorithm, and the first drive delay time is optimized and compensated to obtain the final drive delay time.
By dynamically compensating for camera delay, the driving delay of roadside cameras is reduced, improving the perception accuracy of the roadside perception system and adapting to different environmental changes such as rain, night, snow, and fog.
Smart Images

Figure CN116016903B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image equipment technology, and in particular to a method, apparatus, electronic device, and storage medium for calculating the driving delay time of a roadside camera. Background Technology
[0002] The roadside system uses roadside cameras to identify, locate, and track detected targets. The acquisition of video stream information by the roadside cameras begins when real-world events occur and ends after the video frames are decoded. The camera drive delay primarily consists of the time it takes for the ISP image processor to process image encoding and for the sensing device to retrieve the video stream object from the network.
[0003] Typically, camera drive latency is caused by pixels not constantly following the hardware clock's cycle, requiring time to wait for the ISP image processor's hardware processing. This latency is caused by the buffer.
[0004] In related technologies, the method for adjusting the drive delay time of roadside cameras is based on the time difference (a fixed value) between the drive decoding time and the current device time, or by measuring a fixed time using hardware as the drive delay time. However, these methods do not consider camera exposure time, camera frame rate, or errors in device decoding time; they only use a fixed value as the delay time, resulting in a significant difference between the video stream output and the actual time in the real world. Furthermore, if the video stream from the roadside camera is transmitted to the sensing end, it will cause significant errors in the sensing algorithm processing. Summary of the Invention
[0005] This application provides a method, apparatus, electronic device, and storage medium for calculating the driving delay time of roadside cameras, so as to monitor the driving delay time of roadside cameras in real time and optimize the driving delay time.
[0006] The embodiments of this application adopt the following technical solutions:
[0007] In a first aspect, embodiments of this application provide a method for calculating the driving delay time of a roadside camera, wherein the method includes:
[0008] Real-time monitoring of camera parameters of roadside cameras under the current shooting environment;
[0009] The second drive delay time of the roadside camera is calculated in real time based on the camera parameters.
[0010] The first drive delay time of the roadside camera is optimized and compensated based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera.
[0011] In some embodiments, the camera parameters include the exposure time of the camera shooting, and the camera parameters of the real-time monitoring roadside camera in the current shooting environment include:
[0012] Real-time monitoring of the camera exposure time when the roadside camera is shooting under different shooting environments;
[0013] Determine whether there is a difference between the camera exposure time of the roadside camera when shooting in different shooting environments and the preset camera exposure time;
[0014] If a difference exists and exceeds a preset difference threshold, it is considered that the camera's exposure time has changed and the new camera exposure time is used.
[0015] If no difference exists, continue using the preset camera exposure time.
[0016] In some embodiments, the camera parameters further include camera frame rate and decoding accuracy. The camera parameters of the real-time monitoring roadside camera under the current shooting environment include:
[0017] Real-time monitoring of the camera frame rate when the roadside camera is shooting under different shooting environments;
[0018] It monitors and determines in real time whether the decoding of roadside cameras is correct or incorrect when shooting in different shooting environments.
[0019] In some embodiments, optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera includes:
[0020] Based on the exposure time of the camera, the camera frame rate, and the correctness of the decoding, the second driving delay time of the roadside camera is calculated in real time as a driving delay compensation for the roadside camera.
[0021] In some embodiments, the step of optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera further includes:
[0022] The first drive delay time of the roadside camera is optimized based on the second drive delay time of the roadside camera.
[0023] Based on the final drive delay time of the roadside camera, the video stream captured by the roadside camera is sent to the roadside perception system in real time.
[0024] In some embodiments, the step of calculating the second drive delay time of the roadside camera in real time based on the camera parameters includes:
[0025] The second drive delay time t1 = a*t2 + b*t3 + c*t4,
[0026] Wherein, t2 is the fixed exposure time of the camera, t3 is the camera frame rate, t4 is the camera decoding time, and a, b, and c are preset weights.
[0027] Secondly, embodiments of this application also provide a roadside camera driving delay time calculation device, wherein the device includes:
[0028] The monitoring module is used to monitor the camera parameters of the roadside camera in real time under the current shooting environment;
[0029] The delay calculation module is used to calculate the second drive delay time of the roadside camera in real time based on the camera parameters;
[0030] The delay optimization module is used to optimize and compensate the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera, so as to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera.
[0031] Thirdly, embodiments of this application also provide an electronic device, including: a processor; and a memory arranged to store computer-executable instructions, which, when executed, cause the processor to perform the above-described method.
[0032] Fourthly, embodiments of this application also provide a computer-readable storage medium that stores one or more programs, which, when executed by an electronic device including multiple applications, cause the electronic device to perform the above-described method.
[0033] The at least one technical solution adopted in this application embodiment can achieve the following beneficial effects: by real-time monitoring of the camera parameters of the roadside camera in the current shooting environment, and then calculating the second drive delay time of the roadside camera in real time based on the camera parameters. The first drive delay time of the roadside camera is optimized and compensated based on the second drive delay time to obtain the final drive delay time of the roadside camera. For the roadside camera, this reduces its own drive delay time, achieving synchronization between the target object in the real scene and the monitored scene. Attached Figure Description
[0034] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0035] Figure 1 This is a flowchart illustrating the method for calculating the driving delay time of the roadside camera in the embodiments of this application;
[0036] Figure 2 This is a schematic diagram of the structure of the roadside camera drive delay time calculation device in the embodiments of this application;
[0037] Figure 3 This is a schematic diagram of the algorithm architecture corresponding to the method for calculating the driving delay time of the roadside camera in the embodiments of this application;
[0038] Figure 4 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Detailed Implementation
[0039] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0040] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.
[0041] This application provides a method for calculating the driving delay time of a roadside camera, such as... Figure 1 The diagram shows a flowchart of a method for calculating the driving delay time of a roadside camera in an embodiment of this application. The method includes at least the following steps S110 to S130:
[0042] Step S110: Monitor the camera parameters of the roadside camera in real time under the current shooting environment.
[0043] The roadside camera is used in the roadside perception system, and the driving delay time of the roadside camera is mainly the delay time of the camera driving device.
[0044] The driving delay time for roadside cameras typically refers to the time interval from the start of decoding by the camera's ISP image processor to the time when the image is presented to the human eye. If the camera manufacturer has already specified the driving delay time, it can be used directly. If the camera manufacturer has not specified the driving delay time, a fixed time can be defined as the driving delay time during configuration.
[0045] In practice, by pre-writing computer software programs into the roadside cameras, the camera parameters of the roadside cameras under the current shooting environment can be monitored in real time.
[0046] The default (standard) camera parameters for roadside cameras under different shooting environments are pre-configured. For example, by monitoring the scene being captured in real time by the camera, camera parameters for different weather conditions are configured accordingly. Considering that different weather conditions result in varying temperatures and humidity, which will affect the camera parameters of the roadside cameras, it is necessary to compare the default (standard) camera parameters of the roadside cameras under different shooting environments with the real-time monitored camera parameters.
[0047] In some embodiments, the roadside cameras in the roadside perception system can be configured differently, so that roadside cameras located at different locations (intersections or roads) have corresponding default (standard) camera parameters, thereby enabling centralized configuration and management of the roadside cameras in the roadside perception system and improving perception accuracy.
[0048] To reduce latency and improve real-time performance, it is necessary to monitor the camera parameters of roadside cameras in real time under the current shooting environment. If periodic monitoring is used instead of real-time monitoring, the driving delay of the roadside cameras will still exist, thus affecting the overall perception effect of the roadside sensing end. Therefore, real-time monitoring is more in line with the perception requirements of roadside cameras.
[0049] Step S120: Calculate the second drive delay time of the roadside camera in real time based on the camera parameters.
[0050] The second drive delay time of the roadside camera is calculated in real time based on the camera parameters. It can be understood that a dynamic compensation algorithm can be implemented by pre-writing a computer software program into the roadside camera. The second drive delay time of the roadside camera can be calculated through the dynamic compensation algorithm.
[0051] In some embodiments, the second drive delay time of the roadside camera is calculated in real time according to preset weights in the camera parameters, and these preset weights are related to the specific type of the camera parameters.
[0052] In some embodiments, the camera parameters include exposure time, camera frame rate, decoding accuracy, etc., which are not specifically limited in this application and can be any one or more of them.
[0053] For roadside cameras, exposure time is directly related to the brightness of the background and the target being detected in the roadside scene. Camera frame rate refers to the number of consecutive images captured by the roadside camera per second, which is related to the selection of the roadside camera and the monitoring requirements of the roadside perception system. The accuracy of the roadside camera's decoding directly affects the processing of the ISP image processor.
[0054] Step S130: Optimize and compensate the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera.
[0055] The second drive delay time of the roadside camera is calculated to compensate for the camera drive delay. Since the first drive delay time is a fixed drive delay of the roadside camera, the first drive delay time of the roadside camera is optimized and compensated using the second drive delay time to obtain the final drive delay time of the roadside camera. The optimization and compensation process is to replace the first drive delay time with the second drive delay time.
[0056] Of course, if the drive delay time is small or there is no need to calculate the second drive delay time, the first drive delay time will continue to be used as the drive delay time for the roadside camera.
[0057] Through the aforementioned dynamic compensation mechanism, the camera drive latency is optimized in real time, overcoming the shortcomings of using a fixed time to compensate for camera drive latency. This ensures that the camera video stream time and the time of real-world events are as consistent as possible with the current external environment and system operating mechanism. Consequently, the roadside camera drive latency is significantly reduced, ultimately leading to more accurate perception judgments made by the roadside perception system.
[0058] Unlike related technologies where the camera cannot compensate for camera drive delays based on the current external scene, the method in this application uses dynamic compensation to better suit the changing external scene of the roadside camera. Preferably, it can be applied to different scenarios such as rain, night, snow, and fog.
[0059] For example, the dynamic compensation mechanism can be adjusted periodically according to the different lighting changes of the roadside camera at night or during the day. In addition, the dynamic compensation mechanism can also be adjusted non-periodically, providing different compensation for the roadside camera drive delay time according to the different scenarios in which the roadside camera is located.
[0060] For example, the dynamic compensation mechanism can provide different compensation for the driving delay time of the roadside camera based on the traffic flow and pedestrian flow in the current scene of the roadside camera, and based on the different road sections or intersections where the roadside camera is located.
[0061] In one embodiment of this application, the camera parameters include the exposure time of the camera shooting. The real-time monitoring of the camera parameters of the roadside camera in the current shooting environment includes: real-time monitoring of the camera shooting exposure time of the roadside camera when shooting in different shooting environments; determining whether there is a difference between the camera shooting exposure time of the roadside camera when shooting in different shooting environments and the preset camera shooting exposure time; if there is a difference and it exceeds the preset difference threshold, it is considered that the camera shooting exposure time has changed and the new camera shooting exposure time after the change is used; if there is no difference, the preset camera shooting exposure time is continued to be used.
[0062] Real-time monitoring of camera exposure time is necessary to reduce roadside camera drive latency.
[0063] The computer software program in the roadside camera determines whether there is a difference between the camera's exposure time under different shooting environments and a preset camera exposure time, and whether this difference exceeds a preset difference threshold. This difference refers to the absolute difference. The preset difference threshold (range) is configured according to the actual scenario and is not specifically limited in this application.
[0064] Furthermore, if a difference exists, it is assumed that the camera's exposure time has changed, and the new, modified camera exposure time is used. If they are different and a difference exists, it is assumed that the camera's exposure time has changed, and the new camera exposure time is used and recorded. Similarly, if no difference exists, the preset camera exposure time continues to be used. In other words, the camera exposure time in the camera parameters has no impact on the camera drive delay, or has a minor impact, and therefore does not need to be updated.
[0065] In one embodiment of this application, the camera parameters further include camera frame rate and decoding accuracy. The real-time monitoring of the camera parameters of the roadside camera in the current shooting environment includes: real-time monitoring of the camera frame rate when the roadside camera shoots in different shooting environments; and real-time monitoring and determining whether the decoding of the roadside camera is correct or incorrect when shooting in different shooting environments.
[0066] The system monitors the camera frame rate and / or decoding accuracy in real time, and monitors the camera frame rate of the roadside camera in different shooting environments, such as rainy days, snowy days, sunny days, and cloudy days.
[0067] Afterwards, it is also necessary to monitor and determine in real time whether the decoding of the roadside camera is correct or incorrect when shooting in different shooting environments. Those skilled in the art can understand that mature methods in related technologies can be used to determine whether the decoding is correct or incorrect. If it is correct, it can continue to be used; if it is incorrect, it needs to be updated.
[0068] In one embodiment of this application, the step of optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera includes: calculating the second drive delay time of the roadside camera in real time based on the exposure time of the camera, the camera frame rate, and the decoding accuracy, as a drive delay compensation for the roadside camera.
[0069] The process of calculating the second drive delay time requires calculation based on the camera's exposure time, camera frame rate, and decoding accuracy, using a preset dynamic compensation algorithm. The resulting second drive delay time can then be used as compensation for the roadside camera's drive delay. In other words, the second drive delay time is simply the roadside camera's drive delay time.
[0070] In one embodiment of this application, the step of optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera further includes: optimizing the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera; and sending the video stream captured by the roadside camera to the roadside perception system in real time according to the obtained final drive delay time of the roadside camera.
[0071] To improve the perception accuracy of the roadside perception system, the video stream captured by the roadside camera can be sent to the roadside perception system in real time according to the final drive delay time of the roadside camera.
[0072] The second drive delay time is used when the camera parameters of the roadside camera are detected to be different from the standard camera parameters. If they are the same, the first drive delay time continues to be used.
[0073] In one embodiment of this application, the step of calculating the second driving delay time of the roadside camera in real time according to the camera parameters includes: the second driving delay time t1 = a*t2 + b*t3 + c*t4, where t2 is the fixed exposure time of the camera, t3 is the camera frame rate, t4 is the camera decoding time, and a, b, and c are preset weights.
[0074] In practice, t2 is the camera's fixed exposure time, t3 is the camera's frame period (t3 = 1 / n, where n is the frame rate), and t4 is the camera's decoding time. If the decoding is correct, it is t4; if there is an error, it is t4 - lsat, which means using the decoding time of the previous frame.
[0075] Preferably, t1 = 80% * t2 + 10 * t3 + 10 * t4, and the result is taken as the final drive delay time of the roadside camera mentioned in t1. Using the above method, the algorithm can calculate the camera drive delay time in real time and use it for camera drive delay compensation, ensuring that the delay is minimized.
[0076] In one embodiment of this application, the shooting environment includes at least one of the following weather conditions: rain, night, snow, and fog.
[0077] It can optimize the driving delay of roadside cameras in different shooting environments such as rain, night, snow, and fog, and provides camera driving delay compensation.
[0078] This application embodiment also provides a roadside camera drive delay time calculation device 200, such as Figure 2 As shown, a schematic diagram of the roadside camera drive delay time calculation device in this embodiment of the application is provided. The roadside camera drive delay time calculation device 200 includes at least: a monitoring module 210, a delay calculation module 220, and a delay optimization module 230, wherein:
[0079] In one embodiment of this application, the monitoring module 210 is specifically used to: monitor the camera parameters of the roadside camera in real time under the current shooting environment.
[0080] The roadside camera is used in the roadside perception system of the roadside system, and the driving delay time of the roadside camera is mainly the delay time of the camera driving device.
[0081] The driving delay time for roadside cameras typically refers to the time interval from the start of decoding by the camera's ISP image processor to the time when the image is presented to the human eye. If the camera manufacturer has already specified the driving delay time, it can be used directly. If the camera manufacturer has not specified the driving delay time, a fixed time can be defined as the driving delay time during configuration.
[0082] In practice, by pre-writing computer software programs into the roadside cameras, the camera parameters of the roadside cameras under the current shooting environment can be monitored in real time.
[0083] The default (standard) camera parameters for roadside cameras under different shooting environments are pre-configured. For example, by monitoring the scene being captured in real time by the camera, camera parameters for different weather conditions are configured accordingly. Considering that different weather conditions result in varying temperatures and humidity, which will affect the camera parameters of the roadside cameras, it is necessary to compare the default (standard) camera parameters of the roadside cameras under different shooting environments with the real-time monitored camera parameters.
[0084] In some embodiments, the roadside cameras in the roadside perception system can be configured differently so that roadside cameras located at different locations have corresponding default (standard) camera parameters, thereby enabling centralized configuration and management of the roadside cameras in the roadside perception system and improving perception accuracy.
[0085] To reduce latency and improve real-time performance, it is necessary to monitor the camera parameters of roadside cameras in real time under the current shooting environment. If periodic monitoring is used instead of real-time monitoring, the driving delay of the roadside cameras will still exist, thus affecting the overall perception effect of the roadside sensing end. Therefore, real-time monitoring is more in line with the perception requirements of roadside cameras.
[0086] In one embodiment of this application, the delay calculation module 220 is specifically used to: calculate the second drive delay time of the roadside camera in real time based on the camera parameters.
[0087] The second drive delay time of the roadside camera is calculated in real time based on the camera parameters. It can be understood that a dynamic compensation algorithm can be implemented by pre-writing a computer software program into the roadside camera. The second drive delay time of the roadside camera can be calculated through the dynamic compensation algorithm.
[0088] In some embodiments, the second drive delay time of the roadside camera is calculated in real time according to preset weights in the camera parameters, and these preset weights are related to the specific type of the camera parameters.
[0089] In some embodiments, the camera parameters include exposure time, camera frame rate, decoding accuracy, etc., which are not specifically limited in this application and can be any one or more of them.
[0090] For roadside cameras, exposure time is directly related to the brightness of the background and the target being detected in the roadside scene. Camera frame rate refers to the number of consecutive images captured by the roadside camera per second, which is related to the selection of the roadside camera and the monitoring requirements of the roadside perception system. The accuracy of the roadside camera's decoding directly affects the processing of the ISP image processor.
[0091] In one embodiment of this application, the delay optimization module 230 is specifically used to: optimize and compensate the first drive delay time of the roadside camera according to the second drive delay time of the roadside camera, so as to obtain the final drive delay time of the roadside camera, wherein the first drive delay time is a fixed drive delay of the roadside camera.
[0092] The second drive delay time of the roadside camera is calculated to compensate for the camera drive delay. Since the first drive delay time is a fixed drive delay of the roadside camera, the first drive delay time of the roadside camera is optimized and compensated using the second drive delay time to obtain the final drive delay time of the roadside camera. The optimization and compensation process is to replace the first drive delay time with the second drive delay time.
[0093] Of course, if the drive delay time is small or there is no need to calculate the second drive delay time, the first drive delay time will continue to be used as the drive delay time for the roadside camera.
[0094] Through the aforementioned dynamic compensation mechanism, the camera drive latency is optimized in real time, compensating for the shortcomings of fixed-time compensation for camera drive latency. This ensures that the camera video stream time and the time of events in the real world are as consistent as possible with the current external environment and the current system operating mechanism. Consequently, the roadside camera drive latency is significantly reduced, ultimately leading to more accurate perception judgments made by the roadside perception system.
[0095] Unlike cameras in related technologies, which cannot compensate for camera drive delays based on the current external scene, the method in this application uses dynamic compensation to better match the changing external scene of the roadside camera. Preferably, it can be applied to different scenarios such as rain, night, snow, and fog.
[0096] For example, the dynamic compensation mechanism can be adjusted periodically according to the different lighting changes of the roadside camera at night or during the day. In addition, the dynamic compensation mechanism can also be adjusted non-periodically, providing different compensation for the roadside camera drive delay time according to the different scenarios in which the roadside camera is located.
[0097] For example, the dynamic compensation mechanism can provide different compensation for the driving delay time of the roadside camera based on the traffic flow and pedestrian flow in the current scene of the roadside camera, and based on the different road sections or intersections where the roadside camera is located.
[0098] It is understood that the above-mentioned roadside camera drive delay time calculation device can implement each step of the roadside camera drive delay time calculation method provided in the foregoing embodiments. The relevant explanations of the roadside camera drive delay time calculation method are applicable to the roadside camera drive delay time calculation device, and will not be repeated here.
[0099] Figure 3 This is a schematic diagram of the algorithm architecture corresponding to the method for calculating the roadside camera driving delay time in the embodiments of this application, specifically including:
[0100] The underlying camera driver device has a roadside camera driver delay time, which typically refers to the time period from the start of the camera's ISP decoding to the point where the image is visible to the human eye. If the camera manufacturer has already specified the driver delay time, it can be used directly. If the camera manufacturer has not specified the driver delay time, a fixed time can be defined as the driver delay time during configuration.
[0101] The intermediate layer software system monitoring algorithm monitors the camera parameters of the roadside camera in real time under the current shooting environment, calculates the second drive delay time of the roadside camera, and optimizes and compensates the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera.
[0102] The algorithm process includes: starting the dynamic compensation algorithm, calculating the camera drive delay time during implementation, and obtaining the camera delay compensation.
[0103] The upper-level roadside perception system receives the video stream captured by the roadside camera in real time, according to the final drive delay time of the roadside camera obtained above.
[0104] Figure 4 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Please refer to it. Figure 4 At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and memory. The memory may include main memory, such as high-speed random-access memory (RAM), or non-volatile memory, such as at least one disk drive. Of course, the electronic device may also include other hardware required for other business operations.
[0105] The processor, network interface, and memory can be interconnected via an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 4The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.
[0106] Memory is used to store programs. Specifically, programs may include program code, which includes computer operation instructions. Memory may include main memory and non-volatile memory, and provides instructions and data to the processor.
[0107] The processor reads the corresponding computer program from non-volatile memory into main memory and then executes it, forming a roadside camera driver delay time calculation device at the logical level. The processor executes the program stored in memory and specifically performs the following operations:
[0108] Real-time monitoring of camera parameters of roadside cameras under the current shooting environment;
[0109] The second drive delay time of the roadside camera is calculated in real time based on the camera parameters.
[0110] The first drive delay time of the roadside camera is optimized and compensated based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera.
[0111] The above is as stated in this application. Figure 1The method for calculating the delay time of a roadside camera driver disclosed in the illustrated embodiment can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The processor can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly embodied in the execution of a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software module can reside in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method.
[0112] The electronic device can also perform Figure 1 A method for calculating the driving delay time of the mid-end camera, and implementation of the method for calculating the driving delay time of the mid-end camera. Figure 1 The functions of the embodiments shown are not described again in this application.
[0113] This application also proposes a computer-readable storage medium that stores one or more programs, the programs including instructions that, when executed by an electronic device including multiple applications, enable the electronic device to perform... Figure 1 The method executed by the roadside camera drive delay time calculation device in the illustrated embodiment is specifically used to perform:
[0114] Real-time monitoring of camera parameters of roadside cameras under the current shooting environment;
[0115] The second drive delay time of the roadside camera is calculated in real time based on the camera parameters.
[0116] The first drive delay time of the roadside camera is optimized and compensated based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera.
[0117] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can 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, etc.) containing computer-usable program code.
[0118] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can 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, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0119] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0120] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0121] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0122] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0123] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0124] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0125] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can 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, etc.) containing computer-usable program code.
[0126] The above description is merely an embodiment of this application and is not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.
Claims
1. A method for calculating the driving delay time of a roadside camera, wherein, The method includes: Real-time monitoring of camera parameters of roadside cameras under the current shooting environment; The camera parameters include the exposure time of the camera shooting, and the camera parameters of the real-time monitored roadside camera under the current shooting environment include: Real-time monitoring of the camera exposure time when the roadside camera is shooting under different shooting environments; Determine whether there is a difference between the camera exposure time of the roadside camera when shooting in different shooting environments and the preset camera exposure time; If a difference exists and exceeds a preset difference threshold, it is considered that the camera's exposure time has changed and the new camera exposure time is used. If no difference exists, continue using the preset camera exposure time; The second drive delay time of the roadside camera is calculated in real time based on the camera parameters. The first drive delay time of the roadside camera is optimized and compensated based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera. The camera parameters also include camera frame rate and decoding accuracy. The camera parameters of the real-time monitored roadside camera under the current shooting environment include: Real-time monitoring of the camera frame rate when the roadside camera is shooting under different shooting environments; Real-time monitoring and judgment of whether the decoding of the roadside camera is correct or incorrect when shooting in different shooting environments; The second drive delay time of the roadside camera is calculated in real time based on the camera parameters. The first drive delay time of the roadside camera is optimized and compensated based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera. The step of optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera includes: Based on the exposure time of the camera, the camera frame rate, and the decoding accuracy, the second driving delay time of the roadside camera is calculated in real time as a driving delay compensation for the roadside camera. The step of calculating the second drive delay time of the roadside camera in real time based on the camera parameters includes: The second drive delay time t1 = a*t2 + b*t3 + c*t4, Wherein, t2 is the exposure time of the camera, t3 = 1 / n, n is the frame rate, t4 is the camera decoding time of the current frame (if the decoding is correct, it is t4; if it is incorrect, the decoding time of the previous frame is used), and a, b, and c are preset weights.
2. The method as described in claim 1, wherein, The step of optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera further includes: The first drive delay time of the roadside camera is optimized based on the second drive delay time of the roadside camera. Based on the final drive delay time of the roadside camera, the video stream captured by the roadside camera is sent to the roadside perception system in real time.
3. The method according to any one of claims 1 to 2, wherein, The shooting environment includes at least one of the following weather conditions: rain, night, snow, fog.
4. A device for calculating the driving delay time of a roadside camera, wherein, The device includes: The monitoring module is used to monitor the camera parameters of the roadside camera in real time under the current shooting environment; The camera parameters include the exposure time of the camera shooting, and the camera parameters of the real-time monitored roadside camera under the current shooting environment include: Real-time monitoring of the camera exposure time when the roadside camera is shooting under different shooting environments; Determine whether there is a difference between the camera exposure time of the roadside camera when shooting in different shooting environments and the preset camera exposure time; If a difference exists and exceeds a preset difference threshold, it is considered that the camera's exposure time has changed and the new camera exposure time is used. If no difference exists, continue using the preset camera exposure time; The delay calculation module is used to calculate the second drive delay time of the roadside camera in real time based on the camera parameters; The delay optimization module is used to optimize and compensate the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera, so as to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera. The camera parameters also include camera frame rate and decoding accuracy. The camera parameters of the real-time monitored roadside camera under the current shooting environment include: Real-time monitoring of the camera frame rate when the roadside camera is shooting under different shooting environments; Real-time monitoring and judgment of whether the decoding of the roadside camera is correct or incorrect when shooting in different shooting environments; The delay calculation module is used to calculate the second drive delay time of the roadside camera in real time based on the camera parameters; The delay optimization module is used to optimize and compensate the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera, so as to obtain the final drive delay time of the roadside camera. The first drive delay time is the fixed drive delay time of the roadside camera. The step of optimizing and compensating the first drive delay time of the roadside camera based on the second drive delay time of the roadside camera to obtain the final drive delay time of the roadside camera includes: Based on the exposure time of the camera, the camera frame rate, and the decoding accuracy, the second driving delay time of the roadside camera is calculated in real time as a driving delay compensation for the roadside camera. The step of calculating the second drive delay time of the roadside camera in real time based on the camera parameters includes: The second drive delay time t1 = a*t2 + b*t3 + c*t4, Wherein, t2 is the exposure time of the camera, t3 = 1 / n, n is the frame rate, t4 is the camera decoding time of the current frame (if the decoding is correct, it is t4; if it is incorrect, the decoding time of the previous frame is used), and a, b, and c are preset weights.
5. An electronic device, comprising: processor; as well as A memory configured to store computer-executable instructions, which, when executed, cause the processor to perform the method of any one of claims 1 to 3.
6. A computer-readable storage medium storing one or more programs, which, when executed by an electronic device including a plurality of applications, cause the electronic device to perform the method of any one of claims 1 to 3.
Citation Information
Patent Citations
Method for adjusting exposure delay of camera, camera, computer equipment and storage medium
CN111182229A
Shooting method and device for delayed photography
CN112532857A
