CN114037924A - Vehicle brake-passing judgment method based on image recognition technology and related device - Google Patents

Vehicle brake-passing judgment method based on image recognition technology and related device Download PDF

Info

Publication number
CN114037924A
CN114037924A CN202111137496.3A CN202111137496A CN114037924A CN 114037924 A CN114037924 A CN 114037924A CN 202111137496 A CN202111137496 A CN 202111137496A CN 114037924 A CN114037924 A CN 114037924A
Authority
CN
China
Prior art keywords
vehicle
track
target
brake
trajectory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111137496.3A
Other languages
Chinese (zh)
Inventor
唐健
张驰
王浩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Jieshun Science and Technology Industry Co Ltd
Original Assignee
Shenzhen Jieshun Science and Technology Industry Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Jieshun Science and Technology Industry Co Ltd filed Critical Shenzhen Jieshun Science and Technology Industry Co Ltd
Priority to CN202111137496.3A priority Critical patent/CN114037924A/en
Publication of CN114037924A publication Critical patent/CN114037924A/en
Pending legal-status Critical Current

Links

Images

Abstract

The application discloses a vehicle brake-passing judgment method and a related device based on an image recognition technology, which are used for detecting and tracking a driving track of a vehicle by utilizing a deep learning algorithm and judging brake-passing according to the driving track, so that the accuracy of vehicle brake-passing judgment is improved. The method comprises the following steps: acquiring a video of an entrance and an exit of a parking lot through a parking lot camera; extracting target images frame by frame in the video of the entrance and exit of the parking lot; detecting the vehicles and the license plates in the target image by adopting a target detection algorithm; carrying out license plate information identification on the detected license plate in the target image; binding the license plate information and the position relation between the vehicle and the license plate in the target image, and determining the target vehicle according to the binding result; tracking the vehicle track of the target vehicle by adopting a tracking algorithm; and judging whether the target vehicle passes through the brake according to the vehicle track.

Description

Vehicle brake-passing judgment method based on image recognition technology and related device
Technical Field
The application relates to the technical field of image recognition, in particular to a vehicle brake-passing judgment method based on an image recognition technology and a related device.
Background
Along with the progress and development of society, the quantity and the scale in parking area also greatly increased, and it has the significance to accurately judge whether the vehicle enters the parking area, and it not only is concerned with remaining parking stall count in the field, still will be concerned with the reasonable charge of vehicle admission and departure and the management and control of non-motor vehicle etc..
In the prior art, there are various ways to determine whether a vehicle is passing a brake: one is a mode based on a ground induction coil, which is arranged below a barrier gate, and whether a vehicle exists or not is determined by detecting a metal object, and the mode cannot really judge whether the vehicle passes through the gate or not, and is difficult to distinguish whether two vehicles pass through the gate or one vehicle passes through the gate under the condition that other vehicles follow the vehicle; the other method is based on a radar sensor, which is used for placing the radar sensor on two sides of a road, monitoring electromagnetic waves returned by a vehicle, and judging whether the vehicle passes through a brake or not by measuring the change of the distance. This method also does not accurately distinguish between passing non-motor vehicles and passing vehicles.
In summary, the implementation of the method for determining whether a vehicle passes through a brake in the prior art cannot determine whether the object passing through the brake is a motor vehicle or a non-motor vehicle, and cannot determine whether the vehicle backs up and leaves, so that the accuracy of determining whether the vehicle passes through the brake is not high.
Disclosure of Invention
The application provides a vehicle brake-passing judgment method and a related device based on an image recognition technology, which are used for detecting and tracking a driving track of a vehicle by using a deep learning algorithm and judging brake-passing according to the driving track, so that the accuracy of vehicle brake-passing judgment is improved.
The application provides a vehicle brake-passing judgment method based on an image recognition technology in a first aspect, which comprises the following steps:
acquiring a video of an entrance and an exit of a parking lot through a parking lot camera;
extracting target images frame by frame in the video of the entrance and exit of the parking lot;
detecting the vehicles and the license plates in the target image by adopting a target detection algorithm;
carrying out license plate information identification on the detected license plate in the target image;
binding the license plate information and the position relation between the vehicle and the license plate in the target image, and determining the target vehicle according to the binding result;
tracking the vehicle track of the target vehicle by adopting a tracking algorithm;
and judging whether the target vehicle passes through the brake according to the vehicle track.
Optionally, the determining whether the target vehicle is braked according to the vehicle track includes:
calculating the track direction and the track displacement of the target vehicle according to the vehicle track, wherein the vehicle track is composed of the central points of vehicle detection frames in a plurality of frames of the target image;
judging whether the track frame number of the vehicle track is smaller than a preset frame number or not;
if not, judging whether the vehicle track meets a first brake passing condition or not;
the first pass-gate condition comprises:
the vehicle trajectory disappears from the lower boundary of the target image, the length of the trajectory displacement is greater than 100 pixels, and the cosine value between the trajectory direction and the preset direction is greater than 0;
when the vehicle track is determined to meet a first brake passing condition, determining that the target vehicle has passed brake.
Optionally, after determining whether the track frame number of the vehicle track is smaller than a preset frame number, the method further includes:
and if so, determining that the target vehicle is not braked.
Optionally, the method further includes:
when the vehicle track is determined not to meet the first passing brake condition, judging whether the vehicle track meets a second passing brake condition;
the second passing brake condition is as follows:
the length of the track displacement is more than 200 pixels, and the cosine value between the track direction and the preset direction is more than 0.5;
or the like, or, alternatively,
the length of the track displacement is more than 100 pixels, and the cosine value between the track direction and the preset direction is more than 0.9;
if the vehicle track is determined to meet the second brake passing condition, determining that the target vehicle passes the brake;
and if the vehicle track is determined not to meet the second brake passing condition, determining that the target vehicle is not braked.
Optionally, before the calculating the trajectory direction and the trajectory displacement of the target vehicle according to the vehicle trajectory, the method further includes:
and preprocessing the vehicle track to remove the vehicle track which does not meet the judgment standard.
Optionally, after the track direction and the track displacement of the target vehicle are calculated according to the vehicle track, before the determining whether the number of track frames of the vehicle track is less than a preset number of frames, the method further includes:
carrying out rating processing on the vehicle track;
judging whether the number of the lost frames of the vehicle track is smaller than a dynamic threshold value, wherein the dynamic threshold value is determined by the result of the rating processing;
the judging whether the track frame number of the vehicle track is smaller than a preset frame number comprises:
and if the number of the disappeared frames of the vehicle track is determined to be larger than the dynamic threshold, judging whether the track frame number of the vehicle track is smaller than a preset frame number.
The second aspect of the present application provides a vehicle brake-through determination system based on an image recognition technology, including:
the acquisition unit is used for acquiring a video of an entrance and an exit of the parking lot through a parking lot camera;
the extraction unit is used for extracting target images frame by frame in the parking lot entrance and exit videos;
the detection unit is used for detecting the vehicles and the license plates in the target image by adopting a target detection algorithm;
the identification unit is used for identifying the license plate information of the detected license plate in the target image;
the binding unit is used for binding the license plate information and the position relation between the vehicle and the license plate in the target image and determining the target vehicle according to the binding result;
a tracking unit for tracking the vehicle trajectory of the target vehicle using a tracking algorithm;
and the judging unit is used for judging whether the target vehicle passes through the brake according to the vehicle track.
Optionally, the determining unit includes:
the calculation module is used for calculating the track direction and the track displacement of the target vehicle according to the vehicle track, and the vehicle track is composed of the central points of vehicle detection frames in a plurality of frames of the target image;
the first judgment module is used for judging whether the track frame number of the vehicle track is smaller than a preset frame number or not;
the second judging module is used for judging whether the vehicle track meets a first brake passing condition or not when the judging result of the first judging module is negative;
the first pass-gate condition comprises:
the vehicle trajectory disappears from the lower boundary of the target image, the length of the trajectory displacement is greater than 100 pixels, and the cosine value between the trajectory direction and the preset direction is greater than 0;
and the first determination module is used for determining that the target vehicle has passed the brake when the second judgment module determines that the vehicle track meets a first brake passing condition.
Optionally, the system further comprises:
and the second determining module is used for determining that the target vehicle is not braked when the first judging module judges that the target vehicle is not braked.
Optionally, the determining unit further includes:
the third judging module is used for judging whether the vehicle track meets a second brake passing condition or not when the second judging module determines that the vehicle track does not meet the first brake passing condition;
the second passing brake condition is as follows:
the length of the track displacement is more than 200 pixels, and the cosine value between the track direction and the preset direction is more than 0.5;
or the like, or, alternatively,
the length of the track displacement is more than 100 pixels, and the cosine value between the track direction and the preset direction is more than 0.9;
the first determining module is further used for determining that the target vehicle passes through a brake when the judgment result of the third judging module is yes;
the second determining module is further used for determining that the target vehicle is not braked when the judgment result of the third judging module is negative.
Optionally, the determining unit further includes:
and the preprocessing module is used for preprocessing the vehicle track so as to remove the vehicle track which does not meet the judgment standard.
Optionally, the determining unit further includes:
the rating module is used for rating the vehicle track;
a fourth judging module, configured to judge whether a number of vanishing frames of the vehicle trajectory is smaller than a dynamic threshold, where the dynamic threshold is determined by a result of the rating processing;
the first judging module is specifically configured to:
and when the judgment result of the fourth judgment module is negative, judging whether the track frame number of the vehicle track is smaller than a preset frame number.
The third aspect of the present application provides a vehicle brake-through determination device based on an image recognition technology, the device comprising:
the device comprises a processor, a memory, an input and output unit and a bus;
the processor is connected with the memory, the input and output unit and the bus;
the memory stores a program, and the processor calls the program to execute the vehicle brake-off judging method based on the image recognition technology in any one of the first aspect and the first aspect.
A fourth aspect of the present application provides a computer-readable storage medium having a program stored thereon, where the program executes on a computer the method for determining vehicle passing brake based on image recognition technology, which is optional in any one of the first aspect and the first aspect.
According to the technical scheme, the method has the following advantages:
aiming at the problem that the current brake-passing judging method can not judge whether the object passing the brake is a motor vehicle or a non-motor vehicle, the invention can distinguish the category of the target through a target detection algorithm, for example, only detect the vehicle and the license plate of the motor vehicle, then bind the license plate and the vehicle and then track, thereby filtering the non-motor vehicle and some license-free vehicles.
The invention detects and tracks the driving track of the vehicle through the existing entrance and exit cameras of the parking lot, and comprehensively judges whether the vehicle passes through the barrier gate or leaves from other directions through the direction, displacement and the like of the driving track, thereby improving the accuracy of vehicle passing-gate judgment.
Drawings
In order to more clearly illustrate the technical solutions in the present application, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1 is a schematic flowchart of an embodiment of a vehicle passing brake determination method based on an image recognition technology provided in the present application;
FIG. 2 is a schematic flow chart illustrating another embodiment of a vehicle passing brake determination method based on image recognition technology according to the present application;
FIG. 3 is a schematic diagram of a vehicle track in the vehicle brake-passing determination method based on the image recognition technology provided in the present application;
FIG. 4 is a schematic structural diagram of an embodiment of a vehicle passing brake judging system based on an image recognition technology provided by the present application;
FIG. 5 is a schematic structural diagram of another embodiment of a vehicle passing brake judging system based on an image recognition technology provided by the present application;
fig. 6 is a schematic structural diagram of an embodiment of a vehicle passing brake determination device based on an image recognition technology provided in the present application.
Detailed Description
The application provides a vehicle brake-passing judgment method and a related device based on an image recognition technology, which are used for detecting and tracking a driving track of a vehicle by using a deep learning algorithm and judging brake-passing according to the driving track, so that the accuracy of vehicle brake-passing judgment is improved.
It should be noted that the vehicle passing brake judging method based on the image recognition technology provided by the present application may be applied to a terminal, and may also be applied to a server, for example, the terminal may be a fixed terminal such as a smart phone or a computer, a tablet computer, a smart television, a smart watch, a portable computer terminal, or a desktop computer. For convenience of explanation, the terminal is taken as an execution subject for illustration in the present application.
Referring to fig. 1, fig. 1 is a diagram illustrating an embodiment of a vehicle passing brake determination method based on an image recognition technology, where the method includes:
101. acquiring a video of an entrance and an exit of a parking lot through a parking lot camera;
the method and the device have the advantages that the existing entrance and exit cameras of the parking lot are combined with the deep learning algorithm to judge the vehicle passing brake, firstly, the terminal needs to acquire the field video shot by the parking lot cameras, and the parking lot cameras in the method and the device refer to the cameras installed at the entrance and exit (barrier) of the parking lot.
102. Extracting target images frame by frame in the video of the entrance and exit of the parking lot;
the terminal extracts target images frame by frame in the acquired video of the entrance and exit of the parking lot, and it should be noted that, in order to ensure the accuracy of subsequent detection and identification, the target images are color images with a resolution of at least 1920 × 1080.
103. Detecting the vehicles and the license plates in the target image by adopting a target detection algorithm;
and the terminal detects the vehicle and the license plate in the target image by adopting a target detection algorithm. Specifically, the target detection algorithm may adopt a mainstream SSD object detection algorithm. It should be noted that, in the detection process, the non-motor vehicle in the target image may be considered as a background and may not be detected, so the vehicle passing brake determination method provided by the present application may filter the non-motor vehicle.
104. Carrying out license plate information identification on the detected license plate in the target image;
and the terminal extracts the detected license plate part in the target image and identifies the license plate information. The processing of the license plate recognition portion includes license plate correction, license plate type judgment, license plate voting, multi-recognition filtering, and the like, and is not limited herein.
105. Binding the license plate information and the position relation between the vehicle and the license plate in the target image, and determining the target vehicle according to the binding result;
and the terminal completes the binding of the vehicle and the license plate according to the license plate information and the position relation of the vehicle and the license plate detected in the target image. Because the parking lot camera is usually installed at a height of 1-2 meters, a plurality of license plates and a plurality of vehicles can be shot in a picture, and the terminal can distribute and bind according to the position relation between the license plates and the vehicles. Specifically, the vehicle detection frame and the license plate detection frame mutually calculate IOU, then the IOU is used as a cost matrix, a Hungarian allocation algorithm is adopted, one license plate is matched with one vehicle, the license plate and the vehicle are bound according to a matching result, and the binding result is determined to be a target vehicle.
It should be noted that in the step of binding the vehicle and the license plate, if a plurality of frames of vehicles which are not matched with the license plate are processed as a unlicensed vehicle, the binding cannot be realized, and the subsequent passing brake judgment cannot be realized, so that the vehicle passing brake judgment method provided by the application can filter the unlicensed vehicle.
106. Tracking the vehicle track of the target vehicle by adopting a tracking algorithm;
and after the terminal determines the target vehicle, tracking the vehicle track of the target vehicle by adopting a tracking algorithm. Specifically, the target vehicle can be tracked by adopting a deep sort algorithm, the deep sort algorithm depends on target detection, and the IOU and CNN characteristics between vehicle detection frames in two frames of target images can be used for object association. When a track is associated with a vehicle detection frame in a plurality of consecutive frames (3 frames), it is considered that a new vehicle ID is generated. When a plurality of consecutive frames (30 frames) of the trajectory are not associated with the vehicle detection frame, the vehicle is considered to be disappeared.
107. And judging whether the target vehicle passes through the brake according to the vehicle track.
And the terminal performs brake-passing judgment according to the vehicle track of the target vehicle, wherein the vehicle track is composed of the central points of the vehicle detection frames corresponding to the target vehicle in a plurality of frames of target images.
It should be added that after tracking the vehicle trajectory, the terminal can also learn the traffic direction, i.e. learn a "regular" vehicle travel direction by the vehicle trajectory of the preceding vehicles (typically 10 vehicles). The traveling direction can assist in judging vehicle brake passing more accurately. Specifically, when the first vehicle is present, the "normal" vehicle travel direction is initialized to be from top to bottom, i.e., the direction vector (0, 1). After the subsequent vehicles pass through the brake, the terminal stores the track of the previous 10 vehicles during the brake passing, and then averages all the brake passing tracks of the previous 10 vehicles to obtain a 'conventional' vehicle traveling direction for assisting the judgment of the vehicle brake passing.
In the embodiment, aiming at the problem that the current brake-passing judging method cannot judge whether a brake-passing object is a motor vehicle or a non-motor vehicle, the type of the target can be distinguished through a target detection algorithm, only the vehicle and the license plate of the motor vehicle are detected, and then the license plate and the vehicle are bound and tracked, so that the non-motor vehicle and some unlicensed vehicles are filtered.
In the embodiment, the vehicle is detected and tracked by the existing entrance and exit cameras of the parking lot, and the direction, the displacement and the like of the driving track are comprehensively judged to judge whether the vehicle passes through the barrier or leaves from other directions, so that the accuracy of vehicle passing judgment is improved.
Referring to fig. 2 and 3, please refer to fig. 2 for a detailed description of a brake-passing determination process in the vehicle brake-passing determination method based on the image recognition technology, where fig. 2 is another embodiment of the vehicle brake-passing determination method based on the image recognition technology, and fig. 3 is a schematic view of a vehicle track in the vehicle brake-passing determination method based on the image recognition technology, and the method includes:
201. acquiring a video of an entrance and an exit of a parking lot through a parking lot camera;
202. extracting target images frame by frame in the video of the entrance and exit of the parking lot;
203. detecting the vehicles and the license plates in the target image by adopting a target detection algorithm;
204. carrying out license plate information identification on the detected license plate in the target image;
205. binding the license plate information and the position relation between the vehicle and the license plate in the target image, and determining the target vehicle according to the binding result;
206. tracking the vehicle track of the target vehicle by adopting a tracking algorithm;
steps 201 to 206 in this embodiment are similar to steps 101 to 106 in the previous embodiments, and are not described again here.
207. Preprocessing the vehicle track to remove the vehicle track which does not meet the judgment standard;
after the terminal obtains the vehicle track of the target vehicle, the terminal needs to perform corresponding preprocessing on the vehicle track, the purpose of the preprocessing step is to remove some tracks which do not meet the judgment standard in advance, for example, tracks with too short track frame number (less than 20 frames) or tracks with too short vanishing frame number (less than 6 frames), and the terminals of the tracks which do not meet the judgment standard are not judged.
208. Calculating the track direction and the track displacement of the target vehicle according to the vehicle track, wherein the vehicle track is composed of the central points of vehicle detection frames in a plurality of frames of the target image;
and after the terminal acquires the vehicle track meeting the judgment condition, calculating the track direction and the track displacement of the target vehicle according to the vehicle track. The vehicle trajectory provided in this embodiment is shown in fig. 3, the circle set is a vehicle travel trajectory (composed of center points of vehicle detection frames), and the start point and the end point are respectively composed of average values of 5 points at the beginning and 5 points at the end. The track displacement is a vector of which the starting point points to the end point, the other straight line is a conventional vehicle driving direction generated through the learning of the traffic flow direction, and the terminal can express whether the vehicle is close to the barrier gate or far away from the barrier gate by calculating a vector cosine value between the two.
209. Judging whether the track frame number of the vehicle track is smaller than a preset frame number, if not, executing a step 210, and if so, directly executing a step 213;
the terminal judges whether the track frame number of the vehicle track is smaller than a preset frame number, and the normal vehicle passing brake is about 5s, namely about 125 frames from the beginning to the disappearance of the visual field, so that the preset frame number can be set to about 40 frames to eliminate some false detection conditions.
When the terminal determines that the number of track frames is greater than the preset number of frames, step 210 is executed to enter a further judgment of the passing gate.
When the terminal determines that the track frame number is less than the preset frame number, which indicates that the track of the vehicle is very short and may be a background false detection, step 213 is executed to determine that the target vehicle is not in the brake, so as to perform the brake passing judgment of the next target vehicle.
210. Judging whether the vehicle track meets a first brake passing condition, if not, executing a step 211, and if so, directly executing a step 212;
and after the terminal determines that the track frame number of the vehicle track is greater than the preset frame number, judging a first brake passing condition. In step 210, the terminal needs to simultaneously determine 3 conditions, which are as follows:
1. the vehicle trajectory disappears from the lower boundary of the target image;
2. the length of the track displacement is more than 100 pixels;
3. the cosine value between the track direction and the preset direction is greater than 0.
When the terminal determines that the vehicle trajectory of the target vehicle satisfies the above three conditions at the same time, step 212 is executed to return the result that the target vehicle has passed through the brake. When any one of the above three conditions is not satisfied, step 211 is executed to determine a second pass-gate condition.
It should be noted that, when the vehicle trajectory disappears from the lower boundary of the image, the lower boundary of the vehicle detection frame of the latest 15 frames of trajectory may be counted, and whether more than 10 frames are close to the lower boundary of the target image is determined. The preset direction in the present embodiment refers to a "regular" vehicle traveling direction that the terminal learns from the vehicle trajectories of the first few vehicles (typically 10 vehicles). The traveling direction can assist in judging vehicle brake passing more accurately. Specifically, when the first vehicle is present, the "normal" vehicle travel direction is initialized to be from top to bottom, i.e., the direction vector (0, 1). After the subsequent vehicles pass through the brake, the terminal stores the track of the previous 10 vehicles during the brake passing, and then averages all the brake passing tracks of the previous 10 vehicles to obtain a 'conventional' vehicle traveling direction for assisting the judgment of the vehicle brake passing.
211. Judging whether the vehicle track meets a second brake passing condition, if so, executing a step 212, and if not, executing a step 213;
and when the terminal determines that the vehicle track does not meet the first passing brake condition, continuously judging whether the vehicle track meets a second passing brake condition. The second pass-gate condition is as follows:
1. the length of the track displacement is more than 200 pixels, and the cosine value between the track direction and the preset direction is more than 0.5;
or the like, or, alternatively,
2. the length of the track displacement is greater than 100 pixels and the cosine value between the track direction and the preset direction is greater than 0.9.
Where the second passing condition 1 may summarize a situation where the vehicle has traveled a relatively long distance, but the direction is not very positive, which may occur in some large trucks or T-junctions. The second passing brake condition 2 may summarize that the vehicle has traveled a shorter distance, but has a correct direction, which generally occurs during night driving, and because the night imaging is not good in the daytime, the vehicle is detected at a distance less well, which may result in a relatively short displacement of the vehicle track tracked by the terminal.
The supplementary judgment of the second passing condition 1 and the second passing condition 2 can be carried out on the vehicle passing under some special conditions, and when the terminal determines that the vehicle track does not meet the first passing condition but meets any one of the second passing conditions, the step 212 is executed to return the result that the target vehicle passes.
212. Determining that the target vehicle has passed through a brake;
when the terminal determines that the vehicle track of the target vehicle meets the first passing brake condition or does not meet the first passing brake condition but meets any one of the second passing brake conditions, the target vehicle can be determined to pass the brake. It should be noted that, after the terminal determines that the target vehicle has passed through the brake, the next brake determination of the target vehicle is performed, and the result of passing through the brake is returned only once for one vehicle track.
213. Determining that the target vehicle is not braked.
In step 209, when the terminal determines that the number of track frames of the vehicle track is less than the preset number of frames, which indicates that the vehicle track is very short and may be a background false detection, the terminal may directly return to the target vehicle and not pass the brake, so as to perform the brake passing judgment of the next target vehicle.
The other situation is that when the terminal determines that the track frame number of the vehicle track is greater than the preset frame number, but the vehicle track does not meet the first brake passing condition and also does not meet the second brake passing condition, the target vehicle is determined not to be braked.
In the embodiment, aiming at the problem that the current brake-passing judging method cannot judge whether a brake-passing object is a motor vehicle or a non-motor vehicle, the type of the target can be distinguished through a target detection algorithm, only the vehicle and the license plate of the motor vehicle are detected, and then the license plate and the vehicle are bound and tracked, so that the non-motor vehicle and some unlicensed vehicles are filtered.
The vehicle is detected and tracked through the existing entrance and exit cameras of the parking lot, the driving track of the vehicle is comprehensively judged through the direction, the displacement and the like of the driving track, whether the vehicle passes through a barrier gate or leaves from other directions is judged, multiple judgment conditions are contained in the judgment process, accurate judgment of vehicle passing-through is achieved, and the accuracy of vehicle passing-through judgment is improved.
The method has the advantages that when the Deepsort algorithm is used for tracking a target vehicle, the problem that the vehicle is blocked by pedestrians or the performance of a detector is poor can occur, so that the phenomenon of ID switching is easy to occur, namely the same vehicle can be considered as two vehicles at a previous time and a later time, and therefore the method also provides a process of dynamically grading the track of the vehicle, so that the situation that the vehicle is blocked for a short time by the algorithm is increased, and the robustness of the algorithm is enhanced.
The following describes the application of the dynamic rating method in the vehicle brake-through judging method in detail:
after calculating the track direction and the track displacement of the target vehicle in step 208, before determining whether the track frame number of the vehicle track is smaller than the preset frame number in step 209, the terminal performs track rating processing on the vehicle track, then adjusts the dynamic threshold according to the track rating result, then determines whether the vanishing frame number of the vehicle track is larger than the dynamic threshold, and executes step 209 and subsequent passing judgment when the vanishing frame number of the vehicle track is larger than the dynamic threshold, and if the vanishing frame number of the vehicle track is smaller than the dynamic threshold, directly returns the result of not passing the brake.
Specifically, the grades of the vehicle trajectory can be roughly classified into 3 types as follows:
level 1: if the vehicle trajectory frame number is less than 40 frames or the trajectory displacement is less than 40 pixels. The dynamic threshold is adjusted to 125 frames and the number of vanishing frames for the vehicle trajectory is changed to 126. The track of the type probably belongs to the track shielded by the front vehicle or the pedestrian, the threshold value is adjusted to be large, and a more loose disappearance condition is given to the track, so that the track can be continued after the front vehicle or the pedestrian walks.
And 2, stage: if the displacement length of the track is greater than 400 pixels, the cosine value between the track direction and the preset direction is greater than 0.9, and the area of the nearest 5 detection frames in the track tends to decrease (i.e. whether the detection frames of 5 frames have more than 3 detection frames which are 10% smaller than the area of the detection frame of the previous frame is counted). When these 3 conditions are simultaneously met, then the dynamic threshold is adjusted to 6. This type of trajectory is considered to be a relatively good trajectory, the distance traveled by the vehicle is long, and the direction is very close to the normal traveling direction, and also conforms to the rule that the detection frame is changed from large to small when the picture disappears. The pass-gate can be directly judged for such a trajectory.
And 3, level: when the vehicle trajectory fails to reach the level 1 and level 2 criteria, it is considered to be a general trajectory, where the dynamic threshold is adjusted to 50 and the number of vanishing frames for the trajectory is changed to 51. Such trajectories may be due to poor detector performance, and extending the number of vanishing frames may increase algorithm robustness.
Referring to fig. 4, fig. 4 is a diagram illustrating an embodiment of a vehicle passing brake determining system based on image recognition technology according to the present application, the system including:
an obtaining unit 401, configured to obtain a video of a train yard entrance and exit through a train yard camera;
an extracting unit 402, configured to extract target images frame by frame in the yard entrance/exit video;
a detection unit 403, configured to detect a vehicle and a license plate in the target image by using a target detection algorithm;
the recognition unit 404 is configured to perform license plate information recognition on the detected license plate in the target image;
a binding unit 405, configured to bind the license plate information and the position relationship between the vehicle and the license plate in the target image, and determine a target vehicle according to a binding result;
a tracking unit 406 for tracking a vehicle trajectory of the target vehicle using a tracking algorithm;
the judging unit 407 is configured to judge whether the target vehicle is braked according to the vehicle track.
In this embodiment, the detection unit 403 may distinguish the type of the target by a target detection algorithm, only detect the vehicle and the license plate of the motor vehicle, then bind the license plate with the vehicle by the binding unit 405, and then track by the tracking unit 406, thereby filtering the non-motor vehicle and some unlicensed vehicles.
The invention detects and tracks the running track of the vehicle through the existing entrance and exit cameras of the parking lot, and comprehensively judges whether the vehicle passes through the barrier gate or leaves from other directions through the direction, displacement and the like of the running track through the judging unit 407, thereby improving the accuracy of vehicle passing-gate judgment.
Referring to fig. 5, fig. 5 is a schematic diagram illustrating a vehicle passing brake determining system based on an image recognition technology according to another embodiment of the present invention, where the vehicle passing brake determining system based on an image recognition technology includes:
an obtaining unit 501, configured to obtain a video of an entrance and an exit of a train yard through a train yard camera;
an extracting unit 502, configured to extract target images frame by frame in the yard entrance/exit video;
a detection unit 503, configured to detect a vehicle and a license plate in the target image by using a target detection algorithm;
the recognition unit 504 is configured to perform license plate information recognition on the detected license plate in the target image;
a binding unit 505, configured to bind the license plate information and the position relationship between the vehicle and the license plate in the target image, and determine a target vehicle according to a binding result;
a tracking unit 506 for tracking a vehicle trajectory of the target vehicle using a tracking algorithm;
and a judging unit 507, configured to judge whether the target vehicle is braked according to the vehicle track.
Optionally, the determining unit 507 includes:
a calculating module 5071, configured to calculate a trajectory direction and a trajectory displacement of the target vehicle according to the vehicle trajectory, where the vehicle trajectory is composed of center points of vehicle detection frames in a plurality of frames of the target image;
a first judging module 5072, configured to judge whether a number of track frames of the vehicle track is less than a preset number of frames;
a second determination module 5073, configured to determine whether the vehicle trajectory meets a first passing brake condition when the determination result of the first determination module 5072 is negative;
the first pass-gate condition comprises:
the vehicle trajectory disappears from the lower boundary of the target image, the length of the trajectory displacement is greater than 100 pixels, and the cosine value between the trajectory direction and the preset direction is greater than 0;
a first determination module 5074, configured to determine that the target vehicle has passed brake when the second determination module 5073 determines that the vehicle trajectory satisfies a first passing brake condition.
Optionally, the system further comprises:
a second determination module 5075, configured to determine that the target vehicle is not braked when the determination result of the first determination module 5072 is yes.
Optionally, the determining unit 507 further includes:
a third determination module 5076, configured to determine whether the vehicle trajectory satisfies a second passing condition when the second determination module 5073 determines that the vehicle trajectory does not satisfy the first passing condition;
the second passing brake condition is as follows:
the length of the track displacement is more than 200 pixels, and the cosine value between the track direction and the preset direction is more than 0.5;
or the like, or, alternatively,
the length of the track displacement is more than 100 pixels, and the cosine value between the track direction and the preset direction is more than 0.9;
the first determination module 5074 is further configured to determine that the target vehicle has passed brake when the determination result of the third determination module 5076 is yes;
the second determination module 5075 is further configured to determine that the target vehicle is not braked when the determination result of the third determination module 5076 is negative.
Optionally, the determining unit 507 further includes:
a preprocessing module 5077, configured to preprocess the vehicle trajectory to remove vehicle trajectories that do not meet the determination criteria.
Optionally, the determining unit 507 further includes:
a rating module 5078 for rating the vehicle trajectory;
a fourth determination module 5079, configured to determine whether the number of lost frames of the vehicle trajectory is less than a dynamic threshold, where the dynamic threshold is determined by a result of the rating process;
the first determining module 5072 is specifically configured to:
when the judgment result of the fourth judgment module 5079 is negative, whether the number of track frames of the vehicle track is less than a preset number of frames is judged.
In the system of this embodiment, the functions of each unit correspond to the steps in the method embodiment shown in fig. 2, and are not described herein again.
Referring to fig. 6, fig. 6 is a diagram illustrating an embodiment of a vehicle passing brake determining device based on an image recognition technology, where the vehicle passing brake determining device based on an image recognition technology includes:
a processor 601, a memory 602, an input-output unit 603, a bus 604;
the processor 601 is connected with the memory 602, the input/output unit 603 and the bus 604;
the memory 602 stores a program, and the processor 601 calls the program to execute any one of the above-mentioned vehicle passing brake determination methods based on the image recognition technology.
The present application also relates to a computer-readable storage medium having a program stored thereon, wherein the program, when executed on a computer, causes the computer to execute any of the above-mentioned vehicle passing brake determination methods based on image recognition technology.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and the like.

Claims (10)

1. A vehicle brake-passing judgment method based on an image recognition technology is characterized by comprising the following steps:
acquiring a video of an entrance and an exit of a parking lot through a parking lot camera;
extracting target images frame by frame in the video of the entrance and exit of the parking lot;
detecting the vehicles and the license plates in the target image by adopting a target detection algorithm;
carrying out license plate information identification on the detected license plate in the target image;
binding the license plate information and the position relation between the vehicle and the license plate in the target image, and determining the target vehicle according to the binding result;
tracking the vehicle track of the target vehicle by adopting a tracking algorithm;
and judging whether the target vehicle passes through the brake according to the vehicle track.
2. The method of claim 1, wherein the determining whether the target vehicle is braked according to the vehicle trajectory comprises:
calculating the track direction and the track displacement of the target vehicle according to the vehicle track, wherein the vehicle track is composed of the central points of vehicle detection frames in a plurality of frames of the target image;
judging whether the track frame number of the vehicle track is smaller than a preset frame number or not;
if not, judging whether the vehicle track meets a first brake passing condition or not;
the first pass-gate condition comprises:
the vehicle trajectory disappears from the lower boundary of the target image, the length of the trajectory displacement is greater than 100 pixels, and the cosine value between the trajectory direction and the preset direction is greater than 0;
when the vehicle track is determined to meet a first brake passing condition, determining that the target vehicle has passed brake.
3. The method of claim 2, wherein after the determining whether the number of trajectory frames of the vehicle trajectory is less than a preset number of frames, the method further comprises:
and if so, determining that the target vehicle is not braked.
4. The method of claim 2, further comprising:
when the vehicle track is determined not to meet the first passing brake condition, judging whether the vehicle track meets a second passing brake condition;
the second passing brake condition is as follows:
the length of the track displacement is more than 200 pixels, and the cosine value between the track direction and the preset direction is more than 0.5;
or the like, or, alternatively,
the length of the track displacement is more than 100 pixels, and the cosine value between the track direction and the preset direction is more than 0.9;
if the vehicle track is determined to meet the second brake passing condition, determining that the target vehicle passes the brake;
and if the vehicle track is determined not to meet the second brake passing condition, determining that the target vehicle is not braked.
5. The method of claim 2, wherein prior to said calculating a trajectory direction and a trajectory displacement of said target vehicle from said vehicle trajectory, said method further comprises:
and preprocessing the vehicle track to remove the vehicle track which does not meet the judgment standard.
6. The method of claim 3, wherein after said calculating a trajectory direction and a trajectory displacement of said target vehicle from said vehicle trajectory, before said determining whether a number of trajectory frames of said vehicle trajectory is less than a preset number of frames, said method further comprises:
carrying out rating processing on the vehicle track;
judging whether the number of the lost frames of the vehicle track is smaller than a dynamic threshold value, wherein the dynamic threshold value is determined by the result of the rating processing;
the judging whether the track frame number of the vehicle track is smaller than a preset frame number comprises:
and if the number of the disappeared frames of the vehicle track is determined to be larger than the dynamic threshold, judging whether the track frame number of the vehicle track is smaller than a preset frame number.
7. A vehicle brake-passing judgment system based on an image recognition technology is characterized by comprising:
the acquisition unit is used for acquiring a video of an entrance and an exit of the parking lot through a parking lot camera;
the extraction unit is used for extracting target images frame by frame in the parking lot entrance and exit videos;
the detection unit is used for detecting the vehicles and the license plates in the target image by adopting a target detection algorithm;
the identification unit is used for identifying the license plate information of the detected license plate in the target image;
the binding unit is used for binding the license plate information and the position relation between the vehicle and the license plate in the target image and determining the target vehicle according to the binding result;
a tracking unit for tracking the vehicle trajectory of the target vehicle using a tracking algorithm;
and the judging unit is used for judging whether the target vehicle passes through the brake according to the vehicle track.
8. The system according to claim 7, wherein the judging unit includes:
the calculation module is used for calculating the track direction and the track displacement of the target vehicle according to the vehicle track, and the vehicle track is composed of the central points of vehicle detection frames in a plurality of frames of the target image;
the first judgment module is used for judging whether the track frame number of the vehicle track is smaller than a preset frame number or not;
the second judging module is used for judging whether the vehicle track meets a first brake passing condition or not when the judging result of the first judging module is negative;
the first pass-gate condition comprises:
the vehicle trajectory disappears from the lower boundary of the target image, the length of the trajectory displacement is greater than 100 pixels, and the cosine value between the trajectory direction and the preset direction is greater than 0;
and the first determination module is used for determining that the target vehicle has passed the brake when the second judgment module determines that the vehicle track meets a first brake passing condition.
9. A vehicle brake-passing judgment device based on an image recognition technology is characterized by comprising:
the device comprises a processor, a memory, an input and output unit and a bus;
the processor is connected with the memory, the input and output unit and the bus;
the memory holds a program that the processor calls to perform the method of any one of claims 1 to 6.
10. A computer-readable storage medium having a program stored thereon, the program, when executed on a computer, performing the method of any one of claims 1 to 6.
CN202111137496.3A 2021-09-27 2021-09-27 Vehicle brake-passing judgment method based on image recognition technology and related device Pending CN114037924A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111137496.3A CN114037924A (en) 2021-09-27 2021-09-27 Vehicle brake-passing judgment method based on image recognition technology and related device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111137496.3A CN114037924A (en) 2021-09-27 2021-09-27 Vehicle brake-passing judgment method based on image recognition technology and related device

Publications (1)

Publication Number Publication Date
CN114037924A true CN114037924A (en) 2022-02-11

Family

ID=80140635

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111137496.3A Pending CN114037924A (en) 2021-09-27 2021-09-27 Vehicle brake-passing judgment method based on image recognition technology and related device

Country Status (1)

Country Link
CN (1) CN114037924A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114581465A (en) * 2022-03-09 2022-06-03 深圳市捷顺科技实业股份有限公司 Parking space management and control method, device, equipment and storage medium
CN114677774A (en) * 2022-03-30 2022-06-28 深圳市捷顺科技实业股份有限公司 Barrier gate control method and related equipment
CN114792408A (en) * 2022-06-21 2022-07-26 浙江大华技术股份有限公司 Motor vehicle snapshot method, motor vehicle snapshot device and computer storage medium
CN114924477A (en) * 2022-05-26 2022-08-19 西南大学 Electric fish blocking and ship passing device based on image recognition and PID intelligent control
CN115294560A (en) * 2022-08-10 2022-11-04 青岛文达通科技股份有限公司 Vehicle tracking method and system based on attribute matching and motion trail prediction
CN115861974A (en) * 2023-02-24 2023-03-28 成都宜泊信息科技有限公司 Method and system for managing license-free vehicle passing in parking lot, electronic equipment and storage medium
CN117392585A (en) * 2023-10-24 2024-01-12 广州广电运通智能科技有限公司 Gate traffic detection method and device, electronic equipment and storage medium

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114581465A (en) * 2022-03-09 2022-06-03 深圳市捷顺科技实业股份有限公司 Parking space management and control method, device, equipment and storage medium
CN114677774A (en) * 2022-03-30 2022-06-28 深圳市捷顺科技实业股份有限公司 Barrier gate control method and related equipment
CN114677774B (en) * 2022-03-30 2023-10-17 深圳市捷顺科技实业股份有限公司 Barrier gate control method and related equipment
CN114924477A (en) * 2022-05-26 2022-08-19 西南大学 Electric fish blocking and ship passing device based on image recognition and PID intelligent control
CN114792408A (en) * 2022-06-21 2022-07-26 浙江大华技术股份有限公司 Motor vehicle snapshot method, motor vehicle snapshot device and computer storage medium
CN115294560A (en) * 2022-08-10 2022-11-04 青岛文达通科技股份有限公司 Vehicle tracking method and system based on attribute matching and motion trail prediction
CN115294560B (en) * 2022-08-10 2024-03-01 青岛文达通科技股份有限公司 Vehicle tracking method and system based on attribute matching and motion trail prediction
CN115861974A (en) * 2023-02-24 2023-03-28 成都宜泊信息科技有限公司 Method and system for managing license-free vehicle passing in parking lot, electronic equipment and storage medium
CN115861974B (en) * 2023-02-24 2023-05-09 成都宜泊信息科技有限公司 Parking lot license-free vehicle passing management method, system, electronic equipment and storage medium
CN117392585A (en) * 2023-10-24 2024-01-12 广州广电运通智能科技有限公司 Gate traffic detection method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
CN114037924A (en) Vehicle brake-passing judgment method based on image recognition technology and related device
CN106652465B (en) Method and system for identifying abnormal driving behaviors on road
US8682036B2 (en) System and method for street-parking-vehicle identification through license plate capturing
US10212397B2 (en) Abandoned object detection apparatus and method and system
CN111666853B (en) Real-time vehicle violation detection method, device, equipment and storage medium
KR100969995B1 (en) System of traffic conflict decision for signalized intersections using image processing technique
WO2016129403A1 (en) Object detection device
CN108389396B (en) Vehicle type matching method and device based on video and charging system
CN110532916B (en) Motion trail determination method and device
CN106373426A (en) Computer vision-based parking space and illegal lane occupying parking monitoring method
CN110738150B (en) Camera linkage snapshot method and device and computer storage medium
CN111145555B (en) Method and device for detecting vehicle violation
CN110032947B (en) Method and device for monitoring occurrence of event
CN111192461B (en) License plate recognition method, server, parking charging method and system
CN104574954A (en) Vehicle checking method and system based on free flow system as well as control equipment
CN110942038A (en) Traffic scene recognition method, device, medium and electronic equipment based on vision
CN115331191B (en) Vehicle type recognition method, device, system and storage medium
CN114155619A (en) Method, device, medium and system for automatically monitoring parking space
CN110880205B (en) Parking charging method and device
CN113920749A (en) Vehicle following identification method and system for parking lot and related device
CN112183206A (en) Traffic participant positioning method and system based on roadside monocular camera
CN110660225A (en) Red light running behavior detection method, device and equipment
CN116152753A (en) Vehicle information identification method and system, storage medium and electronic device
CN110782485A (en) Vehicle lane change detection method and device
CN113177509B (en) Method and device for recognizing backing behavior

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination