CN111611995B - Method applied to positioning of highway video image license plate - Google Patents

Method applied to positioning of highway video image license plate Download PDF

Info

Publication number
CN111611995B
CN111611995B CN202010256755.3A CN202010256755A CN111611995B CN 111611995 B CN111611995 B CN 111611995B CN 202010256755 A CN202010256755 A CN 202010256755A CN 111611995 B CN111611995 B CN 111611995B
Authority
CN
China
Prior art keywords
image
license plate
calculating
area
center
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.)
Active
Application number
CN202010256755.3A
Other languages
Chinese (zh)
Other versions
CN111611995A (en
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.)
Tudou Data Technology Group Co ltd
Original Assignee
Tudou Data Technology Group 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 Tudou Data Technology Group Co ltd filed Critical Tudou Data Technology Group Co ltd
Priority to CN202010256755.3A priority Critical patent/CN111611995B/en
Publication of CN111611995A publication Critical patent/CN111611995A/en
Application granted granted Critical
Publication of CN111611995B publication Critical patent/CN111611995B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/24Aligning, centring, orientation detection or correction of the image
    • G06V10/245Aligning, centring, orientation detection or correction of the image by locating a pattern; Special marks for positioning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/28Quantising the image, e.g. histogram thresholding for discrimination between background and foreground patterns
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/60Type of objects
    • G06V20/62Text, e.g. of license plates, overlay texts or captions on TV images
    • G06V20/625License plates

Abstract

The invention discloses a technical method for license plate positioning applied to a highway video image, which comprises the following steps: step one, gray preprocessing is carried out on an acquired image; step two, calculating the longitudinal gradient of Sobel characteristics of the gray level image; thirdly, binarizing the Sobel image obtained by calculation in the second step; step four, performing left-right translation accumulation on the binarized Sobel image; step five, binarizing the image calculated in the step four; step six, calculating the deviation of the center of the minimum circumscribed rectangle of each suspected license plate region relative to the center of the original image in the X direction, the deviation of the center of the minimum circumscribed rectangle of the region relative to the bottom of the whole image in the Y direction and the saturation of the effective pixels contained in the region; and step seven, carrying out weighting after normalizing the features calculated in the step six. The invention can effectively position the area of the vehicle license plate in the highway video image.

Description

Method applied to positioning of highway video image license plate
Technical Field
The invention belongs to the technical field of artificial intelligence and image processing, and relates to a method applied to positioning of a highway video image license plate.
Background
In recent years, the intelligent transportation field is receiving more and more attention from researchers at home and abroad. Algorithm aspect: the vehicle detection and tracking, the automatic driving of the vehicle becomes a research hot spot by positioning and identifying license plates, and algorithms applied to the fields can robustly and accurately extract license plates, greatly reduce the complexity of manual work, avoid misjudgment caused by manual visual fatigue to a certain extent, and provide guarantee for subsequent accurate identification.
The existing license plate positioning algorithm basically adopts blue and rectangular to position under the condition of fixing a position from a vehicle and lighting, and the method is easily influenced by shooting angles and environments.
Disclosure of Invention
The invention discloses a method applied to positioning of a license plate of a highway video image, which provides an accurate and robust algorithm under the conditions of poor shooting light and fuzzy scene images, and the algorithm can effectively position the area of the license plate of a vehicle in the highway video image.
In order to achieve the above purpose, the technical scheme of the invention provides:
a technical method for license plate positioning applied to highway video images comprises the following steps:
step one, gray preprocessing is carried out on an acquired image;
step two, calculating the longitudinal gradient of Sobel characteristic of the gray image, wherein the calculation of the longitudinal gradient of the Sobel characteristic is realized by convolving the original gray image with a convolution template Gy,
Figure BDA0002437635810000011
Figure BDA0002437635810000021
thirdly, binarizing the Sobel image obtained by calculation in the second step;
step four, carrying out left-right translation accumulation on the binarized Sobel image in the step three to obtain an image for describing the degree of intensity of the longitudinal gradient characteristics of the image Sobel;
fifthly, performing binarization processing on the image calculated in the fourth step, marking the image smaller than a threshold value as 0, otherwise marking the image as 255, and taking each connected domain in the binary image as a suspected license plate region;
step six, calculating the deviation of the center of the minimum circumscribed rectangle of each suspected license plate region relative to the center of the original image in the X direction, the deviation of the center of the minimum circumscribed rectangle of the region relative to the bottom of the whole image in the Y direction and the saturation of the effective pixels contained in the region;
and step seven, weighting after normalizing the features calculated in the step six, wherein the area with the highest score is considered as the area where the license plate is located.
In a preferred embodiment of the present invention, the image acquired in the first step is an RGB image, and the RGB image is converted into a gray scale image.
In a preferred embodiment of the present invention, the image in the fifth step is binarized by using the oxford method.
In a preferred embodiment of the present invention, the calculating of the suspected license plate region in the sixth step is as follows:
step 6.1, counting the total number of pixels in each connected domain, namely the area of each area, and marking as area;
step 6.2: calculating the minimum bounding rectangle of each connected domain to obtain the width and height of the minimum bounding rectangle, calculating the aspect ratio, and marking as aspectRatio
aspectRatio=width/height
Step 6.3: calculating rectangle degree:
rectangularity=area/(width*height)
step 6.4: calculating the sum of pixel values in each connected domain, and calculating the saturation of the region containing pixels by using the sum:
saturability=sum/(width*height*255)
step 6.5: the offset of the center (center X, center y) of the smallest bounding rectangle of each connected domain with respect to the image center in the X direction is calculated as:
offsetX=abs(centerX-cols/2)
step 6.6: calculating the offset of the center of the minimum circumscribed rectangle of each connected domain relative to the bottom of the image in the Y direction, and marking as:
offsetY=abs(centerY-rows)。
in a preferred embodiment of the present invention, the distance of the left-right offset of the image in the sixth step is set to 1/5 of the width of the whole image.
In a preferred embodiment of the invention, the implementation for step seven is as follows: the weight of the area is set to 0.1, the weight of the offset relative to the center of the image in the X direction is set to 0.1, the offset relative to the bottom of the image in the Y direction is set to 0.3, the weight of the rectangle degree is set to 0.1, the weight of the aspect ratio is set to 0.2, the weight of the pixel saturation is set to 0.2, and the larger the weighted sum Score is, the more the license plate area is indicated.
Compared with the existing license plate positioning technology, the technical scheme of the invention has the following advantages:
the technical scheme of the invention is not limited by shooting angles and light environments, and can rapidly and accurately position the license plate area in a given highway video, thereby being convenient for license plate number identification.
Drawings
Fig. 1 is a functional block diagram of the present invention.
Detailed Description
A technical method for license plate positioning applied to highway video images comprises the following steps:
step one, gray preprocessing is carried out on an acquired image;
step two, calculating the longitudinal gradient of Sobel characteristic of the gray image, wherein the calculation of the longitudinal gradient of the Sobel characteristic is realized by convolving the original gray image with a convolution template Gy,
Figure BDA0002437635810000041
Figure BDA0002437635810000042
thirdly, binarizing the Sobel image obtained by calculation in the second step;
step four, carrying out left-right translation accumulation on the binarized Sobel image in the step three to obtain an image for describing the degree of intensity of the longitudinal gradient characteristics of the image Sobel;
fifthly, performing binarization processing on the image calculated in the fourth step, marking the image smaller than a threshold value as 0, otherwise marking the image as 255, and taking each connected domain in the binary image as a suspected license plate region;
step six, calculating the deviation of the center of the minimum circumscribed rectangle of each suspected license plate region relative to the center of the original image in the X direction, the deviation of the center of the minimum circumscribed rectangle of the region relative to the bottom of the whole image in the Y direction and the saturation of the effective pixels contained in the region;
and step seven, weighting after normalizing the features calculated in the step six, wherein the area with the highest score is considered as the area where the license plate is located.
Further, the image collected in the first step is an RGB image, and the RGB image is converted into a gray scale image. Further, the image in the fifth step is binarized by using the oxford method.
Specifically, the calculation of the suspected license plate region in the step six is as follows:
step 6.1, counting the total number of pixels in each connected domain, namely the area of each area, and marking as area;
step 6.2: calculating the minimum bounding rectangle of each connected domain to obtain the width and height of the minimum bounding rectangle, calculating the aspect ratio, and marking as aspectRatio
aspectRatio=width/height
Step 6.3: calculating rectangle degree:
rectangularity=area/(width*height)
step 6.4: calculating the sum of pixel values in each connected domain, and calculating the saturation of the region containing pixels by using the sum:
saturability=sum/(width*height*255)
step 6.5: the offset of the center (center X, center y) of the smallest bounding rectangle of each connected domain with respect to the image center in the X direction is calculated as:
offsetX=abs(centerX-cols/2)
step 6.6: calculating the offset of the center of the minimum circumscribed rectangle of each connected domain relative to the bottom of the image in the Y direction, and marking as:
offsetY=abs(centerY-rows)。
in a preferred embodiment of the present invention, the distance of the left-right offset of the image in the sixth step is set to 1/5 of the width of the whole image.
Specifically, the implementation manner for the step seven is as follows: the weight of the area is set to 0.1, the weight of the offset relative to the center of the image in the X direction is set to 0.1, the offset relative to the bottom of the image in the Y direction is set to 0.3, the weight of the rectangle degree is set to 0.1, the weight of the aspect ratio is set to 0.2, the weight of the pixel saturation is set to 0.2, and the larger the weighted sum Score is, the more the license plate area is indicated.
Example 1:
as shown in fig. 1, the invention is mainly applied to effectively positioning license plate areas in highway video images, and the invention comprises the following implementation steps:
step 1: reading an original image;
step 2: converting the original image into a gray image;
step 3: extracting Sobel longitudinal gradient characteristics of gray level images to obtain a characteristic image SobelY;
step 4: binarizing the image SobelY by using an Ojin method, setting the pixel value smaller than a threshold value threshold to be 0, otherwise setting the pixel value to be 1, and obtaining the binarySobelY;
step 5: the left-right offset distance shiftX of the image is set to be 1/5 of the width of the whole image, because the offset is too small, the counted non-zero element area is not bright enough, the offset is too large, the extracted area is too wide, the subsequent identification is not affected, but the license plate extraction area is not accurate enough, so the license plate extraction area is selected to be 1/5 according to the ratio of the license plate to the vehicle body;
step 6: creating an image sumValue1, assigning an original image binarySobelY to the image sumValue1, and taking the sumValue1 as an image to be translated in the next step;
step 7: shifting the image to be shifted leftwards by taking 1 pixel as a step length to obtain a binarySobelleft and taking the binarySobelleft as the image to be shifted next, assigning the sum of sumValue1 and binarySobelleft to sumValue1, repeating the step 7 if the shifting step length is not greater than the shiftX, otherwise, entering the step 8;
step 8: creating an image sumValue2, assigning an original image binarySobelY to the image sumValue2, and taking the sumValue2 as an image to be translated in the next step;
step 9: taking 1 pixel as a step length, shifting the image to be translated rightwards by taking the shift X as a shift distance to obtain a binarySobelRight and taking the binarySobelRight as the image to be translated in the next step, assigning the sum of the sumValue2 and the binarySobelRight to the sumValue2, repeating the step 9 if the shift step length is not greater than the shift X, otherwise, entering the step 10;
step 10: summing pixels at pixel positions corresponding to sumValue1 and sumValue2 to obtain a horizontally moving image, binarizing the image, wherein the pixel value smaller than a threshold value thresh is marked as 0, otherwise marked as 255, and the binarized image is marked as a binaryHarizonImage, wherein the summation mode of sumValue1 and sumValue2 is as follows:
Figure BDA0002437635810000071
wherein m and n are the height and width of the images sumValue1 and sumValue2 respectively;
step 11: taking each connected domain of the image binaryHarizonImage as a suspected license plate region;
step 12: counting the total number of pixels in each connected domain, namely the area of each area, and marking as area;
step 13: calculating the minimum bounding rectangle of each connected domain to obtain the width and height of the minimum bounding rectangle, calculating the aspect ratio, and marking as aspectRatio
aspectRatio=width/height
Step 14: calculating rectangle degree:
rectangularity=area/(width*height)
step 15: calculating the sum of pixel values in each connected domain, and calculating the saturation of the region containing pixels by using the sum:
saturability=sum/(width*height*255)
step 16: the offset of the center (center X, center y) of the smallest bounding rectangle of each connected domain with respect to the image center in the X direction is calculated as:
offsetX=abs(centerX-cols/2)
step 17: calculating the offset of the center of the minimum circumscribed rectangle of each connected domain relative to the bottom of the image in the Y direction, and marking as:
offsetY=abs(centerY-rows)
step 18: and (3) weighting the normalized features in the steps 12 to 17, wherein the highest Score is the area where the license plate is located, the artificial setting of the area weight is 0.1, the offset relative to the center of the image in the X direction is 0.1, the offset relative to the bottom of the image in the Y direction is 0.3, the rectangular weight is 0.1, the aspect ratio weight is 0.2, the pixel saturation weight is 0.2, and the larger the weighted sum Score is, the more the license plate area is indicated.
The foregoing is merely a preferred embodiment of the invention, and it should be noted that it will be apparent to those skilled in the art that modifications and variations can be made without departing from the technical principles of the invention, and these modifications and variations should also be regarded as being within the scope of the invention.

Claims (5)

1. The technical method for positioning the license plate of the road video image is characterized by comprising the following steps of:
step one, gray preprocessing is carried out on an acquired image;
step two, calculating the longitudinal gradient of Sobel characteristic of the gray image, wherein the calculation of the longitudinal gradient of the Sobel characteristic is realized by convolving the original gray image with a convolution template Gy,
Figure FDA0004117094540000011
thirdly, binarizing the Sobel image obtained by calculation in the second step;
step four, carrying out left-right translation accumulation on the binarized Sobel image in the step three to obtain an image for describing the degree of intensity of the longitudinal gradient characteristics of the image Sobel;
fifthly, performing binarization processing on the image calculated in the fourth step, marking the image smaller than a threshold value as 0, otherwise marking the image as 255, and taking each connected domain in the binary image as a suspected license plate region;
step six, calculating the following for each suspected license plate area:
step 6.1: counting the total number of pixels in each connected domain, namely the area of each area, and marking as area;
step 6.2: calculating the minimum circumscribed rectangle of each connected domain, obtaining the width and height of the minimum circumscribed rectangle, calculating the aspect ratio, and marking as aspectRatio:
aspectRatio=width/height
step 6.3: calculating rectangle degree:
rectangularity=area/(width*height)
step 6.4: calculating the sum of pixel values in each connected domain, and calculating the saturation of the region containing pixels by using the sum:
saturability=sum/(width*height*255)
step 6.5: the offset of the center (center X, center y) of the smallest bounding rectangle of each connected domain with respect to the image center in the X direction is calculated as:
offsetX=abs(centerX-cols/2)
step 6.6: calculating the offset of the center of the minimum circumscribed rectangle of each connected domain relative to the bottom of the image in the Y direction, and marking as:
offsetY=abs(centerY-rows);
and step seven, weighting after normalizing the features calculated in the step six, wherein the area with the highest score is considered as the area where the license plate is located.
2. The method of claim 1, wherein the image collected in the first step is an RGB image, and the RGB image is converted into a gray scale image.
3. The technical method for license plate positioning applied to a highway video image according to claim 1, wherein the image in the fifth step is subjected to binarization processing by using an oxford method.
4. The method according to claim 1, wherein the distance of the left-right offset of the image in the sixth step is 1/5 of the width of the whole image.
5. The method for positioning license plates of highway video according to claim 4, wherein the implementation manner for the step seven is as follows: the weight of the area is set to 0.1, the weight of the offset relative to the center of the image in the X direction is set to 0.1, the offset relative to the bottom of the image in the Y direction is set to 0.3, the weight of the rectangle degree is set to 0.1, the weight of the aspect ratio is set to 0.2, the weight of the pixel saturation is set to 0.2, and the larger the weighted sum Score is, the more the license plate area is indicated.
CN202010256755.3A 2020-04-02 2020-04-02 Method applied to positioning of highway video image license plate Active CN111611995B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010256755.3A CN111611995B (en) 2020-04-02 2020-04-02 Method applied to positioning of highway video image license plate

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010256755.3A CN111611995B (en) 2020-04-02 2020-04-02 Method applied to positioning of highway video image license plate

Publications (2)

Publication Number Publication Date
CN111611995A CN111611995A (en) 2020-09-01
CN111611995B true CN111611995B (en) 2023-05-23

Family

ID=72205422

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010256755.3A Active CN111611995B (en) 2020-04-02 2020-04-02 Method applied to positioning of highway video image license plate

Country Status (1)

Country Link
CN (1) CN111611995B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103984949A (en) * 2014-06-11 2014-08-13 四川九洲电器集团有限责任公司 License plate positioning method and system based on high and low cap transformation and connected domain
CN106709530A (en) * 2017-01-17 2017-05-24 中国科学院上海高等研究院 License plate recognition method based on video

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI431559B (en) * 2010-10-29 2014-03-21 Univ Nat Chiao Tung A vehicle registration-plate detecting method and system thereof

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103984949A (en) * 2014-06-11 2014-08-13 四川九洲电器集团有限责任公司 License plate positioning method and system based on high and low cap transformation and connected domain
CN106709530A (en) * 2017-01-17 2017-05-24 中国科学院上海高等研究院 License plate recognition method based on video

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
刘丽丽 ; .车牌识别中的图像分割技术研究.科技通报.2017,(04),全文. *
刘翔 ; 周桢 ; 李旻 ; .复杂环境下车牌定位算法仿真研究.信息技术.2013,(02),全文. *

Also Published As

Publication number Publication date
CN111611995A (en) 2020-09-01

Similar Documents

Publication Publication Date Title
CN105373794B (en) A kind of licence plate recognition method
CN109784344B (en) Image non-target filtering method for ground plane identification recognition
CN109657632B (en) Lane line detection and identification method
KR100912746B1 (en) Method for traffic sign detection
TWI409718B (en) Method of locating license plate of moving vehicle
CN107563413B (en) Unmanned aerial vehicle aerial image farmland block object accurate extraction method
CN106683119B (en) Moving vehicle detection method based on aerial video image
CN108596166A (en) A kind of container number identification method based on convolutional neural networks classification
CN109816024A (en) A kind of real-time automobile logo detection method based on multi-scale feature fusion and DCNN
CN107092871B (en) Remote sensing image building detection method based on multiple dimensioned multiple features fusion
CN107705254B (en) City environment assessment method based on street view
CN103971126A (en) Method and device for identifying traffic signs
CN109886168B (en) Ground traffic sign identification method based on hierarchy
CN107423735B (en) License plate positioning method utilizing horizontal gradient and saturation
CN111382658B (en) Road traffic sign detection method in natural environment based on image gray gradient consistency
Xiang et al. Lightweight fully convolutional network for license plate detection
CN105335744A (en) One-dimensional code region location based on image backbone extraction strip distribution features
Rashedi et al. A hierarchical algorithm for vehicle license plate localization
CN111695373B (en) Zebra stripes positioning method, system, medium and equipment
CN111401364A (en) License plate positioning algorithm based on combination of color features and template matching
CN109635726B (en) Landslide identification method based on combination of symmetric deep network and multi-scale pooling
Chen et al. License plate recognition for moving vehicles using a moving camera
CN108520252B (en) Road sign identification method based on generalized Hough transform and wavelet transform
CN111611995B (en) Method applied to positioning of highway video image license plate
CN113239733A (en) Multi-lane line detection method

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
CB02 Change of applicant information

Address after: Room 504, Block E, HUanpu science and Technology Industrial Park, 211 tianguba Road, high tech Zone, Xi'an City, Shaanxi Province, 710000

Applicant after: Tudou Data Technology Group Co.,Ltd.

Address before: Room 504, Block E, HUanpu science and Technology Industrial Park, 211 tianguba Road, high tech Zone, Xi'an City, Shaanxi Province, 710000

Applicant before: SHAANXI TUDOU DATA TECHNOLOGY Co.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant