CN105740797A - Image processing based abnormal vehicle detection method - Google Patents

Image processing based abnormal vehicle detection method Download PDF

Info

Publication number
CN105740797A
CN105740797A CN201610053976.4A CN201610053976A CN105740797A CN 105740797 A CN105740797 A CN 105740797A CN 201610053976 A CN201610053976 A CN 201610053976A CN 105740797 A CN105740797 A CN 105740797A
Authority
CN
China
Prior art keywords
vehicle
image
target
search
particle
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
CN201610053976.4A
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.)
Dalian Roiland Technology Co Ltd
Original Assignee
Dalian Roiland Technology 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 Dalian Roiland Technology Co Ltd filed Critical Dalian Roiland Technology Co Ltd
Priority to CN201610053976.4A priority Critical patent/CN105740797A/en
Publication of CN105740797A publication Critical patent/CN105740797A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • G06V20/56Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V2201/00Indexing scheme relating to image or video recognition or understanding
    • G06V2201/08Detecting or categorising vehicles

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • Traffic Control Systems (AREA)
  • Image Analysis (AREA)

Abstract

The invention relates to an image processing based abnormal vehicle detection method. The method comprises the following steps of identifying a target region containing a target vehicle through template matching of a shot vehicle image of a current vehicle; performing particle filtering on the target region to obtain the position of the target vehicle in the current image; performing perspective transformation on the current image to obtain a distance between the target vehicle in the current image and the current vehicle; connecting the position of the target vehicle in the current image with the position of the target vehicle in a previous frame of image to obtain a motion track of the target vehicle; and according to the motion track of the target vehicle and the distance between the target vehicle and the current vehicle, judging out an abnormal vehicle. According to the method, vehicles around the current vehicle are tracked and detected based on an image processing technology to discover an exception in time and perform prewarning or handling, thereby effectively reducing the occurrence probability of an accident of the current vehicle caused by accidental driving of other vehicles.

Description

A kind of detection method of the abnormal vehicle based on image procossing
Technical field
The present invention relates to the detection method of a kind of abnormal vehicle, the detection method of specifically a kind of other vehicle abnormalities based on image procossing.
Background technology
For in vehicle accident of today; having quite a few is that the faulty drive of non-car causes; but owing to the faulty operation of other vehicles brings unnecessary loss and life danger to this car; how to avoid the vehicle accident of this part; the safety of lives and properties of protection occupant, is also a link paying much attention to of car manufactures.
Automatic target recognition technology is the image utilizing imaging system to come in, automatically extract target and identify, current Motion parameters algorithm has the statistical pattern recognition method of classics, Knowledge based engineering automatic target recognition method, automatic target recognition method based on model, based on the automatic target recognition method of multi-sensor information fusion, the automatic target recognition method of Corpus--based Method study, motion estimate method.And target following technology can be divided into the tracking based on masterplate, the tracking based on region, the tracking based on profile, the tracking of feature based coupling and based on the tracking of kinetic characteristic.
It is currently based on automatically identifying of image to have developed for many years with tracking technique, vehicle traffic accident prevention has also had multinomial measure, these exceptions and preventive measure design for the driver of this car mostly, but do not detect other vehicles, detecting in real time and judging whether abnormal invention currently without other vehicles based on image, the present invention has certain practical significance, it may have certain theoretical basis.
Summary of the invention
For above-mentioned technical deficiency, it is an object of the invention to provide the detection method of a kind of abnormal vehicle based on image procossing.
The technical solution adopted for the present invention to solve the technical problems is: the detection method of a kind of abnormal vehicle based on image procossing, comprises the following steps:
The vehicle image that this car is shot contains the target area of target vehicle by stencil matching identification:
Target area is carried out particle filter and obtains target vehicle position in present image;
Present image is carried out perspective transform and obtains the distance of target vehicle and this car in present image;Connect the position of target vehicle in the position of target vehicle in present image and previous frame image and obtain the movement locus of target vehicle;
Movement locus according to target vehicle and go out abnormal vehicle with the Distance Judgment of this car.
The target area that the described vehicle image that this car is shot contains target vehicle by stencil matching identification comprises the following steps:
Respectively the various vehicle images all around shot from this car are formed preset template;
The original vehicle image of the four direction of this car Real-time Collection is carried out difference operation with the template of correspondence direction respectively:
D ( x , y ) = Σ x ′ Σ y ′ [ T ( x ′ , y ′ ) - F ( x ′ + x , y ′ + y ) ] 2
D (x, y) estimates for difference, (and x, y) for the coordinate of vehicle image, T () is masterplate, and F () is target vehicle, (x ', y ') it is the point in the coordinate system of preset template image;
Choosing difference in the picture less than the region of threshold value is the target area containing target vehicle.
Described particle filter that target area is carried out obtains target vehicle position in present image and comprises the following steps:
1) RGB of target area in vehicle image is converted to the h space in HSV, is rectangular histogram using h space transforming as target feature vector V;
2) adopt Gauss distribution that the search particle with target area same size is set, present image scans for obtaining the similarity of the histogram vectors Vi and target feature vector V of all search particles;
3) Similarity-Weighted that each search particle is obtained obtains the position of target area.
The h space that the described RGB by original vehicle objective area in image is converted in HSV is realized by below equation:
Wherein, R, G, B are the information in the rgb space of original image, and max is the maximum in RGB, and min is the minima in RGB.
Described employing Gauss distribution arranges the search particle with target area same size particularly as follows: arrange the 80% of total search particle in original image within the scope of the several times of target area, and all the other 20% search particles are placed in the region beyond several times scope.
The described similarity that present image scans for obtaining the histogram vectors Vi and target feature vector V of all search particles comprises the following steps:
Calculate the h rectangular histogram of each search particle, and then obtain hue histogram, be i.e. vector Vi;
Calculate the similarity sum (abs (Vi-V)) of the vectorial Vi and target feature vector V of each search particle;
Similarity corresponding for all search particles is normalized, make all similarities and be 1.
Described to each search particle obtain Similarity-Weighted obtain target area position particularly as follows:
The similarity of each search particle is done weighting process respectively for transverse and longitudinal coordinate, obtains the position of target area:
X=sum (Xn × Wn) Y=sum (Yn × Wn)
Wherein Xn, Yn represent the search horizontal stroke of particle, vertical coordinate, and Wn is the similarity that this search particle is corresponding.
After the described Similarity-Weighted that each search particle is obtained obtains the position of target area, enter the resampling stage:
When the difference of object region estimates similarity that the difference with masterplate estimates less than setting value, return step 2), until the difference of object region estimates difference that the difference with masterplate estimates less than when setting difference, the coordinate of the particle centre obtained is position in present image, the target area.
The described movement locus according to target vehicle and the Distance Judgment with this car go out abnormal vehicle particularly as follows: when the extended line of movement locus is directed towards this car, be then one-level early warning, using target vehicle as abnormal vehicle;When one-level early warning and distance are less than setpoint distance, then it are two grades of early warning, carry out audible alarm;When the speed of two grades of early warning and this car is still constant or increases, then self-actuating brake.
The invention have the advantages that and advantage:
1. the present invention is based on image processing techniques, vehicle periphery vehicle is tracked detection, notes abnormalities in time and carry out early warning or process, effectively reduces owing to the accident of other vehicles drives the probability causing the accident of this car to occur.
2. the present invention real-time with this car for the center of circle, the vehicle in certain radius carries out the supervision of real-time driving states, with the vehicle that notes abnormalities, and takes measures timely, prevents trouble before it happens.
3. the present invention adopts a series of images such as particle filter to process means, it is therefore intended that effectively based on image, vehicle a range of around this car can carry out monitoring constantly, and judge whether that there will be exception jeopardizes the safety of this car.
Accompanying drawing explanation
Fig. 1 is the method flow diagram of the present invention;
Fig. 2 is the perspective effect figure of the present invention.
Detailed description of the invention
Below in conjunction with embodiment, the present invention is described in further detail.
As it is shown in figure 1, the present invention comprises the following steps:
1. stencil matching carries out image automatic vehicle identification:
Respectively this car just before, just after, positive left, front-right one photographic head is set, it is possible to make standard form for off-line, gather the image data source for the image procossing in later stage constantly.
Structure car shown in Fig. 2, lorry, the standard masterplate of passenger vehicle, standard masterplate is formed respectively from this car 4 angle shot all kinds vehicle pictures all around, the rectangle frame that masterplate is is target with vehicle, namely can comprising the minimum rectangle frame of whole vehicle, in frame, major part is automobile, and final masterplate pattern includes the picture of the angle as much as possible of the various vehicle of various angle.Collection standard masterplate in order that for contrasting for extracting information of vehicles from the picture of video, thus real-time tracking and real-time monitoring.
For there is noise in the image in the video that this car is acquired in the process of moving, having space and amplitude quantization error and the uncertainty of examined object shape and configuration aspects, stencil matching is always difficult to absolutely accurate.Thus each version difference between modulus version and image will estimate D (x, y) (wherein x, y are the coordinate of image, with the upper left corner for the coordinate system in the center of circle) on the every bit of image.Every D (x, y) less than a certain threshold value Ld (x, y) place (sets Ld (x, value y) is on image before institute's difference metric a little 10%) to improve accuracy rate the present embodiment, all shows the object that the existence of this place to detect.Usual thresholding is constant in whole image.What the present invention adopted is that difference metric is as follows:
D ( x , y ) = Σ x ′ Σ y ′ [ T ( x ′ , y ′ ) - F ( x ′ + x , y ′ + y ) ] 2
Wherein T () is masterplate, and F () is detected object, x, and y is the coordinate that image is corresponding, x ', and y ' is the position of the point in template image coordinate system;For result, (x, y) judges, less than threshold value is then the region mated with Ld.After coupling, image is carried out particle filter process.
2. based on the image trace technology of particle filter:
Based on the vehicle that automatic recognition detection arrives, calculating the rectangular histogram in tone (Hue) space in this region, chrominance space is in three, hsv color space component color, saturation, value, with the conversion formula of tradition RGB color is:
Wherein, R, G, B is the information in the rgb space of original image, and max is the maximum in RGB, and min is the minima in RGB.
According to formula, by the RGB of target area being converted to the h space in HSV, and to the h Information Statistics in target frame be rectangular histogram as search clarification of objective, rectangular histogram can represent with a vector, so characteristic target is exactly the vectorial V of a N*1.
Search phase adopts Gauss distribution to arrange search particle (with target area same size), namely the close-proximity target zone determined at previous frame, near order target area (within the scope of 1 times of target area), the 80% of total particle is set, wide region place all the other 20%, color characteristic to image residing for this particle of calculating particles of each placement, i.e. h rectangular histogram, obtain a hue histogram, represent with vector Vi, and calculate the similarity of this rectangular histogram and goal histogram.Similarity has multiple tolerance, simplest one is to calculate sum (abs (Vi-V)), namely calculate absolute value between this histogram vectors and goal histogram vector and, in order to simplify follow-up calculating, similarity is obtained for all particles need to carry out a normalization so that all of similarity and be 1.
The similarity that each particle is obtained by the decision phase is done weighting respectively for transverse and longitudinal coordinate and is processed, then the most probable pixel coordinate X=sum (Xn × Wn) of target, Y=sum (Yn × Wn), wherein Xn, Yn represents the transverse and longitudinal coordinate of particle, and Wn is the similarity of this particle.
The resampling stage, result according to similarity discharges search particle again, the place that similarity is high arranges the 80% of total population, the 20% of total number of particles is placed in the position that similarity is low, such repeat search stage, then the decision phase is calculated, then proceed to circulation, until finding similarity and target region closely, namely until finding the difference of target area image in search particle range to estimate the difference of the similarity that the difference with template image is estimated closely 0, the final difference of such as two target areas is less than 0.01, finally determine the target position at present frame.Wherein, similarity measurement adopts the difference of histogram vectors to measure, and formula is as follows: sum (abs (Vi-V)).
3. the vehicle for following the tracks of carries out real-time detection, image is carried out perspective transform, in advance video camera is demarcated according to four known points, form the perspective transform figure at God visual angle, to detect the situation of vehicle periphery, schematic diagram is as shown in Figure 2, calculate the movement locus of vehicle, if it find that the extended line that the movement locus of vehicle is is directed towards this car, this track be by many frame informations statistics on perspective view to display constantly, start one-level early warning, using target vehicle as paying close attention to vehicle.
Judge the speed of target vehicle on projection images and apart from the spacing of this car, the actual range being set by perspective transform of this distance, setpoint distance threshold value is 5 meters, speed can calculate with perspective actual range according to the frame number of video, if distance is less than threshold value, then take the second early warning alarm and reminding driver to take measures, if driver does not take measures, open the 3rd modes of warning, automobile emergency brake, to avoid target vehicle.

Claims (9)

1. the detection method based on the abnormal vehicle of image procossing, it is characterised in that comprise the following steps:
The vehicle image that this car is shot contains the target area of target vehicle by stencil matching identification:
Target area is carried out particle filter and obtains target vehicle position in present image;
Present image is carried out perspective transform and obtains the distance of target vehicle and this car in present image;Connect the position of target vehicle in the position of target vehicle in present image and previous frame image and obtain the movement locus of target vehicle;
Movement locus according to target vehicle and go out abnormal vehicle with the Distance Judgment of this car.
2. the detection method of a kind of abnormal vehicle based on image procossing according to claim 1, it is characterised in that the target area that the described vehicle image that this car is shot contains target vehicle by stencil matching identification comprises the following steps:
Respectively the various vehicle images all around shot from this car are formed preset template;
The original vehicle image of the four direction of this car Real-time Collection is carried out difference operation with the template of correspondence direction respectively:
D ( x , y ) = Σ x ′ Σ y ′ [ T ( x ′ , y ′ ) - F ( x ′ + x , y ′ + y ) ] 2
D (x, y) estimates for difference, (and x, y) for the coordinate of vehicle image, T () is masterplate, and F () is target vehicle, (x ', y ') it is the point in the coordinate system of preset template image;
Choosing difference in the picture less than the region of threshold value is the target area containing target vehicle.
3. the detection method of a kind of abnormal vehicle based on image procossing according to claim 1, it is characterised in that described particle filter that target area is carried out obtains target vehicle position in present image and comprises the following steps:
1) RGB of target area in vehicle image is converted to the h space in HSV, is rectangular histogram using h space transforming as target feature vector V;
2) adopt Gauss distribution that the search particle with target area same size is set, present image scans for obtaining the similarity of the histogram vectors Vi and target feature vector V of all search particles;
3) Similarity-Weighted that each search particle is obtained obtains the position of target area.
4. the detection method of a kind of abnormal vehicle based on image procossing according to claim 3, it is characterised in that the h space that the described RGB by original vehicle objective area in image is converted in HSV is realized by below equation:
Wherein, R, G, B are the information in the rgb space of original image, and max is the maximum in RGB, and min is the minima in RGB.
5. the detection method of a kind of abnormal vehicle based on image procossing according to claim 3, it is characterized in that adopting Gauss distribution to arrange the search particle with target area same size particularly as follows: arrange within the scope of the several times of target area in original image and always search for the 80% of particle, all the other 20% search particles are placed in the region beyond several times scope.
6. the detection method of a kind of abnormal vehicle based on image procossing according to claim 3, it is characterised in that the described similarity that present image scans for obtaining the histogram vectors Vi and target feature vector V of all search particles comprises the following steps:
Calculate the h rectangular histogram of each search particle, and then obtain hue histogram, be i.e. vector Vi;
Calculate the similarity sum (abs (Vi-V)) of the vectorial Vi and target feature vector V of each search particle;
Similarity corresponding for all search particles is normalized, make all similarities and be 1.
7. the detection method of a kind of abnormal vehicle based on image procossing according to claim 4, it is characterised in that described to each search particle obtain Similarity-Weighted obtain target area position particularly as follows:
The similarity of each search particle is done weighting process respectively for transverse and longitudinal coordinate, obtains the position of target area:
X=sum (Xn × Wn) Y=sum (Yn × Wn)
Wherein Xn, Yn represent the search horizontal stroke of particle, vertical coordinate, and Wn is the similarity that this search particle is corresponding.
8. the detection method of a kind of abnormal vehicle based on image procossing according to claim 3, it is characterised in that after the described Similarity-Weighted that each search particle is obtained obtains the position of target area, enters the resampling stage:
When the difference of object region estimates similarity that the difference with masterplate estimates less than setting value, return step 2), until the difference of object region estimates difference that the difference with masterplate estimates less than when setting difference, the coordinate of the particle centre obtained is position in present image, the target area.
9. the detection method of a kind of abnormal vehicle based on image procossing according to claim 1, it is characterised in that the described movement locus according to target vehicle and the Distance Judgment with this car go out abnormal vehicle particularly as follows:
When the extended line of movement locus is directed towards this car, then it is one-level early warning, using target vehicle as abnormal vehicle;When one-level early warning and distance are less than setpoint distance, then it are two grades of early warning, carry out audible alarm;When the speed of two grades of early warning and this car is still constant or increases, then self-actuating brake.
CN201610053976.4A 2016-01-27 2016-01-27 Image processing based abnormal vehicle detection method Pending CN105740797A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610053976.4A CN105740797A (en) 2016-01-27 2016-01-27 Image processing based abnormal vehicle detection method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610053976.4A CN105740797A (en) 2016-01-27 2016-01-27 Image processing based abnormal vehicle detection method

Publications (1)

Publication Number Publication Date
CN105740797A true CN105740797A (en) 2016-07-06

Family

ID=56246697

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610053976.4A Pending CN105740797A (en) 2016-01-27 2016-01-27 Image processing based abnormal vehicle detection method

Country Status (1)

Country Link
CN (1) CN105740797A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101236657A (en) * 2008-03-03 2008-08-06 吉林大学 Single movement target track tracking and recording method
CN104290745A (en) * 2014-10-28 2015-01-21 奇瑞汽车股份有限公司 Semi-automatic driving system for vehicle and method thereof
CN105046225A (en) * 2015-07-14 2015-11-11 安徽清新互联信息科技有限公司 Vehicle distance detection method based on tail detection
CN105070098A (en) * 2015-07-14 2015-11-18 安徽清新互联信息科技有限公司 Vehicle distance detection method based on license plate position
CN105182320A (en) * 2015-07-14 2015-12-23 安徽清新互联信息科技有限公司 Depth measurement-based vehicle distance detection method
CN105740804A (en) * 2016-01-27 2016-07-06 大连楼兰科技股份有限公司 Automatic vehicle tracking and driving method based on image processing

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101236657A (en) * 2008-03-03 2008-08-06 吉林大学 Single movement target track tracking and recording method
CN104290745A (en) * 2014-10-28 2015-01-21 奇瑞汽车股份有限公司 Semi-automatic driving system for vehicle and method thereof
CN105046225A (en) * 2015-07-14 2015-11-11 安徽清新互联信息科技有限公司 Vehicle distance detection method based on tail detection
CN105070098A (en) * 2015-07-14 2015-11-18 安徽清新互联信息科技有限公司 Vehicle distance detection method based on license plate position
CN105182320A (en) * 2015-07-14 2015-12-23 安徽清新互联信息科技有限公司 Depth measurement-based vehicle distance detection method
CN105740804A (en) * 2016-01-27 2016-07-06 大连楼兰科技股份有限公司 Automatic vehicle tracking and driving method based on image processing

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
PRFANS: ""基于粒子滤波的物体跟踪"", 《HTTP://WWW.SIGVC.ORG/BBS/THREAD-1959-1-1.HTML》 *
朱志宇: "《流形粒子滤波算法及其在视频目标跟踪中的应用》", 31 May 2015, 北京:国防工业出版社 *

Similar Documents

Publication Publication Date Title
EP1671216B1 (en) Moving object detection using low illumination depth capable computer vision
JP5297078B2 (en) Method for detecting moving object in blind spot of vehicle, and blind spot detection device
CN113370977B (en) Intelligent vehicle forward collision early warning method and system based on vision
Bedruz et al. Real-time vehicle detection and tracking using a mean-shift based blob analysis and tracking approach
US20090309966A1 (en) Method of detecting moving objects
CN111563469A (en) Method and device for identifying irregular parking behaviors
US20110164789A1 (en) Detection of vehicles in images of a night time scene
Kortli et al. A novel illumination-invariant lane detection system
CN102598057A (en) Method and system for automatic object detection and subsequent object tracking in accordance with the object shape
CN107480646B (en) Binocular vision-based vehicle-mounted video abnormal motion detection method
CN111553214B (en) Method and system for detecting smoking behavior of driver
CN112329747A (en) Vehicle parameter detection method based on video identification and deep learning and related device
Kortli et al. Efficient implementation of a real-time lane departure warning system
CN113658427A (en) Road condition monitoring method, system and equipment based on vision and radar
CN109858456A (en) A kind of rolling stock status fault analysis system
Kuo et al. Vision-based vehicle detection in the nighttime
Chang et al. Real-time vehicle tracking mechanism with license plate recognition from road images
Moizumi et al. Traffic light detection considering color saturation using in-vehicle stereo camera
CN113989779A (en) Rapid lane line detection method for port and wharf auxiliary barrier filtering
JP2002197588A (en) Method for discriminating tire type of traveling vehicle and method and device for discriminating vehicle model
CN113205687B (en) Drunk driving vehicle track recognition system based on video monitoring
Munajat et al. Vehicle detection and tracking based on corner and lines adjacent detection features
Chen et al. Automatic head detection for passenger flow analysis in bus surveillance videos
CN105740797A (en) Image processing based abnormal vehicle detection method
Srivastava et al. Standoff video analysis for the detection of security anomalies in vehicles

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20160706