Vehicle illegal parking detection method and device
By matching the current vehicle information with stable vehicle information in vehicle illegal parking detection, and judging whether the vehicle is an illegally parked vehicle based on the counting threshold, the problem of unclear license plates caused by environmental factors is solved, and the accurate judgment of vehicle stay time is achieved. Missed detections and false detections are avoided.
Patent Information
- Application Number
- CN202111038967.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-06
- Publication Date
- 2024-10-15
- Estimated Expiration
- 2041-09-06
AI Technical Summary
Existing vehicle illegal parking detection relies on license plate recognition. Environmental factors make it impossible to determine the vehicle's parking time when the license plate is unclear, resulting in many problems of missed detection and false detection.
By matching the current vehicle information with stable vehicle information in the illegal parking monitoring area image, and judging whether the vehicle is an illegally parked vehicle based on the counting threshold, continuous tracking of vehicles and illegal parking judgment are achieved, avoiding reliance on license plate recognition.
It enhances the adaptability to different environmental conditions, effectively avoids missed and misdetected vehicles, and improves the accuracy of illegal parking detection.
Smart Images

Figure CN115841756B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of intelligent transportation technology, and in particular to a method and device for detecting illegal parking of vehicles. Background Art
[0002] The existing vehicle illegal parking detection is based on the illegal parking camera marking the license plate after recognition, and then taking another photo at a set interval to find the same license plate to detect the illegal parking of the vehicle.
[0003] Existing technical solutions rely on license plate recognition. In actual scenarios, due to factors such as the vehicle's direction, obstruction, light, weather, and distance, it is often impossible to capture a clear license plate. As a result, it is impossible to determine the vehicle's stay time. The illegal parking identification system gives up processing such vehicles, resulting in a large number of missed detections by the illegal parking system in actual scenarios.
[0004] Therefore, it is of great significance to propose a method that can match parked vehicles without relying on license plate recognition, has strong adaptability under different environmental conditions, and avoids missed detection and false detection. Summary of the invention
[0005] The present invention provides a vehicle illegal parking detection method and device to solve the technical problems that the existing vehicle illegal parking detection relies on the recognition of license plates, but in actual scenes, due to environmental factors and other factors, clear license plates are often unable to be captured, resulting in false detection and missed detection.
[0006] In a first aspect, the present invention provides a method for detecting illegal parking of a vehicle, comprising:
[0007] Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0008] In a case where the current vehicle information matches the stable vehicle information, counting the stable vehicle information;
[0009] When the count of the stable vehicle information reaches a first count threshold, determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0010] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0011] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0012] In one embodiment, it further includes:
[0013] Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the initial vehicle information;
[0014] In the case where the current vehicle information matches the initial vehicle information, the initial vehicle information is counted.
[0015] In one embodiment, it further includes:
[0016] In the case that the current vehicle information does not match the initial vehicle information, the current vehicle information is used as the initial vehicle information.
[0017] In one embodiment, the illegal parking monitoring area is determined by:
[0018] The monitoring area is outlined by picking up points in a polygon based on the online webpage, and the area outlined by picking up points is automatically closed and calculated to determine the illegal parking monitoring area.
[0019] In one embodiment, the vehicles in the illegal parking monitoring area image are determined in the following manner:
[0020] The monitoring area image is input into the vehicle detection model to obtain the vehicle detection frame, and the vehicle whose center point of the vehicle detection frame is within the illegal parking monitoring area is determined to be the vehicle in the illegal parking monitoring area image.
[0021] In one embodiment, it further includes:
[0022] In a case where the count of consecutive mismatches between the current vehicle information and the stable vehicle information is greater than a third count threshold, the stable vehicle information is determined as unstable vehicle information.
[0023] In one embodiment, after determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle, the method further includes:
[0024] Take a snapshot of the illegally parked vehicle, perform license plate number recognition based on the captured image, and obtain the license plate number of the illegally parked vehicle;
[0025] The illegal parking information of the illegally parked vehicle and the license plate number of the illegally parked vehicle are stored in the illegal parking alarm information list.
[0026] In a second aspect, the present invention further provides a vehicle illegal parking detection device, comprising:
[0027] A vehicle information matching module is used to match the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0028] a vehicle information counting module, configured to count the stable vehicle information when the current vehicle information matches the stable vehicle information;
[0029] an illegally parked vehicle determination module, configured to determine, when the count of the stable vehicle information reaches a first count threshold, a vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0030] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0031] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0032] In a third aspect, the present invention further provides an electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of any one of the above-mentioned vehicle illegal parking detection methods are implemented.
[0033] In a fourth aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which implements the steps of any of the above-mentioned vehicle illegal parking detection methods when the computer program is executed by a processor.
[0034] The vehicle illegal parking detection method, device, electronic device and storage medium provided by the present invention achieve continuous tracking of the vehicle by matching the current vehicle information of the vehicle in the illegal parking monitoring area image with the stable vehicle information and counting the successfully matched stable vehicle information. If it is determined through counting that the parking time of the vehicle in the illegal parking area exceeds a threshold, the vehicle is classified as an illegally parked vehicle. The illegal parking judgment of the vehicle is achieved through vehicle detection and tracking without relying on license plate number recognition, which enhances the adaptability to the actual scene environment and effectively avoids missed detection and false detection of vehicles. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0036] Figure 1 A schematic diagram of the process of the vehicle illegal parking detection method provided by the present invention;
[0037] Figure 2 A schematic diagram of the structure of the vehicle illegal parking detection device provided by the present invention;
[0038] Figure 3 This is a schematic structural diagram of an electronic device provided by the present invention. DETAILED DESCRIPTION
[0039] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0040] Figure 1 This is a flow chart of the vehicle illegal parking detection method provided by the present invention. Figure 1 The vehicle illegal parking detection method provided by the present invention may include:
[0041] S110, matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0042] S120, when the current vehicle information matches the stable vehicle information, counting the stable vehicle information;
[0043] S130, when the count of the stable vehicle information reaches a first count threshold, determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0044] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0045] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0046] The execution subject of the vehicle parking violation detection method provided by the present invention can be an electronic device, a component in an electronic device, an integrated circuit, or a chip. The electronic device can be a mobile electronic device or a non-mobile electronic device. Exemplarily, the mobile electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, an in-vehicle electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook or a personal digital assistant (PDA), etc., and the non-mobile electronic device can be a server, a network attached storage (NAS) or a personal computer (PC), etc., which is not specifically limited by the present invention.
[0047] The following takes the vehicle illegal parking detection method provided by the present invention executed by a computer as an example to explain the technical solution of the present invention in detail.
[0048] Specifically, in step S110, based on the monitoring area image, the vehicles in the illegal parking monitoring area in the monitoring area image are identified, the vehicle information of the vehicles in the illegal parking monitoring area is obtained, and the current vehicle information is matched with the stable vehicle information.
[0049] Optionally, the current vehicle information of the vehicle in the illegal parking monitoring area image can be obtained by obtaining the vehicle detection frame through the vehicle detection model of target recognition, and assigning an ID to the detected vehicle. The vehicle ID, the current vehicle position and the vehicle feature map are used as the current vehicle information.
[0050] It is understandable that the illegal parking monitoring area image can be obtained by the monitoring image acquisition device. Among them, the monitoring images acquired by the monitoring image acquisition device do not necessarily all belong to the illegal parking monitoring area image. After the monitoring image is acquired by the monitoring image acquisition device, the illegal parking monitoring area in the monitoring image area is acquired according to the pre-defined illegal parking monitoring area.
[0051] In step S120, the current vehicle information is matched with the stable vehicle information. If the match is successful, the stable vehicle information is counted.
[0052] It is understandable that if the current vehicle information matches the stable vehicle information, it means that the current vehicle and the stable vehicle are the same vehicle. By counting the stable vehicle information, the time that the vehicle stays in the illegal parking monitoring area can be recorded.
[0053] Optionally, after obtaining the current vehicle in the illegal parking monitoring area, feature extraction can be performed on the current vehicle to obtain feature information of the current vehicle. At the same time, feature information of the stable vehicle is obtained based on the stable vehicle information. Based on the feature information of the current vehicle and the feature information of the stable vehicle, it is determined whether the current vehicle and the vehicle in the stable vehicle information are the same vehicle.
[0054] In step S130, when the count of the stable vehicle information reaches a first count threshold, the vehicle corresponding to the stable vehicle information is determined as an illegally parked vehicle.
[0055] It is understandable that the first counting threshold can be set according to the illegal parking determination time. If the count of the stable vehicle information after matching reaches the first counting threshold, it can be said that the stable vehicle's stay time in the illegal parking monitoring area exceeds the illegal parking determination time, and the vehicle can be determined to be an illegally parked vehicle. At the same time, by adjusting the first counting threshold, it can adapt to different illegal parking scenarios, from temporary parking of no more than a few seconds to tens of minutes, to avoid misjudgment of passing vehicles, and can effectively identify the change of parking spots in larger parking areas and movement in parking areas.
[0056] Among them, the stable vehicle information is determined based on the initial vehicle information when the count of the initial vehicle information reaches the second count threshold; the initial vehicle information is the information of the vehicle that appears in the illegal parking monitoring area image for the first time.
[0057] It is understandable that if the count of the initial vehicle information reaches the second count threshold, it means that the initial vehicle has been stably present in the illegal parking monitoring area for a period of time, and the initial vehicle can be determined to be a stable vehicle in the illegal parking monitoring area.
[0058] The vehicle illegal parking detection method provided by the present invention achieves continuous tracking of the vehicle by matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information, and counting the successfully matched stable vehicle information. If it is determined through counting that the parking time of the vehicle in the illegal parking area exceeds a threshold, the vehicle is classified as an illegally parked vehicle. The illegal parking judgment of the vehicle is achieved through vehicle detection and tracking without relying on license plate number recognition, which enhances the adaptability to the actual scene environment and effectively avoids missed detection and false detection of vehicles.
[0059] In one embodiment, the current vehicle information of the vehicle in the current illegal parking monitoring area image is matched with the initial vehicle information; in a case where the current vehicle information matches the initial vehicle information, the initial vehicle information is counted.
[0060] It is understandable that if the current vehicle information can be successfully matched with the initial vehicle information, it means that the current vehicle and the initial vehicle are the same vehicle. By counting the initial vehicle information, the time the vehicle continues to stay in the illegal parking monitoring area can be recorded.
[0061] Optionally, feature extraction may be performed on the current vehicle to obtain feature information of the current vehicle. At the same time, feature information of the initial vehicle is obtained according to the initial vehicle information. Based on the feature information of the current vehicle and the feature information of the initial vehicle, it is determined whether the current vehicle and the vehicle in the initial vehicle information are the same vehicle.
[0062] The vehicle illegal parking detection method provided by the present invention matches the current vehicle information of the vehicle in the current illegal parking monitoring area image with the initial vehicle information, and counts the initial vehicle information according to the matching result, thereby determining that the current vehicle is a stable vehicle based on the count, realizing continuous tracking of the vehicle, and providing a basis for determining the illegal parking vehicles in the subsequent illegal parking monitoring area.
[0063] In one embodiment, when the current vehicle information does not match the initial vehicle information, the current vehicle information is used as the initial vehicle information.
[0064] It is understandable that if the current vehicle information does not match the initial vehicle information, it means that the current vehicle is the first vehicle to appear in the illegal parking monitoring area image. Therefore, the current vehicle information is used as the initial vehicle information to continue the subsequent detection.
[0065] The vehicle illegal parking detection method provided by the present invention determines that when the current vehicle information does not match the initial vehicle information, the current vehicle information is used as the initial vehicle information to determine that the current vehicle is the vehicle that appears for the first time in the illegal parking monitoring area image, thereby realizing a cyclic judgment of whether the vehicle in the illegal parking monitoring area is an illegally parked vehicle.
[0066] In one embodiment, the illegal parking monitoring area is determined in the following manner: polygonal point picking is performed on the monitoring area based on an online webpage, and the area picked by the points is automatically closed and calculated to determine the illegal parking monitoring area.
[0067] Specifically, the images acquired by the monitoring collection device can be provided to the user in the form of an online web page. The user draws the irregular area by picking up polygon points based on the online web page, and finally performs automatic closing calculation to determine the illegal parking monitoring area.
[0068] Optionally, the illegal parking monitoring area can be set to a polygonal area of various shapes according to actual needs, including convex polygons, concave polygons, polygons with holes, etc.
[0069] The vehicle illegal parking detection method provided by the present invention performs polygonal point picking to outline the monitoring area based on an online web page, automatically closes the area outlined by the picked points and calculates to determine the illegal parking monitoring area, making the setting of the illegal parking monitoring area more flexible and convenient.
[0070] In one embodiment, the vehicle in the illegal parking monitoring area image is determined in the following manner: the monitoring area image is input into a vehicle detection model to obtain a vehicle detection frame, and the vehicle whose center point of the vehicle detection frame is within the illegal parking monitoring area is determined as the vehicle in the illegal parking monitoring area image.
[0071] Optionally, to determine whether the target center point is within the polygonal parking violation monitoring area, the ray method can be used. Draw a ray from the center point as the origin, and calculate the number of intersections between the ray and the polygonal parking violation monitoring area. If the number of intersections is an odd number, the center point is within the polygonal parking violation monitoring area; if the number of intersections is an even number, the center point is not within the polygonal parking violation monitoring area.
[0072] The vehicle illegal parking detection method provided by the present invention provides a basis for determining the illegal parking vehicles in the subsequent illegal parking monitoring area by determining that the vehicle whose center point is within the illegal parking monitoring area is the vehicle in the illegal parking monitoring area image.
[0073] In one embodiment, when the count of consecutive mismatches between the current vehicle information and the stable vehicle information is greater than a third count threshold, the stable vehicle information is determined to be unstable vehicle information.
[0074] It is understandable that if the current vehicle information does not match the stable vehicle information, it is possible that the subsequent vehicle is lost, the subsequent vehicle may have left the illegal parking monitoring area, or the vehicle target may be obscured, resulting in missed detection due to factors such as weather and light. Therefore, the third counting threshold can be set to check whether there is a continuous mismatch between the current vehicle information and the stable vehicle information. If the count of continuous mismatches is greater than the third counting threshold, it means that the subsequent vehicle has left the illegal parking monitoring area. If a mismatch occurs, but the count of continuous mismatches is less than the third counting threshold, it means that missed detection may be caused by environmental factors or the subsequent vehicle being obscured.
[0075] The vehicle illegal parking detection method provided by the present invention sets a third counting threshold to check whether the current vehicle information and the stable vehicle information are continuously mismatched. By judging the continuous mismatch count of the vehicle and the third counting threshold, it is determined whether the vehicle has left the illegal parking monitoring area or has been missed due to environmental factors or occlusion. Continuous tracking of the vehicle is achieved, the adaptability to the actual scene environment is enhanced, and missed detection and false detection of the vehicle are effectively avoided.
[0076] In one embodiment, after determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle, it also includes: taking a snapshot of the illegally parked vehicle, identifying the license plate number based on the captured image, and obtaining the license plate number of the illegally parked vehicle; storing the illegal parking information of the illegally parked vehicle and the license plate number of the illegally parked vehicle in an illegal parking alarm information list.
[0077] Specifically, after determining that the vehicle is an illegally parked vehicle, the license plate number and illegal parking information of the illegally parked vehicle are obtained, and the illegal parking information is returned to the video surveillance platform. The relevant management personnel can be notified to conduct review and on-site intervention, or the traffic management platform and other systems can be connected to directly obtain the owner's contact information, and the owner can be notified by phone or text message to handle the illegal parking.
[0078] Optionally, after determining the illegally parked vehicle, the illegally parked vehicle can be captured to generate a structured captured image. The illegal parking information of the illegally parked vehicle, such as the timestamp of the capture, the target ID, the vehicle type, and the length of stay, can be marked. At the same time, the image of the illegally parked vehicle can be captured, and the image can be subjected to license plate detection to determine whether a valid license plate can be detected. If it can, the license plate area image is sent to the license plate recognition network for license plate number recognition. The validity of the recognized license plate number is checked, and a valid license plate number is provided for the corresponding illegally parked vehicle.
[0079] The vehicle illegal parking detection method provided by the present invention determines the illegally parked vehicles in the illegal parking monitoring area, obtains the license plate number of the illegally parked vehicle and the illegal parking information of the illegally parked vehicle, and realizes the identification and management of the illegally parked vehicles in the illegal parking monitoring area.
[0080] The following uses a vehicle parking violation detection method provided by the present invention as an example to illustrate the technical solution provided by the present invention:
[0081] First, the yolov5 network model is used to detect vehicles in the monitoring area. The vehicle detection model is obtained by training the yolov5 network model with data of various motor vehicle types. Collect vehicle data sets, and organize a batch of more than 50,000 picture data for common vehicle types such as cars, buses, and trucks as input for model training. The scenes of the picture data should include monitoring roads in time periods and weather such as early morning, noon, evening, night, rainy days, and snowy days. At the same time, the traffic flow in the shooting scene should include lanes under different traffic conditions such as smooth and congested. The shooting angle is a bird's-eye view, the angle is fixed, and the corresponding illegal parking area is also fixed in the field of view. For the illegal parking behavior detection test video, there needs to be a segment where the vehicle stops and waits for more than 5 seconds. After the vehicle data set is input into the vehicle detection model obtained after training, the vehicle detection frame is output.
[0082] For illegal parking monitoring areas, you can customize irregular polygonal illegal parking monitoring areas, including convex polygons, concave polygons, and polygons with holes. The criterion for judging whether a vehicle enters the illegal parking monitoring area is that the center point of the vehicle detection frame output by the monitoring field of view image detected by the vehicle detection model enters the illegal parking monitoring area. The illegal parking monitoring area is delineated based on polygon point picking on the online web page, and finally an automatic closing calculation is performed to determine the illegal parking monitoring area. To determine whether the center point of the vehicle detection frame is within the illegal parking monitoring area, the ray method can be used. Specifically, a ray is drawn from the center point of the vehicle detection frame, and the number of intersections between the ray and the polygonal area is calculated. If the number of intersections is an odd number, the center point is within the polygon; if the number of intersections is an even number, the center point is not within the polygon.
[0083] All vehicles in the illegal parking monitoring area are detected and assigned IDs through the above-trained vehicle detection model. An initial list is generated, and the location and feature map of the vehicle with the corresponding ID are saved in the initial list. After obtaining all vehicles in the illegal parking monitoring area, the current illegal parking monitoring area image frame is subjected to vehicle detection frame by frame and the obtained initial vehicle object is compared with the initial list.
[0084] If the detection frame of the current initial vehicle is in the illegal parking area and the initial vehicle information can be matched with the information of the corresponding vehicle in the initial list, that is, the current initial vehicle position and feature map information can be matched with the position and feature map information of the corresponding vehicle stored in the initial list. Then add 1 to the matching count of the corresponding initial vehicle ID. When the matching count reaches the counting threshold, such as 5, the initial vehicle ID can be added to the stable trajectory list. Add the initial timestamp T and the length of stay count of the initial vehicle in the illegal parking area to the stable trajectory list, and add the feature map information of the initial vehicle.
[0085] Next, follow the above steps to match the detection objects of subsequent frames with the initial list and the stable trajectory list in turn. If the detection object of the current frame is in the illegal parking area, it is first matched with the target in the stable trajectory. If the match is successful, the length of stay is increased by 1. Otherwise, match with the initial list. If it can be matched and the match count reaches the count threshold, such as 5, the current detection object can be added to the stable trajectory list. At the same time, by adjusting the count threshold, the noise trajectory caused by misidentification can be reduced, and the interference to passing vehicles can also be controlled. If the new detection target cannot find a matching target, a new ID is assigned to the detection box and it is added to the initial list.
[0086] If no matching target is found in the current frame for the vehicle with a stable trajectory, it is possible that the target vehicle is lost. The target vehicle may have left the monitoring field of view, or it may be blocked and missed due to factors such as weather and lighting. At this time, it is necessary to look back to see if the current target vehicle trajectory has a continuous mismatch with the stable trajectory list. If there is no mismatch between the target vehicle information and the vehicle information in the stable trajectory list, the mismatch count value is set and the mismatch count threshold is initialized to 1. If the target vehicle information does not match the vehicle information in the stable trajectory list, the mismatch count value is increased by 1 and compared with the mismatch count threshold. If the continuous mismatch count value is greater than the mismatch count threshold, it means that the trajectory has ended and the target vehicle needs to be deleted from the stable trajectory list. This strategy can reduce the situation where ID switching occurs due to interruption of tracking trajectory caused by missed detection of targets in a few frames.
[0087] In the process of matching the vehicles in the image frames of the current illegal parking monitoring area frame by frame, for all trajectories, when it is found that the target stay time is greater than the illegal parking threshold, the target vehicle is added to the illegal parking alarm information list. The time when the target vehicle enters the illegal parking area, the target ID, vehicle type, license plate number, stay time, stay location and the time of leaving are recorded, and three attribute structured images of entry, stay and leaving are generated. This information is returned to the video monitoring platform, and the relevant management personnel can be notified for review and on-site intervention. It can also be connected to the traffic management platform and other systems to directly obtain the contact information of the car owner, and notify the car owner by phone or text message to handle the illegal parking.
[0088] Among them, license plate capture and recognition is aimed at the trajectory that exceeds the parking threshold in the illegal parking area. The detection frame screenshot of the vehicle is extracted from the trajectory, the license plate detection is performed, the parameters are set, and it is determined whether a valid license plate can be detected. If a valid license plate can be detected, the detected license plate area is then sent to the license plate recognition network for license plate number recognition. The validity of the recognized license plate number is checked, and a valid license plate number is finally provided for each trajectory.
[0089] The matching method between the current vehicle information and the initial list and the stable trajectory list can be based on feature map distance calculation. The deep convolutional network is used to extract features from the vehicle information. The deep convolutional network model is a vehicle re-identification model trained with large-scale vehicle re-identification data. Images of the same vehicle under different angles, directions, lighting, occlusion, weather and other conditions are collected, and the vehicle re-identification model is obtained after training with vehicle re-identification data sets such as VeRi-776 and VERI-Wild, so as to realize the judgment of whether the current vehicle is the same as the vehicle in the initial list, and whether the current vehicle is the same as the vehicle in the stable trajectory list. This can effectively reduce the switching of target IDs during target tracking and reduce the cases of missed detections, false detections, and repeated alarms in illegal parking discrimination.
[0090] During the process of tracking the target vehicle, the image coordinates can be converted to actual coordinates through camera calibration to detect the real-time speed of the vehicle, which is used to record the parking timestamp and restart timestamp of the vehicle. At the same time, in order to facilitate viewing of information, the detection frame of the vehicle before it is judged as an illegally parked vehicle can be set to green, and the detection frame can be set to red after the illegal parking time threshold is reached. At the same time, the type, ID and number of frames of the vehicle are marked in the detection frame. In addition, for illegally parked vehicles with valid license plates that can be identified, the license plate number is marked, and the ID and timestamp of the illegally parked vehicle are marked in the upper left corner of the image.
[0091] The present invention also provides a vehicle illegal parking detection device, which can correspond to the vehicle illegal parking detection method described above.
[0092] Figure 2 The schematic diagram of the structure of the vehicle parking violation detection device provided by the present invention is as follows: Figure 2 As shown, the device comprises:
[0093] The vehicle information matching module 210 is used to match the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0094] The vehicle information counting module 220 is used to count the stable vehicle information when the current vehicle information matches the stable vehicle information;
[0095] An illegally parked vehicle determination module 230, configured to determine, when the count of the stable vehicle information reaches a first count threshold, the vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0096] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0097] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0098] The vehicle illegal parking detection device provided by the present invention achieves continuous tracking of the vehicle by matching the current vehicle information of the vehicle in the illegal parking monitoring area image with the stable vehicle information and counting the successfully matched stable vehicle information. If it is determined through counting that the parking time of the vehicle in the illegal parking area exceeds a threshold, the vehicle is classified as an illegally parked vehicle. The illegal parking judgment of the vehicle is achieved through vehicle detection and tracking without relying on license plate number recognition, which enhances the adaptability to the actual scene environment and effectively avoids missed detection and false detection of vehicles.
[0099] In one embodiment, the vehicle information matching module 210 is specifically used for:
[0100] Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the initial vehicle information;
[0101] In the case where the current vehicle information matches the initial vehicle information, the initial vehicle information is counted.
[0102] In one embodiment, the vehicle information matching module 210 is further specifically used for:
[0103] In the case that the current vehicle information does not match the initial vehicle information, the current vehicle information is used as the initial vehicle information.
[0104] In one embodiment, the vehicle information matching module 210 is further specifically used for:
[0105] The monitoring area is outlined by picking up points in a polygon based on the online webpage, and the area outlined by picking up points is automatically closed and calculated to determine the illegal parking monitoring area.
[0106] In one embodiment, the initial vehicle acquisition module 210 is further specifically configured to:
[0107] The monitoring area image is input into the vehicle detection model to obtain the vehicle detection frame, and the vehicle whose center point of the vehicle detection frame is within the illegal parking monitoring area is determined to be the vehicle in the illegal parking monitoring area image.
[0108] In one embodiment, the vehicle information counting module 220 is specifically used for:
[0109] In a case where the count of consecutive mismatches between the current vehicle information and the stable vehicle information is greater than a third count threshold, the stable vehicle information is determined as unstable vehicle information.
[0110] In one embodiment, the illegally parked vehicle determination module 230 is specifically used to:
[0111] After the vehicle corresponding to the stable vehicle information is determined as an illegally parked vehicle, the following steps are also included:
[0112] Take a snapshot of the illegally parked vehicle, perform license plate number recognition based on the captured image, and obtain the license plate number of the illegally parked vehicle;
[0113] The illegal parking information of the illegally parked vehicle and the license plate number of the illegally parked vehicle are stored in the illegal parking alarm information list.
[0114] The present invention also provides an electronic device, such as Figure 3 As shown, the electronic device may include: a processor 310, a communication interface 320, a memory 330 and a communication bus 340, wherein the processor 310, the communication interface 320 and the memory 330 communicate with each other through the communication bus 340. The processor 310 may call the logic instructions in the memory 330 to execute the steps of the vehicle parking violation detection method, for example including:
[0115] Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0116] In a case where the current vehicle information matches the stable vehicle information, counting the stable vehicle information;
[0117] When the count of the stable vehicle information reaches a first count threshold, determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0118] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0119] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0120] In addition, the logic instructions in the above-mentioned memory 330 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0121] On the other hand, the present invention further provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions, when the program instructions are executed by a computer, the computer can perform the steps of the vehicle parking violation detection method provided by the above-mentioned method embodiments, for example, including:
[0122] Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0123] In a case where the current vehicle information matches the stable vehicle information, counting the stable vehicle information;
[0124] When the count of the stable vehicle information reaches a first count threshold, determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0125] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0126] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0127] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the vehicle parking violation detection method provided by the above-mentioned method embodiments are implemented, for example, including:
[0128] Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information;
[0129] In a case where the current vehicle information matches the stable vehicle information, counting the stable vehicle information;
[0130] When the count of the stable vehicle information reaches a first count threshold, determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle;
[0131] Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold;
[0132] The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image.
[0133] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0134] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0135] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A vehicle illegal parking detection method, characterized in that: include: Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information; In a case where the current vehicle information matches the stable vehicle information, counting the stable vehicle information; When the count of the stable vehicle information reaches a first count threshold, determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle; Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold; The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image; Also includes: Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the initial vehicle information; In the case where the current vehicle information matches the initial vehicle information, counting the initial vehicle information; In the case that the current vehicle information does not match the initial vehicle information, the current vehicle information is used as the initial vehicle information.
2. The vehicle illegal parking detection method according to claim 1, characterized in that: The illegal parking monitoring area is determined in the following manner: The monitoring area is outlined by picking up points in a polygon based on an online webpage, and the area outlined by picking up points is automatically closed and calculated to determine the illegal parking monitoring area.
3. The vehicle illegal parking detection method according to claim 1, characterized in that: The vehicles in the illegal parking monitoring area image are determined in the following manner: The monitoring area image is input into the vehicle detection model to obtain a vehicle detection frame, and the vehicle whose center point of the vehicle detection frame is within the illegal parking monitoring area is determined to be the vehicle in the illegal parking monitoring area image.
4. The vehicle illegal parking detection method according to claim 1, characterized in that: Also includes: In a case where the count of consecutive mismatches between the current vehicle information and the stable vehicle information is greater than a third count threshold, the stable vehicle information is determined as unstable vehicle information.
5. The vehicle illegal parking detection method according to claim 1, characterized in that: After determining the vehicle corresponding to the stable vehicle information as an illegally parked vehicle, the method further includes: Taking a snapshot of the illegally parked vehicle, performing license plate number recognition based on the captured image, and obtaining the license plate number of the illegally parked vehicle; The illegal parking information of the illegally parked vehicle and the license plate number of the illegally parked vehicle are stored in an illegal parking alarm information list.
6. A vehicle illegal parking detection device, characterized in that: include: A vehicle information matching module is used to match the current vehicle information of the vehicle in the current illegal parking monitoring area image with the stable vehicle information; a vehicle information counting module, configured to count the stable vehicle information when the current vehicle information matches the stable vehicle information; an illegally parked vehicle determination module, configured to determine, when the count of the stable vehicle information reaches a first count threshold, a vehicle corresponding to the stable vehicle information as an illegally parked vehicle; Wherein, the stable vehicle information is determined according to the initial vehicle information when the count of the initial vehicle information reaches a second count threshold; The initial vehicle information is the information of the vehicle that first appears in the illegal parking monitoring area image; Also includes: Matching the current vehicle information of the vehicle in the current illegal parking monitoring area image with the initial vehicle information; In the case where the current vehicle information matches the initial vehicle information, counting the initial vehicle information; In the case that the current vehicle information does not match the initial vehicle information, the current vehicle information is used as the initial vehicle information.
7. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the vehicle illegal parking detection method as described in any one of claims 1 to 5 are implemented.
8. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the vehicle illegal parking detection method as described in any one of claims 1 to 5 are implemented.
