Vehicle speed measurement method, device, medium, equipment and system based on image processing

By installing a binocular camera on the vehicle and using the parallax angle to calculate the vehicle's speed, the problem of obtaining vehicle speed between the vehicle's electronic control system and the intelligent system is solved, and vehicle speed measurement is achieved without the need for additional hardware, reducing costs and avoiding interference with the electronic control system.

CN115547069BActive Publication Date: 2025-10-10BEIJING BOE TECH DEV CO LTD +1
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202211167583.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-23
Publication Date
2025-10-10
Estimated Expiration
2042-09-23

AI Technical Summary

Technical Problem

In the existing technology, it is difficult to directly connect the vehicle electronic control system and the on-board intelligent system to obtain the vehicle speed, which requires the installation of additional hardware, increases costs and may interfere with the normal operation of the electronic control system.

Method used

An image processing-based method is adopted. By installing a first camera and a second camera of a binocular shooting device on a vehicle, the vehicle's speed is calculated using the parallax angle, avoiding the need to install additional hardware.

Benefits of technology

The vehicle's speed can be obtained without the need for additional hardware installation and directly provided to the on-board intelligent system, avoiding interference with the electronic control system and reducing costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115547069B_ABST
    Figure CN115547069B_ABST
Patent Text Reader

Abstract

The application provides a vehicle speed measurement method and device based on image processing, a medium, equipment and system, the method comprises the following steps: acquiring images shot by a binocular shooting device at a set frequency during vehicle driving, the images comprising a first image shot by a first camera and a second image shot by a second camera, and determining a reference target from the first image and the second image; determining the image frame number when the relative position change of the reference target in the first image or the second image meets a preset requirement, determining the target duration based on the image frame number and the set frequency; calculating the distance of the vehicle driving within the target duration based on the parallax angle of the binocular shooting device; and calculating the driving speed of the vehicle based on the distance and the target duration. The application directly measures the driving speed based on image processing independently of the vehicle electronic control system, and does not need to additionally install redundant hardware, thereby avoiding increasing the cost and avoiding interfering with the vehicle electronic control system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vehicle speed measurement, and in particular to a vehicle speed measurement method, device, medium, equipment and system based on image processing. Background Art

[0002] The current trend toward intelligent vehicles is clear. After leaving the factory, consumers often install various intelligent systems on their vehicles. Vehicle speed is often a key input parameter for these systems. However, these aftermarket systems are often disconnected from the vehicle's electronic control system and cannot read the vehicle's real-time speed. Therefore, vehicle speed typically needs to be read from the vehicle's electronic control system or acquired using additional components such as accelerometers and speed radar. Transmitting speed from the vehicle's electronic control system to the intelligent system is difficult, and using additional components requires the installation of additional hardware, increasing system hardware measurement costs and even interfering with the normal operation of the vehicle's electronic control system. Summary of the Invention

[0003] The present invention provides a vehicle speed measurement method, device, medium, equipment and system based on image processing, providing a solution for measuring driving speed directly based on image processing, which is independent of the vehicle's electronic control system and does not require the installation of additional redundant hardware, thereby avoiding increased costs and interference with the vehicle's electronic control system.

[0004] In a first aspect, an embodiment of the present invention provides a vehicle speed measurement method based on image processing, wherein the vehicle body is equipped with a binocular camera for photographing the vehicle's exterior environment, the binocular camera comprising a first camera and a second camera located at different positions on the vehicle body; the method comprising:

[0005] Acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by the first camera and a second image captured by the second camera, and segment and determine a reference target from the first image and the second image;

[0006] determining the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determining a target duration based on the number of image frames and the set frequency;

[0007] Calculating the distance traveled by the vehicle within the target duration based on the parallax angle of the binocular camera device;

[0008] The driving speed of the vehicle is calculated based on the distance and the target duration.

[0009] In some implementations, the reference target includes a fixed reference object; and the driving speed of the vehicle includes the vehicle's own driving speed.

[0010] In some implementations, the reference target comprises a moving reference object; and the driving speed of the vehicle comprises a relative driving speed of the vehicle relative to the moving reference object.

[0011] In some implementations, the determining the image frame number at which the relative position change of the reference target in the first image or the second image meets the preset requirement comprises:

[0012] In the first image or the second image of the continuous multiple frames, in a case where the relative position change of the reference target in the first image and the last image reaches a preset threshold, the image frame number of the last image is determined as the image frame number at which the relative position change of the reference target meets the preset requirement.

[0013] In some implementations, the first camera and the second camera are respectively arranged at the front and the rear of the vehicle body to form a binocular camera device; and the calculating the distance traveled by the vehicle in the target time period based on the parallax angle of the binocular camera device comprises:

[0014] calculating the parallax angle formed by the first camera and the second camera;

[0015] calculating the first distance from the reference target to the first camera or the second distance from the reference target to the second camera at an initial time in the target time period based on the law of sines;

[0016] calculating the distance traveled by the vehicle in the target time period based on the first distance or the second distance by using the law of sines.

[0017] In some implementations, the calculating the parallax angle formed by the first camera and the second camera comprises:

[0018] calculating the parallax angle formed by the first camera and the second camera by using the law of sines based on a first included angle between the line direction of the reference target and the first camera and the driving direction of the vehicle and a second included angle between the line direction of the reference target and the second camera and the driving direction of the vehicle.

[0019] In some implementations, the calculating the first distance from the reference target to the first camera or the second distance from the reference target to the second camera at an initial time in the target time period based on the law of sines comprises:

[0020] calculating the first distance from the reference target to the first camera at an initial time in the target time period based on the distance between the first camera and the second camera, the second included angle and the parallax angle; or

[0021] A second distance from the reference target to the second camera at an initial time in the target duration is calculated based on the distance between the first camera and the second camera, the first angle, and the second angle.

[0022] In some implementations, the method further includes:

[0023] determining whether the driving speed exceeds a preset speed threshold;

[0024] When the driving speed exceeds a preset speed threshold, an abnormal prompt message is generated.

[0025] In a second aspect, an embodiment of the present invention provides a vehicle speed measurement system based on image processing, wherein a binocular camera for photographing the vehicle's exterior is mounted on the vehicle body, the binocular camera comprising a first camera and a second camera located at different positions on the vehicle body; the device comprises:

[0026] an acquisition module, configured to acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by the first camera and a second image captured by the second camera, and segment and determine a reference target from the first image and the second image;

[0027] a determination module, configured to determine the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determine a target duration based on the number of image frames and the set frequency;

[0028] A calculation module is used to calculate the distance traveled by the vehicle within the target duration based on the parallax angle of the binocular camera device, and calculate the driving speed of the vehicle based on the distance and the target duration.

[0029] In a third aspect, an embodiment of the present invention provides a computer storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by one or more processors, the method described in the first aspect is implemented.

[0030] In a fourth aspect, an embodiment of the present invention provides an electronic device comprising a memory and one or more processors, wherein the memory stores a computer program, and when the computer program is executed by the one or more processors, the method described in the first aspect is implemented.

[0031] In a fifth aspect, an embodiment of the present invention provides a vehicle speed measuring device, including:

[0032] At least one processor is configured to acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by a first camera and a second image captured by a second camera, and segment and determine a reference target from the first image and the second image; determine the number of image frames when a relative position change of the reference target in the first image or the second image meets a preset requirement, and determine a target duration based on the number of image frames and the set frequency; calculate a distance traveled by the vehicle within the target duration based on a parallax angle of the binocular camera; and calculate a travel speed of the vehicle based on the distance and the target duration;

[0033] A binocular camera device is installed on a vehicle body, and includes a first camera and a second camera located at different positions on the vehicle body.

[0034] In some implementations, the first camera and the second camera are respectively arranged at the front and rear of the vehicle body to form a binocular shooting device.

[0035] In some implementations, the first camera is disposed on an outer edge of an outer rearview mirror at the front of the vehicle body.

[0036] In some implementations, the binocular shooting device includes a binocular camera, which is disposed on an outer edge of an outer rearview mirror at the front of the vehicle body.

[0037] In some implementations, the vehicle speed measuring device further includes:

[0038] a voice prompter, connected to the processor, for providing a voice prompt of the vehicle's driving speed and / or playing an abnormal prompt message when the driving speed exceeds a preset speed threshold; and / or

[0039] A video display is connected to the processor and is used to display the driving speed of the vehicle and / or display abnormal prompt information when the driving speed exceeds a preset speed threshold.

[0040] In a sixth aspect, an embodiment of the present invention provides an on-board intelligent system, which is connected to the vehicle speed measuring device described in the first aspect to obtain the vehicle's driving speed obtained by the vehicle speed measuring device.

[0041] Compared with the prior art, one or more embodiments of the present invention can bring at least the following beneficial effects:

[0042] By capturing images of the vehicle's surroundings using a binocular camera, and exploiting the pattern in which external objects are captured sequentially by the two cameras, the vehicle's speed is measured based on image processing. This eliminates the need for redundant hardware to obtain speed from the vehicle's electronic control system. Speed ​​is measured directly through image processing, avoiding interference with the vehicle's electronic control system. The obtained speed can then be directly provided to the vehicle's intelligent system, making it easier for the vehicle's aftermarket intelligent system to obtain speed information. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and therefore should not be regarded as limiting the scope.

[0044] Figure 1 This is a flow chart of a vehicle speed measurement method based on image processing provided by an embodiment of the present invention;

[0045] Figure 2 This is an installation example of the first camera and the second camera provided by an embodiment of the present invention;

[0046] Figure 3 Schematic diagram of the angle between the line connecting the reference target and the camera and the driving direction provided by an embodiment of the present invention;

[0047] Figure 4 is a schematic diagram of the geometric relationship between the reference target, the first camera, and the second camera provided by an embodiment of the present invention;

[0048] Figure 5 is a schematic diagram of the geometric relationship between the reference target and the first camera within the target duration provided by an embodiment of the present invention;

[0049] Figure 6 This is a flow chart of another vehicle speed measurement method based on image processing provided by an embodiment of the present invention;

[0050] Figure 7 This is a block diagram of a vehicle speed measurement system based on image processing provided by an embodiment of the present invention;

[0051] Figure 8 Schematic diagram of the conversion relationship between world coordinates and camera coordinates provided by an embodiment of the present invention;

[0052] Figure 9 is a schematic diagram of the imaging plane of two cameras before epipolar correction provided by an embodiment of the present invention;

[0053] Figure 10 is a schematic diagram of the imaging plane of two cameras after epipolar correction provided by an embodiment of the present invention;

[0054] Figure 11 is a field of view calibration schematic diagram provided by the embodiment of the present application. DETAILED DESCRIPTION

[0055] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the drawings can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the claimed present application, but only represents selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present application.

[0056] In the application scenario of the embodiment of the present application, the vehicle body of a vehicle is provided with a binocular shooting device for shooting the external environment of the vehicle. The binocular shooting device includes a first camera and a second camera located at different positions of the vehicle body. The images of the external environment of the vehicle are shot by the first camera and the second camera with a certain parallax angle. The first camera is arranged at the front of the vehicle body, and the second camera is arranged at the rear of the vehicle body. During the driving process of the vehicle, the scenery on one side of the vehicle always first appears in the first camera at the front and then appears in the second camera at the rear. It can be considered that the external scenery of the vehicle moves from the imaging surface of the first camera to the imaging surface of the second camera.

[0057] The embodiment of the present application uses the binocular shooting device composed of cameras distributed at different positions of the vehicle body to continuously collect images at a set frequency. By using the principle that external objects are successively captured by cameras at different positions during the forward driving process of the vehicle, the driving speed of the vehicle is calculated, and the measurement of the driving speed of the vehicle itself and the relative driving speed of other vehicles is completed.

[0058] Example 1

[0059] Figure 1 A flowchart of a vehicle speed measurement method based on image processing is shown. As shown in Figure 1 The vehicle speed measurement method based on image processing of the embodiment includes:

[0060] Step S101, acquiring images shot by the binocular shooting device at a set frequency during the driving process of the vehicle, including a first image shot by the first camera and a second image shot by the second camera, and determining a reference target from the first image and the second image.

[0061] In some cases, the first camera and the second camera are respectively arranged at the front and rear of the vehicle body to form a binocular shooting device. Preferably, the first camera is arranged at the outer edge of the outer rearview mirror at the front of the vehicle body, and the second camera is arranged at the rear of the vehicle body. The first camera and the second camera shoot the external environment in the same direction to ensure that the same object can pass through the imaging surfaces of the two cameras successively and be photographed by the two cameras.

[0062] by Figure 2 For example, the first camera O1 is arranged on the outer edge of the outside rearview mirror on the right side of the front of the vehicle body, and the second camera O2 is arranged at the rear of the vehicle body, and the installation distance d from the first camera O2 in the width direction of the vehicle body, and the installation distance between the first camera O1 and the second camera O2 in the length direction of the vehicle body is L. Half of the horizontal field of view HLOV of the first camera O1 is θ1, and half of the horizontal field of view HFOV of the second camera O2 is θ2. Due to possible installation errors, θ1 and θ2 may not be consistent. It should be understood that the horizontal field of view HFOV of the first camera O1 and the second camera O2 can be calibrated during the camera calibration stage. During the driving process of the vehicle, the reference objects outside the vehicle will be captured by the first camera O1 and the second camera O2 in succession, and the images are A and A' respectively.

[0063] In other cases, the binocular shooting device used in this embodiment is a binocular camera, which can be arranged on the outer edge of the outer rearview mirror at the front of the vehicle body. The binocular camera includes a first camera and a second camera. There is parallax between these two cameras. During the driving process of the vehicle, the same object can still pass through the imaging surfaces of the two cameras successively and be photographed by the two cameras.

[0064] During normal driving of the vehicle, the first camera O1 and the second camera O2 are started at the same time. After the startup is completed and the vehicle runs stably, starting from a certain moment, the first camera O1 and the second camera O2 take images at a set frequency F, where the set frequency can be but is not limited to 30f / ps, that is, 30 frames of images are taken per second.

[0065] At a certain moment, the first camera O1 and the second camera O2 capture images G10 and G20, respectively. The images are then captured and cached simultaneously: a set of first images G10, ..., G1n, captured by the first camera O1, and a set of second images G20, ..., G2n, captured by the second camera O2, where n = 2, 3, 4, 5, ..., etc. While capturing the images, at least one reference object is identified through image segmentation. One of the at least one reference object is used as a reference target, such as a fixed reference object such as a billboard, a mountain, or a power pylon, or a moving reference object such as a vehicle. The identified reference target should be present in all images captured by the same camera, and its relative position in the images captured by the same camera should change significantly as the vehicle travels.

[0066] Step S102: determining the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determining the target duration based on the number of image frames and the set frequency.

[0067] In some implementations, determining the number of image frames at which a relative position change of a reference target in a first image or a second image meets a preset requirement includes:

[0068] Step S102a: In the first image or the second image of the continuous multiple frames, when the relative position change of the reference target in the first frame image and the last frame image reaches a preset threshold, determine that the image frame number of the last frame image is the image frame number that meets the preset requirements.

[0069] It should be understood that the change in the relative position of the reference target also reflects the change in the angle between the reference target and the optical axis of the camera.

[0070] In practical applications, the preset threshold can be set according to the actual calculation frequency requirements. For example, it can be 1 / S of the image width. When a relatively high calculation frequency is required to measure the driving speed more frequently, the value of S can be set relatively large (for example, the value of S is 10) to accurately track the changes in the driving speed; when a relatively low calculation frequency is required to measure the driving speed, the value of S can be set relatively small (for example, the value of S is 5), which can reduce the calculation pressure to a certain extent.

[0071] Still taking a group of first images G10, ...G1n taken by the first camera O1, and a group of second images G20, ...G2n taken by the second camera O2 as an example, in these consecutive n frames of first images or second images, the first frame first image is G10, the last frame first image is G1n, the first frame second image is G20, and the last frame second image is G2n. If the relative position change of the reference target in the first frame first image G10 and the last frame first image G1n reaches a preset threshold, the preset requirement is met, or if the relative position change of the reference target in the first frame second image G20 and the last frame second image G2n reaches a preset threshold, the preset requirement is met, and the number of image frames n corresponding to when the preset requirement is met is determined.

[0072] Furthermore, the target duration can be determined based on the number of image frames n and the set frequency F. The target duration also indicates the interval between the last time the driving speed was calculated based on image processing and the current time. By subsequently calculating the distance traveled by the vehicle within this target duration, the vehicle's driving speed can be obtained.

[0073] Taking n = 100s and F = 30f / ps as an example, it shows that a single camera needs to capture 100 frames of images for the relative position change to reach the preset threshold, and the target duration is determined to be T = n / F = 3.33s.

[0074] Step S103: Calculate the distance traveled by the vehicle within the target duration based on the parallax angle of the binocular camera device.

[0075] In some cases, the first camera and the second camera are respectively arranged at the front (e.g., the outer edge of the outer rearview mirror at the front of the vehicle) and the rear of the vehicle to form a binocular camera device. In this case, calculating the distance traveled by the vehicle within the target duration based on the parallax angle of the binocular camera device includes:

[0076] Step S103a: Calculate the parallax angle between the first camera and the second camera.

[0077] For example, if the first camera is mounted on the outer edge of the exterior rearview mirror at the front of the vehicle, its lens is oriented perpendicular to the vehicle body to capture the surroundings outside. Specifically, the angle η between the camera's optical axis and the longitudinal direction of the vehicle body is 90°. Similarly, the lens orientation of the second camera is aligned as closely as possible with that of the first camera.

[0078] by Figure 3 For example, if the reference target is within the camera's horizontal field of view (HFOV), and the camera's optical axis bisects HFOV, the angle α between the line connecting the reference target and the camera and the camera's optical axis can be calculated based on the angle η (not shown) between the camera's optical axis and the vehicle's length, and the angle θ between the line connecting the reference target and the camera and the direction of travel, satisfying η = α + θ. η is determined by the camera's mounting position and can be obtained during the calibration phase.

[0079] Therefore, in some implementations, the parallax angle between the first camera and the second camera is calculated based on a first angle formed by the direction of the line connecting the reference target and the first camera and the direction of vehicle travel, and a second angle formed by the direction of the line connecting the reference target and the second camera and the direction of vehicle travel.

[0080] by Figure 4 For example, based on the first angle θ1 formed by the line direction between the reference target and the first camera O1 and the vehicle's travel direction (body length direction), and the second angle θ2 formed by the line direction between the reference target and the second camera and the vehicle's travel direction, the parallax angle θ0 formed by the first camera and the second camera is calculated. Figure 3 The principle is to find that β = 180° - θ2. According to the theorem that the sum of the interior angles of a triangle is 180°, θ0 can be calculated, θ0 = 180° - θ1 - θ2, and the parallax angle between the first camera and the second camera is thus obtained.

[0081] Step S103b: Calculate a first distance from the reference target to the first camera or a second distance from the reference target to the second camera at the initial time in the target duration based on the law of sine.

[0082] Continue with Figure 4 For example, d1 is the first distance from the reference target to the first camera O1, d2 is the second distance from the reference target to the second camera, and L is the distance between the first camera and the second camera (determined during installation). Based on the sine theorem, d1 / sinθ0=d2 / sinθ1=L / sinθ2, and the unknown quantities d1 and d2 can be obtained.

[0083] When subsequently calculating the distance traveled by the vehicle within the target duration, the distance traveled by the vehicle within the target duration can be obtained based on the distance between the initial time reference target and one of the cameras within the target duration.

[0084] Therefore, in some implementations, calculating the first distance from the reference target to the first camera or the second distance from the reference target to the second camera at the initial time in the target duration based on the law of sine includes:

[0085] Calculate a first distance from the reference target to the first camera at an initial time in the target duration based on the distance between the first camera and the second camera, the second angle, and the parallax angle; or

[0086] A second distance from the reference target to the second camera at an initial time in the target duration is calculated based on the distance between the first camera and the second camera, the first angle, and the second angle.

[0087] Step S103c: Based on the first distance or the second distance, use the law of sine to calculate the distance traveled by the vehicle within the target duration.

[0088] Similar to step S103b, the sine law can be used to calculate the distance traveled by the vehicle within the target duration. Figure 4 and Figure 5 For example, from the initial time in the target duration to the last time in the target duration, the first camera O1 moves from position A to position B. During this period, the vehicle travels a distance of D. Based on the law of sine, D can be calculated.

[0089] Step S104: Calculate the vehicle's travel speed based on the distance and the target duration.

[0090] Based on the distance D traveled by the vehicle within the target time T, the vehicle's travel speed V=D / T is calculated.

[0091] In some cases, the reference target includes a fixed reference object, and accordingly, the calculated driving speed of the vehicle includes the vehicle's own driving speed.

[0092] In other cases, the reference target includes a moving reference object; accordingly, the calculated driving speed of the vehicle includes the relative driving speed of the vehicle relative to the moving reference object.

[0093] In some implementations, such as Figure 6 As shown, the vehicle speed measurement method based on image processing in this embodiment may further include:

[0094] Step S105: determining whether the driving speed exceeds a preset speed threshold;

[0095] Step S106: When the driving speed exceeds a preset speed threshold, an abnormal prompt message is generated.

[0096] Based on the vehicle's speed measurement, this method can further implement speeding reminders. The preset speed threshold can be determined according to the actual speeding standard, such as 60 km / h. When the speed exceeds the preset threshold, an abnormal speeding warning message is generated for the user's reference.

[0097] In some cases, in order to avoid the possible jump between the vehicle's driving speed calculated this time and the vehicle's driving speed calculated previously, which makes the measured driving speed unable to truly reflect the current vehicle condition, the driving speed can also be corrected by averaging the driving speeds obtained all before this time during the current driving process. For example, the driving speed has been calculated N times during the current driving process. After taking the average of these N driving speeds, the average is taken and then added to the driving speed calculated this time to obtain the final driving speed of the current time, and then it is determined whether it exceeds the preset speed threshold to provide an abnormal prompt.

[0098] In some cases, there may be two first cameras, which are installed on the outer edges of the left and right outside rearview mirrors at the front of the vehicle body respectively. These two first cameras form a binocular shooting device structure with the second camera installed at the rear of the vehicle body, and respectively execute the method of this embodiment, so that two driving speeds can be calculated. These two driving speeds can still be corrected according to the above-mentioned averaging method, and then the average value of the two corrected driving speeds can be averaged again to obtain the final driving speed at that time, and then determine whether it exceeds the preset speed threshold to provide an abnormal prompt.

[0099] This embodiment measures the vehicle's speed by capturing images of the vehicle's surroundings using a binocular camera. By exploiting the pattern in which external objects are sequentially captured by the binocular camera's two cameras, the system uses image processing to calculate and measure the vehicle's speed. This eliminates the need for redundant hardware to obtain speed from the vehicle's electronic control system. Speed ​​is measured directly through image processing, avoiding interference with the vehicle's electronic control system. The obtained speed can then be directly provided to the vehicle's intelligent system, making it easier for the vehicle's aftermarket intelligent system to obtain speed information.

[0100] Example 2

[0101] This embodiment provides a vehicle speed measurement system based on image processing, wherein a binocular camera for photographing the environment outside the vehicle is installed on the vehicle body, and the binocular camera comprises a first camera and a second camera located at different positions on the vehicle body; Figure 7 As shown, the system of this embodiment includes:

[0102] An acquisition module 201 is configured to acquire images captured by a binocular camera at a set frequency while the vehicle is traveling, including a first image captured by a first camera and a second image captured by a second camera, and to segment and determine a reference target from the first image and the second image;

[0103] A determination module 202 is configured to determine the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determine a target duration based on the number of image frames and a set frequency;

[0104] The calculation module 203 is configured to calculate the distance traveled by the vehicle within the target duration based on the parallax angle of the binocular camera device, and calculate the vehicle's travel speed based on the distance and the target duration.

[0105] In some cases, the first camera and the second camera are respectively arranged at the front and rear of the vehicle body to form a binocular shooting device. Preferably, the first camera is arranged at the outer edge of the outer rearview mirror at the front of the vehicle body, and the second camera is arranged at the rear of the vehicle body. The first camera and the second camera shoot the external environment in the same direction to ensure that the same object can pass through the imaging surfaces of the two cameras successively and be photographed by the two cameras.

[0106] In other cases, the binocular shooting device used in this embodiment is a binocular camera, which can be arranged on the outer edge of the outer rearview mirror at the front of the vehicle body. The binocular camera includes a first camera and a second camera. There is parallax between these two cameras. During the driving process of the vehicle, the same object can still pass through the imaging surfaces of the two cameras successively and be photographed by the two cameras.

[0107] During normal driving of the vehicle, the first camera O1 and the second camera O2 are started at the same time. After the startup is completed and the vehicle runs stably, starting from a certain moment, the first camera O1 and the second camera O2 take images at a set frequency F, where the set frequency can be but is not limited to 30f / ps, that is, 30 frames of images are taken per second.

[0108] At a certain moment, the first camera O1 and the second camera O2 capture images G10 and G20, respectively. The images are then captured and cached simultaneously: a set of first images G10, ..., G1n, captured by the first camera O1, and a set of second images G20, ..., G2n, captured by the second camera O2, where n = 2, 3, 4, 5, ..., etc. While capturing the images, at least one reference object is identified through image segmentation. One of the at least one reference object is used as a reference target, such as a fixed reference object such as a billboard, a mountain, or a power pylon, or a moving reference object such as a vehicle. The identified reference target should be present in all images captured by the same camera, and its relative position in the images captured by the same camera should change significantly as the vehicle travels.

[0109] In some implementations, determining the number of image frames when the relative position change of the reference target in the first image or the second image meets the preset requirements includes: in multiple consecutive frames of the first image or the second image, when the relative position change of the reference target in the first frame image and the last frame image reaches a preset threshold, determining that the image frame number of the last frame image is the image frame number that meets the preset requirements.

[0110] It should be understood that the change in the relative position of the reference target also reflects the change in the angle between the reference target and the optical axis of the camera.

[0111] Still taking a group of first images G10, ...G1n taken by the first camera O1, and a group of second images G20, ...G2n taken by the second camera O2 as an example, in these consecutive n frames of first images or second images, the first frame first image is G10, the last frame first image is G1n, the first frame second image is G20, and the last frame second image is G2n. If the relative position change of the reference target in the first frame first image G10 and the last frame first image G1n reaches a preset threshold, the preset requirement is met, or if the relative position change of the reference target in the first frame second image G20 and the last frame second image G2n reaches a preset threshold, the preset requirement is met, and the number of image frames n corresponding to when the preset requirement is met is determined.

[0112] Furthermore, the target duration can be determined based on the number of image frames n and the set frequency F. The target duration also indicates the interval between the last time the driving speed was calculated based on image processing and the current time. By subsequently calculating the distance traveled by the vehicle within this target duration, the vehicle's driving speed can be obtained.

[0113] In a case that the first camera and the second camera are respectively arranged at a front portion (for example, an outer edge of an outside rearview mirror of the front portion of the vehicle body) and a rear portion of the vehicle body, the distance traveled by the vehicle in the target time period is calculated based on a parallax angle of the binocular camera device, including: calculating a parallax angle formed by the first camera and the second camera; calculating a first distance from the reference target to the first camera or a second distance from the reference target to the second camera at an initial time in the target time period based on the sine theorem; and calculating the distance traveled by the vehicle in the target time period based on the first distance or the second distance by using the sine theorem.

[0114] In some implementations, the parallax angle formed by the first camera and the second camera is calculated based on a first included angle between a line direction of the reference target and the first camera and a direction of travel of the vehicle, and a second included angle between a line direction of the reference target and the second camera and the direction of travel of the vehicle.

[0115] In some implementations, the first distance from the reference target to the first camera or the second distance from the reference target to the second camera at the initial time in the target time period is calculated based on the sine theorem, including:

[0116] The first distance from the reference target to the first camera at the initial time in the target time period is calculated based on a distance between the first camera and the second camera, the second included angle, and the parallax angle; or

[0117] The second distance from the reference target to the second camera at the initial time in the target time period is calculated based on the distance between the first camera and the second camera, the first included angle, and the second included angle.

[0118] Based on the distance D traveled by the vehicle in the target time period T, a travel speed V of the vehicle is calculated as V = D / T.

[0119] In some cases, the reference target includes a fixed reference object, and accordingly, the calculated travel speed of the vehicle includes a self travel speed of the vehicle.

[0120] In other cases, the reference target includes a moving reference object, and accordingly, the calculated travel speed of the vehicle includes a relative travel speed of the vehicle relative to the moving reference object.

[0121] In some implementations, the apparatus of the present embodiment can further include:

[0122] The prompting module is configured to determine whether the travel speed exceeds a preset speed threshold, and generate an abnormal prompt information in a case that the travel speed exceeds the preset speed threshold.

[0123] Based on the vehicle's speed measurement, this method can further implement speeding reminders. The preset speed threshold can be determined according to the actual speeding standard, such as 60 km / h. When the speed exceeds the preset threshold, an abnormal speeding warning message is generated for the user's reference.

[0124] This embodiment measures the vehicle's speed by capturing images of the vehicle's surroundings using a binocular camera. By exploiting the pattern in which external objects are sequentially captured by the binocular camera's two cameras, the system uses image processing to calculate and measure the vehicle's speed. This eliminates the need for redundant hardware to obtain speed from the vehicle's electronic control system. Speed ​​is measured directly through image processing, avoiding interference with the vehicle's electronic control system. The obtained speed can then be directly provided to the vehicle's intelligent system, making it easier for the vehicle's aftermarket intelligent system to obtain speed information.

[0125] Those skilled in the art will appreciate that the above modules or steps can be implemented using a general-purpose computing device, centralized on a single computing device, or distributed across a network of multiple computing devices. Alternatively, they can be implemented using program code executable by a computing device, which can then be stored in a storage device and executed by the computing device. Alternatively, they can be fabricated into separate integrated circuit modules, or multiple modules or steps can be fabricated into a single integrated circuit module for implementation. The present invention is not limited to any specific combination of hardware and software.

[0126] Example 3

[0127] This embodiment provides a computer storage medium. The computer-readable storage medium stores a computer program. When the computer program is executed by one or more processors, the method of the above embodiment is implemented.

[0128] Among them, the computer-readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk or optical disk.

[0129] The method implemented in this embodiment is detailed in the above embodiments and will not be described again in this embodiment.

[0130] Example 4

[0131] This embodiment provides an electronic device, including a memory and one or more processors. The memory stores a computer program, and when the computer program is executed by the one or more processors, the method of the above embodiment is implemented.

[0132] In practical applications, the processor can be an application specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable logic device (PLD), a field programmable gate array (FPGA), a controller, a microcontroller unit (MCU), a microprocessor or other electronic components to execute the methods in the above embodiments.

[0133] The method implemented in this embodiment is detailed in the above embodiments and will not be described again in this embodiment.

[0134] Example 5

[0135] This embodiment provides a vehicle speed measurement device, including:

[0136] At least one processor is configured to acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by a first camera and a second image captured by a second camera, and segment and determine a reference target from the first image and the second image; determine the number of image frames when a relative position change of the reference target in the first image or the second image meets a preset requirement, and determine a target duration based on the number of image frames and the set frequency; calculate a distance traveled by the vehicle within the target duration based on a parallax angle of the binocular camera; and calculate a travel speed of the vehicle based on the distance and the target duration;

[0137] A binocular camera device is installed on a vehicle body, and includes a first camera and a second camera located at different positions on the vehicle body.

[0138] In some implementations, the first camera and the second camera are respectively arranged at the front and rear of the vehicle body to form a binocular shooting device, wherein the first camera is preferably arranged at the outer edge of the outside rearview mirror at the front of the vehicle body, and the outside rearview mirror can refer to the outside rearview mirror on the left front of the vehicle body or the outside rearview mirror on the right front of the vehicle body, and the second camera can be arranged in an unobstructed position at the rear of the vehicle body.

[0139] In some implementations, the binocular shooting device is a binocular camera, which is disposed on the outer edge of an outer rearview mirror at the front of the vehicle body.

[0140] In some implementations, the vehicle speed measuring device of this embodiment may further include:

[0141] a voice prompter connected to the processor for providing a voice prompt of the vehicle's driving speed and / or playing an abnormal prompt message when the driving speed exceeds a preset speed threshold; and / or

[0142] The video display is connected to the processor and is used to display the vehicle's driving speed and / or display abnormal prompt information when the driving speed exceeds a preset speed threshold.

[0143] Abnormal prompt information can be output through a voice prompter and / or a video display, so that the abnormal prompt information can be obtained in time and the abnormal situation can be handled as soon as possible.

[0144] In some implementations, determining the number of image frames at which a relative position change of a reference target in a first image or a second image meets a preset requirement includes:

[0145] In the first image or the second image of multiple consecutive frames, when the relative position change of the reference target in the first frame image and the last frame image reaches a preset threshold, the image frame number of the last frame image is determined to be the image frame number that meets the preset requirements.

[0146] In practical applications, the preset threshold can be set according to the actual calculation frequency requirements. For example, it can be 1 / S of the image width. When a relatively high calculation frequency is required to measure the driving speed more frequently, the value of S can be set relatively large (for example, the value of S is 10) to accurately track the changes in the driving speed; when a relatively low calculation frequency is required to measure the driving speed, the value of S can be set relatively small (for example, the value of S is 5), which can reduce the calculation pressure to a certain extent.

[0147] Taking a group of first images G10, ...G1n taken by the first camera O1, and a group of second images G20, ...G2n taken by the second camera O2 as examples, in these consecutive n frames of first images or second images, the first frame first image is G10, the last frame first image is G1n, the first frame second image is G20, and the last frame second image is G2n, if the relative position change of the reference target in the first frame first image G10 and the last frame first image G1n reaches a preset threshold, then the preset requirement is met, or if the relative position change of the reference target in the first frame second image G20 and the last frame second image G2n reaches a preset threshold, then the preset requirement is met, and the number of image frames n corresponding to when the preset requirement is met is determined.

[0148] Furthermore, the target duration can be determined based on the number of image frames n and the set frequency F. The target duration also indicates the interval between the last time the driving speed was calculated based on image processing and the current time. By subsequently calculating the distance traveled by the vehicle within this target duration, the vehicle's driving speed can be obtained.

[0149] Taking n = 100s and F = 30f / ps as an example, it shows that a single camera needs to capture 100 frames of images for the relative position change to reach the preset threshold, and the target duration is determined to be T = n / F = 3.33s.

[0150] In some cases, the first camera and the second camera are respectively arranged at the front (e.g., the outer edge of the outer rearview mirror at the front of the vehicle) and the rear of the vehicle to form a binocular camera device. In this case, calculating the distance traveled by the vehicle within the target duration based on the parallax angle of the binocular camera device includes:

[0151] Calculating a parallax angle between the first camera and the second camera; calculating a first distance from the reference target to the first camera or a second distance from the reference target to the second camera at an initial time in the target duration based on the law of sine; and calculating a distance traveled by the vehicle within the target duration based on the first distance or the second distance using the law of sine.

[0152] In some cases, the reference target includes a fixed reference object, and accordingly, the calculated driving speed of the vehicle includes the vehicle's own driving speed.

[0153] In other cases, the reference target includes a moving reference object; accordingly, the calculated driving speed of the vehicle includes the relative driving speed of the vehicle relative to the moving reference object.

[0154] The processor is further configured to determine whether the driving speed exceeds a preset speed threshold; and generate an abnormal prompt message when the driving speed exceeds the preset speed threshold.

[0155] In some cases, in order to avoid the possible jump between the vehicle's driving speed calculated this time and the vehicle's driving speed calculated previously, which makes the measured driving speed unable to truly reflect the current vehicle condition, the driving speed can also be corrected by averaging the driving speeds obtained all before this time during the current driving process. For example, the driving speed has been calculated N times during the current driving process. After taking the average of these N driving speeds, the average is taken and then added to the driving speed calculated this time to obtain the final driving speed of the current time, and then it is determined whether it exceeds the preset speed threshold to provide an abnormal prompt.

[0156] In some cases, there may be two first cameras, which are installed on the outer edges of the left and right outside rearview mirrors at the front of the vehicle body respectively. These two first cameras form a binocular shooting device structure with the second camera installed at the rear of the vehicle body, and respectively execute the method of this embodiment, so that two driving speeds can be calculated. These two driving speeds can still be corrected according to the above-mentioned averaging method, and then the average value of the two corrected driving speeds can be averaged again to obtain the final driving speed at that time, and then determine whether it exceeds the preset speed threshold to provide an abnormal prompt.

[0157] In some implementations, the processor obtains system power from the vehicle electronic control system in the vehicle, the first camera is installed on the outer edge of the outside rearview mirror at the front of the vehicle body, and the second camera is arranged in an unobstructed position at the rear of the vehicle body, such as Figure 2 As shown. In the wired transmission mode, the transmission cable of the first camera is introduced into the vehicle through the outer rearview mirror and the door, and the transmission cable of the second camera can be introduced into the vehicle through the rear door, and the introduced transmission cable is connected to the processor. The processor, video display and voice prompt are integrated into the center console of the cockpit. When the vehicle is driving, the first camera and the second camera capture images, and the images are transmitted to the processor for processing through the transmission cable. The processor calculates the vehicle's driving speed according to the method provided in the embodiment of the present invention for use by other modules connected to the system processor (such as voice prompt, video display).

[0158] In some implementations, the vehicle speed measurement device of this embodiment may further include a memory for storing each image captured and the calculated vehicle speed when the first camera and the second camera capture images. The image storage may be in, but is not limited to, a queue form. For example, the images G10, G11, ..., G1n captured by the first camera are stored as a queue in the order of capture, and the images G20, G21, ..., G2n captured by the second camera are stored as a queue in the order of capture.

[0159] In practical applications, the following system calibration can be performed at the beginning of system startup.

[0160] First, transform from the world coordinate system to the camera coordinate system.

[0161] Assume that any point P in the world coordinate system is denoted as (Xw, Yw, Zw), and the coordinates of its image point p in the camera coordinate system are denoted as (Xc, Yc, Zc). In homogeneous form, it can be considered that point P reaches point p after rotation and translation. The rotation matrix of the coordinate transformation is denoted as R 3×3 (3 degrees of freedom), the translation matrix is ​​denoted as T, and the two form a 4×4 matrix, which is the external parameter matrix of the camera. The transformation relationship between the world coordinates and the camera coordinates is as follows Figure 8 And the following matrix relationship is shown:

[0162]

[0163] Second, convert from the camera coordinate system to the pixel coordinate system

[0164] The pixel coordinate system is a two-dimensional rectangular coordinate system that reflects the arrangement of pixels in the camera CCD / CMOS chip. The origin of the coordinate is located in the upper left corner of the image, and the u-axis and v-axis are parallel to the two sides of the image plane, such as Figure 8 As shown in the figure, the unit of the coordinate axis in the pixel coordinate system is pixel (integer).

[0165] The pixel coordinate system is not conducive to coordinate transformation, so it is necessary to establish an image coordinate system XOY. The coordinate axis units are millimeters (mm). The origin is the intersection of the camera optical axis and the image plane (called the principal point), which is the center point of the image. The X-axis and Y-axis are parallel to the U-axis and V-axis, respectively. Therefore, the two coordinate systems are actually a translation relationship. That is, the image coordinate system is obtained by translating the pixel coordinate system.

[0166] The transformation relationship between the pixel coordinate system and the image coordinate system is as follows:

[0167]

[0168] Among them, dX and dY are the physical sizes of the pixel in the X and Y axis directions, respectively, and u0 and v0 are the coordinates of the principal point (image origin).

[0169] The transformation relationship between the pixel coordinate system and the world coordinate system is as follows:

[0170]

[0171] Among them, R is the rotation matrix, T is the translation matrix, s is the scale factor between the pixel coordinate system and the world coordinate system, Xw is the coordinate in the world coordinate system, f is the focal length of the camera, and f x =f / dX, f y =f / dY, where are the normalized focal lengths on the u and v axes respectively, M1 is the intrinsic parameter matrix of the camera, M2 is the extrinsic parameter matrix of the camera, and M is the projection matrix.

[0172] Again, epipolar correction

[0173] In actual installation, the optical axes of the first and second cameras are not parallel, which will affect the measurement accuracy and the complexity of subsequent processing. Therefore, it is necessary to determine the actual rotation relationship between the two cameras so that the imaging planes of the two cameras are parallel (the optical axes are parallel) to complete the epipolar correction.

[0174] Assume that two cameras are distributed at points O and O', and the spatial coordinate point P is imaged at points p and p' on the camera imaging plane, respectively. Figure 9 It can be seen that the two imaging planes are not parallel and there is a certain angle between them.

[0175] Assume that the coordinate system of the first camera on the left is the world coordinate system, and the external parameters of the second camera on the right are R (rotation matrix) and T (translation matrix). Then the point P1 in the coordinate system of the first camera is:

[0176] P2=RP1+T (1)

[0177] The first step in epipolar correction is to rotate each camera by half of R so that the imaging planes of the two cameras are parallel. First, perform a Rodrigues transform on R to obtain the rotation vector θn, where θ is the rotation angle and n is the unit vector of the rotation axis. Perform an inverse Rodrigues transform on the rotation vector (θ / 2)*n to obtain the rotation matrix r, which has the property: r*r=R. Then, rotating the first camera by r and the second camera by r can make the image planes of the two cameras parallel. The coordinates of the rotated point are: P1'=r*P1. Substituting into equation (1) yields:

[0178] P2'=P1'+r -1 *T (2)

[0179] Let t = r -1 *T is the translation vector after rotation.

[0180] The second step of epipolar correction is to make the epipolar lines of the two camera images horizontal, that is, the x-axis coincides with t, then:

[0181] First, calculate the rotation axis of t and the x-axis: cross-product t with the unit vector (1,0,0) to get the rotation axis w, whose modulus is the modulus of t and the sine product of the required rotation angle α: |t|*sinα

[0182] The third step of epipolar correction is to calculate the rotation angle: the component of t on the x-axis is its x-axis coordinate c, and the rotation angle α = acos(c / |t|).

[0183] Therefore, to adjust the length of w: to make it equal to α, we need to multiply it by acos(c / |t|) / |w|

[0184] Perform the inverse Rodrigo transform on the scaled w to obtain the rotation matrix Rw, and rotate both the left and right cameras by Rw, P1" = R W *P1', substituting into (2) we can get:

[0185] P2”=P1”+R W *r -1 *T

[0186] Finally, the rotation matrix of the first camera and the second camera is obtained, such as Figure 10 As shown, the two camera image planes are parallel at this time, and the epipolar line (the line where l and l' are located) is parallel to the baseline (the line where O and O' are located).

[0187] Finally, calibrate the camera's field of view

[0188] like Figure 11 As shown, a field of view test drawing is fixed to a test board with a magnet. The camera is pointed directly at the center of the drawing to take a picture (the shooting distance is determined according to the drawing specifications, and in this embodiment, the shooting distance can be 50 cm), so that the two diagonal lines of the camera image fall exactly at the four corners of the picture. After taking the picture, the HFOV (horizontal field of view), VFOV (vertical field of view), and DFOV (diagonal field of view) are read according to the scale lines. The horizontal field of view (HFOV) calibrated here can be used to provide a basis for subsequently estimating the angle between the reference template and the camera optical axis.

[0189] The above system calibration can make the image imaging effects of the first camera and the second camera meet actual needs, and then execute the method of the above embodiment to achieve vehicle speed measurement based on image processing.

[0190] The vehicle speed measuring device of this embodiment can directly obtain the vehicle's driving speed, avoiding interference with the vehicle's electronic control system by obtaining the driving speed from the vehicle's electronic control system, and does not require the installation of additional redundant hardware to increase costs. The method of measuring the driving speed is simple and reliable and does not affect the normal operation of the vehicle.

[0191] Example 6

[0192] This embodiment provides an in-vehicle intelligent system, which is connected to the vehicle speed measuring device of the aforementioned embodiment to obtain the vehicle's running speed obtained by the vehicle speed measuring device.

[0193] The on-board intelligent system of this embodiment can directly obtain the vehicle's driving speed from the aforementioned vehicle speed measuring equipment, avoiding interference with the vehicle's electronic control system caused by obtaining the driving speed from the vehicle's electronic control system, and there is no need to install additional redundant hardware to increase costs. The method of measuring driving speed is simple and reliable and does not affect the normal operation of the vehicle.

[0194] In the several embodiments provided in the embodiments of the present invention, it should be understood that the disclosed system and method can also be implemented in other ways. The above-described system and method embodiments are merely illustrative.

[0195] It should be noted that, in this document, the terms "first", "second", etc. in the specification and claims of this application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. The terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device that includes a series of elements includes not only those elements, but also includes other elements that are not explicitly listed, or also includes elements that are inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a..." does not exclude the presence of other identical elements in the process, method, article or device that includes the element.

[0196] Although the embodiments disclosed herein are as described above, the contents described herein are merely embodiments for facilitating understanding of the present invention and are not intended to limit the present invention. Any person skilled in the art may make any modifications and variations in the form and details of the embodiments without departing from the spirit and scope of the present invention. However, the scope of patent protection of the present invention shall remain subject to the scope defined by the appended claims.

Claims

1. A vehicle speed measurement method based on image processing, characterized in that: The vehicle body is equipped with a binocular camera for photographing an environment outside the vehicle, the binocular camera comprising a first camera and a second camera located at different positions on the vehicle body, the first camera and the second camera being arranged at the front and rear of the vehicle body, respectively, so that the same object can pass through the imaging planes of the first camera and the second camera successively and be photographed by the first camera and the second camera; the method comprising: Acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by the first camera and a second image captured by the second camera, and segment and determine a reference target from the first image and the second image; determining the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determining a target duration based on the number of image frames and the set frequency; calculating a parallax angle formed by the first camera and the second camera; Calculating a first distance from the reference target to the first camera or a second distance from the reference target to the second camera at an initial time in the target duration based on the law of sine; Calculating the distance traveled by the vehicle within the target duration using the law of sine based on the first distance or the second distance; The driving speed of the vehicle is calculated based on the distance and the target duration.

2. The vehicle speed measurement method based on image processing according to claim 1, characterized in that: The reference target includes a fixed reference object; the driving speed of the vehicle includes the vehicle's own driving speed.

3. The vehicle speed measurement method based on image processing according to claim 1, characterized in that: The reference target includes a moving reference object; the driving speed of the vehicle includes a relative driving speed of the vehicle relative to the moving reference object.

4. The vehicle speed measurement method based on image processing according to claim 1, characterized in that: The determining the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement includes: In the first image or the second image of multiple consecutive frames, when the relative position change of the reference target in the first frame image and the last frame image reaches a preset threshold, the image frame number of the last frame image is determined to be the image frame number that meets the preset requirements.

5. The vehicle speed measurement method based on image processing according to claim 1, characterized in that: The calculating the parallax angle formed by the first camera and the second camera includes: A parallax angle formed by the first camera and the second camera is calculated based on a first angle formed by a line connecting the reference target and the first camera and a direction of travel of the vehicle, and a second angle formed by a line connecting the reference target and the second camera and the direction of travel of the vehicle.

6. The vehicle speed measurement method based on image processing according to claim 5, characterized in that: The calculating, based on the law of sine, of a first distance from the reference target to the first camera or a second distance from the reference target to the second camera at an initial time in the target duration includes: Calculate a first distance from the reference target to the first camera at an initial time in the target duration based on the distance between the first camera and the second camera, the second angle, and the parallax angle; or A second distance from the reference target to the second camera at an initial time in the target duration is calculated based on the distance between the first camera and the second camera, the first angle, and the second angle.

7. The vehicle speed measurement method based on image processing according to claim 1, characterized in that: Also includes: determining whether the driving speed exceeds a preset speed threshold; When the driving speed exceeds a preset speed threshold, an abnormal prompt message is generated.

8. A vehicle speed measurement system based on image processing, characterized in that: The vehicle body is equipped with a binocular camera for photographing an environment outside the vehicle, the binocular camera comprising a first camera and a second camera located at different positions on the vehicle body, the first camera and the second camera being arranged at the front and rear of the vehicle body, respectively, so that the same object can pass through the imaging planes of the first camera and the second camera successively and be photographed by the first camera and the second camera; The vehicle speed measuring device comprises: an acquisition module, configured to acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by the first camera and a second image captured by the second camera, and segment and determine a reference target from the first image and the second image; a determination module, configured to determine the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determine a target duration based on the number of image frames and the set frequency; The calculation module is configured to calculate a parallax angle formed by the first camera and the second camera; calculate a first distance from the reference target to the first camera or a second distance from the reference target to the second camera at an initial time in a target duration based on the law of sine; calculate a distance traveled by the vehicle within the target duration using the law of sine based on the first distance or the second distance, and calculate a travel speed of the vehicle based on the distance and the target duration.

9. A computer storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by one or more processors, the method according to any one of claims 1 to 7 is implemented.

10. An electronic device, characterized in that: The method comprises a memory and one or more processors, wherein a computer program is stored in the memory, and when the computer program is executed by the one or more processors, the method according to any one of claims 1 to 7 is implemented.

11. A vehicle speed measuring device, characterized in that: include: A binocular camera device mounted on a vehicle body, the binocular camera device comprising a first camera and a second camera located at different positions on the vehicle body, the first camera and the second camera being disposed at the front and rear of the vehicle body, respectively, so that the same object can be captured by both the first camera and the second camera by passing through the imaging planes of the first camera and the second camera in sequence; at least one processor, configured to acquire images captured by the binocular camera at a set frequency while the vehicle is traveling, including a first image captured by the first camera and a second image captured by the second camera, and segment and determine a reference target from the first image and the second image; determining the number of image frames when the relative position change of the reference target in the first image or the second image meets a preset requirement, and determining a target duration based on the number of image frames and the set frequency; calculating a parallax angle formed by the first camera and the second camera; A first distance from the reference target to the first camera or a second distance from the reference target to the second camera at an initial time in the target duration is calculated based on the law of sine; a distance traveled by the vehicle within the target duration is calculated using the law of sine based on the first distance or the second distance; and a driving speed of the vehicle is calculated based on the distance and the target duration.

12. The vehicle speed measuring device according to claim 11, characterized in that: The first camera is arranged on the outer edge of the outer rearview mirror at the front of the vehicle body.

13. The vehicle speed measuring device according to claim 11, characterized in that: The binocular shooting device includes a binocular camera, which is arranged on the outer edge of the outer rearview mirror at the front of the vehicle body.

14. The vehicle speed measuring device according to claim 11, characterized in that: Also includes: a voice prompter, connected to the processor, for providing a voice prompt of the vehicle's driving speed and / or playing an abnormal prompt message when the driving speed exceeds a preset speed threshold; and / or A video display is connected to the processor and is used to display the driving speed of the vehicle and / or display abnormal prompt information when the driving speed exceeds a preset speed threshold.

15. An in-vehicle intelligent system, characterized in that: The on-board intelligent system is connected to the vehicle speed measuring device according to any one of claims 11 to 14 to obtain the vehicle's driving speed obtained by the vehicle speed measuring device.

Citation Information

Patent Citations

  • Vehicle speed measurement method based on binocular camera computer vision technology

    CN106370884A

  • Moving target detection method and device, vehicle and storage medium

    CN112396634A

  • Blind area detection method and system based on binocular camera and storage medium

    CN113191238A