1. Initial license plate location
1.1. License plate after conversion from RGB space to HSI space
Color images contain rich color information and give people a good visual effect. The initial positioning is based on this feature. However, in general, color images are all under the RGB model, and the HSI model is more suitable for the human visual system, so color space conversion is required to convert the RGB model into the HSI model. The conversion formula from RGB space to HSI space is:
When B <=G, H = θ; when B > G, H = 360°- θ.
In the blue-background white-letter license plate, the chromaticity H of blue is about 240° and the saturation S value is relatively large. Through these two quantities, the blue part of the input image can be completely filtered out, thereby removing a large amount of background noise.
The experimental test shows that the chroma of the blue license plate is >= 0.75 and the saturation is >= 0.51. It can be seen that the license plate area can be roughly located by using the range values of chroma and saturation in the HSI space, and the result is shown in Figure 1.
1.2. Preprocessing of license plate location
After preliminary positioning, the license plate range is reduced and the license plate image is processed in grayscale. The texture distribution of the grayscale image is mainly in the headlights, license plate, and radiator. The grayscale value of the license plate position is also different from that of other parts. Most of the grayscale changes in the non-license plate area are relatively gentle.
(1) Remove isolated bright spots
Generally speaking, the acquisition process of license plate images is affected by various factors, such as background, lighting and some characteristics of the car itself, which easily cause noise in the image. Since the initial positioning has removed most of the background of the license plate image, the noise points are reduced. In order to reduce the possible area of the license plate, the bwmorph function in the Matlab toolbox is used to effectively remove isolated points. The result is shown in Figure 3.
(2) Shift scanning and edge detection
The shift scan is to scan the entire image from left to right, using adjacent pixels as the grayscale to weaken the horizontal texture and retain and increase the grayscale at the vertical transition, as shown in formula (4).
In the formula, f (xj, yi) is the original image, g (xj, yi) is the scanned image. After processing, the vertical texture and lines of the image become more obvious, thereby weakening other areas and highlighting the license plate area. As shown in Figure 4. Then, using edge detection, the boundary of the license plate area is highlighted from the entire image, making the features of the license plate area more obvious. The effect is shown in Figure 5.
Figure 5 Edge detection diagram
2. Accurate positioning of license plates
After the shift scan, the texture and lines of the license plate area in the grayscale image become more obvious, and the noise of the entire image is less, so the horizontal and vertical boundaries of the license plate can be determined.
This paper uses horizontal projection and vertical projection to determine the boundaries of the license plate respectively.
By edge detection of the image, the license plate area is clearly divided and the noise points in the non-license plate area are reduced, so the horizontal projection method is used to determine the vertical license plate boundary.
Horizontal projection is to scan the image f (xj, yi) row by row from top to bottom, add the values of each column, and get a one-dimensional function f (yi). This converts the two-dimensional function into a one-dimensional function, as shown in formula (5).
The obtained one-dimensional function is a statistic of the white pixels in each column of the image. When the value of f(yi) is large, it corresponds to the license plate area; when the value of f(yi) is small or 0, it corresponds to the noise in the non-license plate area. This feature is used to determine the horizontal boundary of the license plate. When the image is drawn for the function fyi, it can be found that when f(yi) is not 0, there is a white pixel in the vertical direction of the corresponding f(xj,yi). When fyi is 0, there is no white pixel in the vertical direction of the corresponding f(xj,yi), which can be determined as a non-license plate area.
When the left and right boundaries of the license plate are determined, the relative noise of the vertical positioning is reduced. The vertical projection is to first scan the image f (xj, yi) line by line from left to right, add the values of each line, and obtain a one-dimensional function f (xj).
As shown in formula (6).
The projection diagrams of the horizontal projection and the vertical projection are shown in FIGS. 6 and 7 .
In this process, the selection of the threshold is determined based on the image of the projection map. Because in the projection map, it represents the accumulation of white pixels in each column or row. So when the value of the projection map is large, it means that there are more white pixels in this column or row, which is the license plate area; when the value of the projection map is small, it is a noise point, so a threshold must be determined to remove the noise. The image processing method used in this article has removed most of the noise points, so the threshold is set here first. The area greater than this value is the license plate area. At the same time, because the license plate itself has the characteristics of length and width ratio, the ratio of the license plate is generally 22:7, and the final positioning is based on this feature.
In license plate positioning, the positioning method mainly considers whether the anti-interference ability to noise is good. The initial positioning of the license plate area in this paper is through the conversion of the color model, and the license plate position is roughly determined by the range of chroma and saturation. A large amount of background noise is removed, providing a reliable basis for the accuracy of secondary positioning. In precise positioning, considering the noise of the car itself, such as radiator, headlights, etc., but because the texture of the license plate position is prominent and the body noise is relatively small, the license plate position is more prominent by using differential scanning, and only a single isolated bright spot is left in the non-license plate area. In precise positioning, projection is used, so isolated bright spots must be removed. In this paper, Matlab toolbox is used to effectively remove a large number of isolated bright spots. Horizontal and vertical projections are used to determine the horizontal and vertical boundaries, and the characteristics of the length and width ratio of the license plate itself are used for final positioning. Experiments have shown that the anti-interference ability to the license plate image noise is good and the positioning effect is good.
3. Conclusion
This paper uses a license plate positioning method based on color and projection to determine the license plate area in two steps. By testing 320 car pictures with a resolution of 1 024%768 and different backgrounds, the positioning success rate reaches more than 8%.
Previous article:Video conferencing video debugging techniques and skills
Next article:Design and implementation of Ethernet video surveillance based on KT8818
- Popular Resources
- Popular amplifiers
- High signal-to-noise ratio MEMS microphone drives artificial intelligence interaction
- Advantages of using a differential-to-single-ended RF amplifier in a transmit signal chain design
- ON Semiconductor CEO Appears at Munich Electronica Show and Launches Treo Platform
- ON Semiconductor Launches Industry-Leading Analog and Mixed-Signal Platform
- Analog Devices ADAQ7767-1 μModule DAQ Solution for Rapid Development of Precision Data Acquisition Systems Now Available at Mouser
- Domestic high-precision, high-speed ADC chips are on the rise
- Microcontrollers that combine Hi-Fi, intelligence and USB multi-channel features – ushering in a new era of digital audio
- Using capacitive PGA, Naxin Micro launches high-precision multi-channel 24/16-bit Δ-Σ ADC
- Fully Differential Amplifier Provides High Voltage, Low Noise Signals for Precision Data Acquisition Signal Chain
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- How to enable TI 15.4-Stack to support 470M frequency band
- Design of temperature control system using DS18B20
- Introducing a touch capacitive screen IIC interface to USB solution
- ad16
- MOSFET switching voltage Vgs
- High-precision electronic heartbeat comes from TI's breakthrough BAW resonator technology
- Please tell me what is the shortcut key to flip a layer in PCB in Altium Designer?
- Embedded Qt-Make a stopwatch
- How complicated is the inside of a sweeping robot? TI E2E will reveal the secrets for you in five steps! Answer the questions and win prizes...
- 【Development Kit for nRF52840】+ Three Tools for Evaluation & Cloud Gateway Testing