Method for measuring vehicle speed based on fuzzy image

文档序号:1389889 发布日期:2020-02-28 浏览:18次 中文

阅读说明:本技术 一种基于模糊图像测量车速的方法 (Method for measuring vehicle speed based on fuzzy image ) 是由 王飞 于 2019-11-21 设计创作,主要内容包括:本发明公开了一种基于模糊图像测量车速的方法,包括以下步骤:步骤1、实时拍摄单幅车辆场景图像;步骤2、根据车辆场景图像计算路面距离与像素距离之间的标定函数;步骤3、提取当前车辆场景图像中的车辆图像;步骤4、对车辆图像进行模糊度计算并输出模糊像素值;步骤5、根据标定函数、模糊像素值、拍摄曝光时间计算车辆行驶速度;本发明使用拍摄的单幅图像,通过深度学习模型评估模糊度来计算图像中的车速,可有效简化车辆测速设备安装及测量过程。(The invention discloses a method for measuring vehicle speed based on a blurred image, which comprises the following steps: step 1, shooting a single vehicle scene image in real time; step 2, calculating a calibration function between the road surface distance and the pixel distance according to the vehicle scene image; step 3, extracting a vehicle image in the current vehicle scene image; step 4, calculating the fuzziness of the vehicle image and outputting a fuzzy pixel value; step 5, calculating the vehicle running speed according to the calibration function, the fuzzy pixel value and the shooting exposure time; the method uses the shot single image to evaluate the ambiguity through the deep learning model to calculate the vehicle speed in the image, and can effectively simplify the installation and measurement process of the vehicle speed measuring equipment.)

1. A method for measuring vehicle speed based on blurred images is characterized by comprising the following steps:

step 1, shooting a single vehicle scene image in real time;

step 2, calculating a calibration function between the road surface distance and the pixel distance according to the vehicle scene image;

step 3, extracting a vehicle image in the current vehicle scene image;

step 4, calculating the fuzziness of the vehicle image and outputting a fuzzy pixel value;

and 5, calculating the vehicle running speed according to the calibration function, the fuzzy pixel value and the shooting exposure time.

2. The method for measuring the vehicle speed based on the blurred image as claimed in claim 1, wherein the vehicle running speed is calculated by adopting the following formula:

Figure FDA0002283145030000011

wherein: v is the vehicle speed;

h (x) is a calibration function;

z is the minimum pixel distance between the vehicle image and the first calibration line segment;

△ z are blurred pixel values;

△ t is the shot exposure time.

3. The method for measuring vehicle speed based on blurred image as claimed in claim 2, wherein the step 2 comprises the following sub-steps:

step 2.1, respectively selecting a first calibration line segment and a second calibration line segment which are perpendicular to the length direction of the road surface and parallel to each other in the vehicle scene image, and measuring the actual lengths of the first calibration line segment and the second calibration line segment as d respectively1And d2

Step 2.2, calculating pixels of the first calibration line segment and the second calibration line segment according to the vehicle scene imageEach length is Pd1And Pd2Calculating the pixel distance h between the first calibration line segment and the second calibration line segmentp

Step 2.3, calculating a calibration function h (x) according to the following calculation formula:

Figure FDA0002283145030000012

wherein:

Figure FDA0002283145030000013

4. the method for measuring the vehicle speed based on the blurred image as claimed in claim 3, wherein the distance between the first calibration line segment and the second calibration line segment is greater than or equal to the length of the vehicle.

5. The method for measuring the vehicle speed based on the blurred image as claimed in any one of claims 1 to 4, wherein a high-speed camera is used for shooting the vehicle image in the step 1, and a plurality of groups of fixed shutter exposure time are set.

6. The method of claim 5, wherein the fixed shutter exposure time is adjusted based on ambient light intensity.

7. The method for measuring vehicle speed based on blurred images as claimed in claim 1, wherein in step 3, a deep learning target detection method is adopted to extract the vehicle images in the current image scene.

8. The method for measuring vehicle speed based on blurred images as claimed in claim 1, wherein in step 4, a deep learning target detection method is adopted to perform blur degree calculation on the vehicle images and output blurred pixel values.

Technical Field

The invention belongs to the technical field of vehicle speed measurement, and particularly relates to a method for measuring vehicle speed based on a fuzzy image.

Background

At present, the modes of speed measurement based on video in traffic speed measurement mainly include a large-scene speed measurement method, a binocular or multi-view camera speed measurement method and a speed measurement mode combining a panoramic camera and a close-up camera. The large-scene speed measurement method has the advantages that the measurement accuracy is greatly influenced by the influence of illumination and the interference of other vehicles. The binocular camera and the multi-view camera use a plurality of cameras, are troublesome to install and are difficult to stereoscopically match. Based on the mode of combining the panoramic camera and the close-up camera, the defects of more cameras, complex installation and the like exist. Meanwhile, the traditional image speed measurement method generally needs to shoot a plurality of images, then compares the images and finally calculates the vehicle speed, and the corresponding vehicle speed measurement process is complex. Therefore, the invention discloses a method for measuring vehicle speed based on fuzzy images, aiming at the defects of inconvenient installation of speed measuring equipment and complex measuring process in the traditional vehicle speed measuring method.

Disclosure of Invention

The invention aims to provide a method for measuring vehicle speed based on a blurred image, which uses a shot image to evaluate the blur degree through a deep learning model to calculate the vehicle speed in the image, and can effectively simplify the installation and measurement process of vehicle speed measuring equipment.

The invention is realized by the following technical scheme:

a method for measuring vehicle speed based on blurred images comprises the following steps:

step 1, shooting a single vehicle scene image in real time;

step 2, calculating a calibration function between the road surface distance and the pixel distance according to the vehicle scene image;

step 3, extracting a vehicle image in the current vehicle scene image;

step 4, calculating the fuzziness of the vehicle image and outputting a fuzzy pixel value;

and 5, calculating the vehicle running speed according to the calibration function, the fuzzy pixel value and the shooting exposure time.

In order to better implement the invention, further, the following formula is adopted to calculate the vehicle running speed:

Figure BDA0002283145040000011

wherein: v is the vehicle speed;

h (x) is a calibration function;

z is the minimum pixel distance between the vehicle image and the first calibration line segment;

△ z are blurred pixel values;

△ t is the shot exposure time.

In order to better implement the present invention, further, the step 2 includes the following sub-steps:

step 2.1, respectively selecting a first calibration line segment and a second calibration line segment which are perpendicular to the length direction of the road surface and parallel to each other in the vehicle scene image, and measuring the actual lengths of the first calibration line segment and the second calibration line segment as d respectively1And d2

Step 2.2, calculating the pixel lengths of the first calibration line segment and the second calibration line segment to be P respectively according to the vehicle scene imaged1And Pd2Calculating the pixel distance h between the first calibration line segment and the second calibration line segmentp

Step 2.3, calculating a calibration function h (x) according to the following calculation formula:

Figure BDA0002283145040000021

wherein:

d1is the actual length of the first calibration line segment, d2The actual length of the second calibration line segment;

pd1is the pixel length of the first calibration line segment, pd2Is the pixel length of the second calibration line segment.

In order to better implement the invention, further, the distance between the first calibration line segment and the second calibration line segment is greater than or equal to the length of the vehicle.

In order to better implement the present invention, further, in step 1, a high-speed camera is used to capture an image of the vehicle, and several sets of fixed shutter exposure times are set.

To better implement the present invention, further, the fixed shutter exposure time is adjusted according to the intensity of the ambient light.

In order to better implement the present invention, further, in step 3, a deep learning target detection method is adopted to extract a vehicle image in a current image scene.

In order to better implement the present invention, in step 4, a deep learning target detection method is further adopted to perform a blur degree calculation on the vehicle image and output a blurred pixel value.

Compared with the prior art, the invention has the following advantages and beneficial effects:

(1) the method adopts the camera to shoot a single vehicle scene image, calculates the calibration function relationship between the road surface distance and the pixel distance according to the single vehicle scene image, extracts the vehicle image by a deep learning target detection method, calculates the vehicle image by fuzziness to obtain a fuzzy pixel value, and finally calculates the vehicle running speed according to the fuzzy pixel value, the calibration function and the shutter exposure time, compared with the traditional speed measurement method, the method has the advantages of extracting only the single image, having few required parameters and being simple, convenient and quick in the vehicle speed measurement calculation process;

(2) because only a single image is extracted, the invention only needs to install independent cameras corresponding to the lanes, the required number of the cameras is small, and the corresponding cameras are more convenient to install.

Drawings

FIG. 1 is a flow chart of the steps of the present invention;

fig. 2 is a schematic view of a scene image of a vehicle.

Detailed Description

7页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:基于仿生谐振毛发传感器的管道侧线阵列装置

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!