CN111695373B - Zebra stripes positioning method, system, medium and equipment - Google Patents
Zebra stripes positioning method, system, medium and equipment Download PDFInfo
- Publication number
- CN111695373B CN111695373B CN201910185277.9A CN201910185277A CN111695373B CN 111695373 B CN111695373 B CN 111695373B CN 201910185277 A CN201910185277 A CN 201910185277A CN 111695373 B CN111695373 B CN 111695373B
- Authority
- CN
- China
- Prior art keywords
- zebra
- image
- zebra crossing
- rectangular frame
- horizontal rectangular
- 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
Links
- 241000283070 Equus zebra Species 0.000 title claims abstract description 196
- 238000000034 method Methods 0.000 title claims abstract description 66
- 238000012544 monitoring process Methods 0.000 claims abstract description 56
- 238000001514 detection method Methods 0.000 claims abstract description 43
- 238000012545 processing Methods 0.000 claims abstract description 38
- 238000013135 deep learning Methods 0.000 claims abstract description 32
- 238000006243 chemical reaction Methods 0.000 claims abstract description 21
- 238000004458 analytical method Methods 0.000 claims abstract description 20
- 238000007621 cluster analysis Methods 0.000 claims abstract description 13
- 238000003708 edge detection Methods 0.000 claims abstract description 13
- 230000005484 gravity Effects 0.000 claims description 30
- 230000001186 cumulative effect Effects 0.000 claims description 12
- 238000004590 computer program Methods 0.000 claims description 11
- 238000000605 extraction Methods 0.000 claims description 8
- 238000012549 training Methods 0.000 claims description 4
- 238000004891 communication Methods 0.000 description 6
- 230000000694 effects Effects 0.000 description 6
- 238000013527 convolutional neural network Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 230000007547 defect Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 238000003491 array Methods 0.000 description 2
- 238000013528 artificial neural network Methods 0.000 description 2
- 235000019800 disodium phosphate Nutrition 0.000 description 2
- 230000006870 function Effects 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 238000012360 testing method Methods 0.000 description 2
- 230000003044 adaptive effect Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 230000018109 developmental process Effects 0.000 description 1
- 230000008030 elimination Effects 0.000 description 1
- 238000003379 elimination reaction Methods 0.000 description 1
- 238000000802 evaporation-induced self-assembly Methods 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 230000002349 favourable effect Effects 0.000 description 1
- 238000003058 natural language processing Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000306 recurrent effect Effects 0.000 description 1
- 230000011218 segmentation Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
- G06V20/50—Context or environment of the image
- G06V20/56—Context or environment of the image exterior to a vehicle by using sensors mounted on the vehicle
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/23—Clustering techniques
- G06F18/232—Non-hierarchical techniques
- G06F18/2321—Non-hierarchical techniques using statistics or function optimisation, e.g. modelling of probability density functions
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/20—Image preprocessing
- G06V10/25—Determination of region of interest [ROI] or a volume of interest [VOI]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/20—Image preprocessing
- G06V10/26—Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion
- G06V10/267—Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion by performing operations on regions, e.g. growing, shrinking or watersheds
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
- G06V10/44—Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
- G06V10/56—Extraction of image or video features relating to colour
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Data Mining & Analysis (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Bioinformatics & Computational Biology (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Evolutionary Biology (AREA)
- Evolutionary Computation (AREA)
- General Engineering & Computer Science (AREA)
- Artificial Intelligence (AREA)
- Life Sciences & Earth Sciences (AREA)
- Probability & Statistics with Applications (AREA)
- Image Analysis (AREA)
Abstract
The invention provides a zebra crossing positioning method, a zebra crossing positioning system, a zebra crossing positioning medium and zebra crossing positioning equipment, wherein the zebra crossing positioning method comprises the following steps: detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in an image position area of each identified zebra crossing in the monitoring image; performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing to generate a binarized image of the monitoring image; clustering and analyzing white pixel points in the binary image, and removing noise areas of non-zebra crossings; and selecting contour extreme points in the binarized images after cluster analysis through edge detection, and extracting zebra stripes to extract the zebra stripes so as to locate zebra stripes. The zebra crossing positioning method provided by the invention improves the accuracy of zebra crossing positioning and provides a basis for complex vehicle driving analysis at traffic intersections.
Description
Technical Field
The invention belongs to the field of image processing, relates to a zebra crossing image positioning method, and particularly relates to a zebra crossing positioning method, system, medium and equipment.
Background
The problem of zebra stripes detection is that automatic driving and intelligent traffic are always concerned, and the difference of angles of cameras makes the shape and the size of the zebra stripes different. Under the condition of automatic driving, zebra stripes are mostly parallel to upper and lower boundaries in an acquired image, and in the image acquired by a traffic camera, especially in the image acquired by a camera with a rotatable angle, the directions and the sizes of the zebra stripes are different, and under the scene of a traffic intersection, a plurality of zebra stripes which are clear or fuzzy and have huge deformation due to perspective effect exist in one image. This situation presents additional difficulties in identifying and locating zebra crossings.
The problem of zebra stripes detection is compatible with the development of automatic driving, and is not limited to automatic driving scenes, for example, the problem that the detection and positioning of zebra stripes in intelligent traffic are also necessary to overcome. The traditional zebra crossing detection method focuses on physical characteristics of zebra crossing, extracts edges through a canny operator, obtains straight lines through Hough transformation, and detects the existence of the zebra crossing through analysis on a series of parallel straight lines. However, the methods are different in size, and have weak adaptability to detection of zebra stripes under different light, deformation and definition scenes.
Deep learning is a popular direction of computer and even other disciplines in recent years. Deep learning frameworks such as deep neural networks, convolutional neural networks, deep belief networks, recurrent neural networks, and the like have been widely used in the fields of computer vision, speech recognition, natural language processing, audio recognition, bioinformatics, and the like to achieve excellent effects. The deep learning has the advantages that the semi-supervised or non-supervised feature learning and hierarchical feature extraction are used for efficiently replacing the manual feature acquisition.
In the deep learning target detection algorithm, the fast R-CNN is an algorithm with high speed and high accuracy, integrates four basic steps (candidate region generation, feature extraction, classification and position adjustment) of target detection, and greatly improves the running speed. However, in the conventional target detection algorithm, the generated candidate region and the detection frame output by the network are horizontal rectangular frames, and a good positioning effect cannot be achieved for non-conventional target detection data (such as long and narrow zebra crossings at traffic intersections).
Therefore, how to provide a positioning method for the zebra stripes, so that the positioning is more accurate and is more suitable for complex and changeable environments, so as to reduce the false detection rate of the zebra stripes, has become a technical problem to be solved by those skilled in the art.
Disclosure of Invention
In view of the above drawbacks of the prior art, the present invention is directed to a method, a system, a medium, and a device for positioning a zebra stripes, which are used for solving the problem of low positioning accuracy of zebra stripes in the prior art.
To achieve the above and other related objects, the present invention provides a method for positioning a zebra stripes, comprising: detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in an image position area of each identified zebra crossing in the monitoring image; performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing to generate a binarized image of the monitoring image; clustering and analyzing white pixel points in the binary image, and removing noise areas of non-zebra crossings; and selecting contour extreme points in the binarized images after cluster analysis through edge detection, and extracting zebra stripes to extract the zebra stripes so as to locate zebra stripes.
In an embodiment of the present invention, before the step of detecting the collected monitoring image of the traffic intersection with a deep-learning zebra crossing detection network and setting a horizontal rectangular frame for determining the position of the zebra crossing in the image position area of each zebra crossing identified in the monitoring image, the positioning method of the zebra crossing further includes: training a deep learning zebra crossing detection model by the pre-collected monitoring images of a plurality of traffic intersections, and generating the zebra crossing detection network.
In an embodiment of the present invention, the step of performing color space conversion on the monitor image in the horizontal rectangular frame and performing image binarization processing to generate a binarized image of the monitor image includes: performing color space conversion on the traffic monitoring image in the horizontal rectangular frame; drawing a cumulative histogram according to the proportion of the pixel points corresponding to the brightness values after the color space conversion in the total number of the pixel points; a proportional threshold is set in the cumulative histogram as a demarcation value of the white pixel point of the image binarization.
In an embodiment of the present invention, the step of cluster analyzing white pixels in the binary image and removing noise areas of non-zebra stripes includes: in each horizontal rectangular frame area, performing density analysis on the areas of all the white pixel points in the binarized image according to a preset size parameter; determining the average position of the white pixel points in each horizontal rectangular frame area one by one according to the result of the density analysis, and taking the average position as the center of gravity of the cluster; performing straight line fitting on all the cluster centers of gravity; and eliminating the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line.
In an embodiment of the present invention, the step of eliminating the area of the white pixel corresponding to the cluster center deviating from the straight line includes: determining the area of the white pixel point corresponding to the clustering center deviating from the straight line as a noise area; and eliminating the noise area.
In an embodiment of the present invention, the cluster centroid is a density centroid of pixels determined in the horizontal rectangular frame.
In an embodiment of the invention, the cluster analysis is based on a preset scan radius parameter and a minimum inclusion point parameter.
In another aspect, the present invention provides a positioning system for a zebra stripes, where the positioning system for a zebra stripes includes: the position selection module is used for detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in the image position area of each zebra crossing identified in the monitoring image; the binarization processing module is used for carrying out color space conversion on the monitoring image in the horizontal rectangular frame and carrying out image binarization processing so as to generate a binarized image of the monitoring image; the clustering processing module is used for carrying out clustering analysis on white pixel points in the binarized image and eliminating noise areas of non-zebra crossings; and the positioning module is used for selecting contour extreme points through edge detection in the binary image after cluster analysis, extracting zebra crossing contour extraction and positioning a zebra crossing region.
In yet another aspect, the present invention provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the zebra crossing positioning method.
In a final aspect the invention provides an apparatus comprising: a processor and a memory;
the memory is used for storing a computer program, and the processor is used for executing the computer program stored by the memory so as to enable the device to execute the zebra crossing positioning method.
As described above, the zebra stripes positioning method, system, medium and equipment of the invention have the following beneficial effects:
the method can quickly and accurately identify the zebra stripes in the images acquired by the traffic intersection cameras, can adapt to different weather, time and seasons to accurately position the zebra stripes, greatly reduces the false detection rate of the zebra stripes, improves the accuracy rate of the zebra stripe positioning, and provides a basis for complex vehicle driving analysis of the traffic intersection.
Drawings
Fig. 1 is a schematic flow chart of a zebra stripes positioning method according to an embodiment of the present invention.
Fig. 2 is a schematic diagram of a zebra pattern detected by a zebra stripes detection network.
FIG. 3 is a schematic diagram of a zebra stripes positioning system according to an embodiment of the present invention.
Description of element reference numerals
21. Horizontal rectangular frame
22. White pixel area
23. Edge detection line
24. Non-zebra crossing regions
25. Clustering center of gravity on fitting straight line
26. Clustering center of gravity deviating from fitted line
27. Fitting straight line
3. Positioning system of zebra stripes
31. Position selection module
32. Binarization processing module
33. Clustering processing module
34. Positioning module
S11-S14 zebra crossing positioning method steps
Detailed Description
Other advantages and effects of the present invention will become apparent to those skilled in the art from the following disclosure, which describes the embodiments of the present invention with reference to specific examples. The invention may be practiced or carried out in other embodiments that depart from the specific details, and the details of the present description may be modified or varied from the spirit and scope of the present invention. It should be noted that the following embodiments and features in the embodiments may be combined with each other without conflict.
It should be noted that the illustrations provided in the following embodiments merely illustrate the basic concept of the present invention by way of illustration, and only the components related to the present invention are shown in the drawings and are not drawn according to the number, shape and size of the components in actual implementation, and the form, number and proportion of the components in actual implementation may be arbitrarily changed, and the layout of the components may be more complicated.
The technical principles of the zebra crossing positioning method, the zebra crossing positioning system, the zebra crossing positioning medium and the zebra crossing positioning equipment are as follows: detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in an image position area of each identified zebra crossing in the monitoring image; performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing to generate a binarized image of the monitoring image; clustering and analyzing white pixel points in the binary image, and removing noise areas of non-zebra crossings; and selecting contour extreme points in the binarized images after cluster analysis through edge detection, and extracting zebra stripes to extract the zebra stripes so as to locate zebra stripes.
Example 1
The zebra stripes positioning method provided by the embodiment comprises the following steps: detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in an image position area of each identified zebra crossing in the monitoring image; performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing to generate a binarized image of the monitoring image; clustering and analyzing white pixel points in the binary image, and removing noise areas of non-zebra crossings; and selecting contour extreme points in the binarized images after cluster analysis through edge detection, and extracting zebra stripes to extract the zebra stripes so as to locate zebra stripes.
The following describes the positioning method of the zebra stripes provided in this embodiment in detail with reference to the drawings.
Referring to fig. 1, a schematic flow chart of a zebra stripes positioning method according to an embodiment of the present invention is shown. As shown in fig. 1, the positioning method of the zebra stripes specifically includes the following steps:
and S10, training a deep learning zebra crossing detection model by the pre-collected monitoring images of a plurality of traffic intersections, and generating the zebra crossing detection network.
The monitoring images are images shot by cameras at the actual traffic intersections, zebra crossings in the images are different in position, different in shape and size and quite similar in size, and the images are quite different in brightness according to reasons such as weather at shooting time, and the zebra crossings are quite different in definition due to different drawing time because the images are actual scenes.
And S11, detecting the collected monitoring image of the traffic intersection through a zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of the zebra crossing in an image position area of each identified zebra crossing in the monitoring image.
The zebra stripes detection network is trained by a pre-stored deep learning method. The deep learning method greatly improves the detection accuracy problem of the traditional method, reduces the omission factor, improves the detection accuracy, improves the universality of detection, is more suitable for detecting the zebra stripes under the unfavorable environment conditions such as blurred images, darkness and the like, is also more suitable for detecting the zebra stripes with different forms, and is not limited by the zebra stripe interested areas determined according to the parallel edges and the white areas.
In practical application, the deep learning method adopts a deep learning fast R-CNN algorithm to detect zebra crossings appearing in images. The test network was trained with 400 training samples, approximately containing more than 1200 zebra crossings. And detecting zebra crossings in the test pictures through the trained model to obtain a horizontal rectangular frame which is used as an interested region in post-treatment. Referring to fig. 2, a schematic diagram of a zebra line image detected by a zebra line detection network is shown.
In this embodiment, the monitoring image of the traffic intersection to be collected is detected by using a deep-learning zebra crossing detection network, and a horizontal rectangular frame for determining the zebra crossing position is set in the image position area of each zebra crossing identified in the monitoring image.
In the embodiment, the zebra stripes are identified through a fast R-CNN deep learning target detection algorithm, the color characteristics of the zebra stripes are extracted, and the positions of the zebra stripes are determined through a clustering algorithm and contour extraction. Because of the existence of the differences in the actual scenes, the deep learning fast R-CNN algorithm in the step S11 plays a role in learning the zebra stripes of various different scenes and accurately identifying the zebra stripes in different actual scenes, and compared with other traditional methods, the deep learning method has universality and stronger inclusion.
And S12, performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing to generate a binarized image of the monitoring image.
In this embodiment, the S12 includes: performing color space conversion on the traffic monitoring image in the horizontal rectangular frame; drawing a cumulative histogram according to the proportion of the pixel points corresponding to the brightness values after the color space conversion in the total number of the pixel points; a proportional threshold is set in the cumulative histogram as a demarcation value of the white pixel point of the image binarization.
Specifically, the horizontal rectangular frame 21 obtained by the deep learning detection algorithm in step S11 is used as a region of interest, and image binarization is performed in the region, and the binarization method is a cumulative histogram method.
The color cumulative histogram binarization method is a self-adaptive threshold method, and is characterized in that the cumulative histogram is manufactured by counting the proportion of pixel points corresponding to all values of Y channels, namely brightness channels 0-255, in a YCbCr color space to the total number of pixel points, and the binarization is performed on a region of interest by manually setting the proportion of white pixel points after binarization.
Due to the fact that the brightness of the zebra stripes in the images is different due to the fact that the light rays in the natural environment are different, a part of the brightest area in the interested area needs to be selected through an adaptive method to obtain the approximate position range of the zebra stripes. In the step S12, the color space of the RGB image is first converted into the YCbCr color space. The YCbCr color space Y is a luminance component of color, so extracting a region with highest luminance in the region of interest is more favorable to separating zebra stripes under different lighting conditions than other binarization methods. The conversion formula is as follows:
compared with other image binarization methods, the binary image obtained by using the color cumulative histogram method is more suitable for shooting scenes by traffic cameras with different image brightness.
In this embodiment, white areas of the binary image are clustered, an unsupervised DBSCAN algorithm is utilized to cluster according to density, and each white line can be clustered for a large-area zebra crossing near, so that the zebra crossing can be more accurately segmented, and the white areas far away from the main body of the zebra crossing can be segmented, so that the positioning is more accurate.
S13, clustering white pixel points in the binarized image, and removing noise areas of non-zebra crossings;
specifically, the region 22 of white pixels in the binary image is clustered by using a DBSCAN algorithm, and pixels in the non-zebra stripes region 24 are removed, so that the segmentation according to zebra stripes is realized. The DBSCAN is a clustering analysis algorithm based on density, two parameters are required to scan radius parameter epsilon and minimum points required for forming a high-density region, namely minimum inclusion points, and the zebra stripes in the region of interest and noise which is binarized into white can be clustered respectively by selecting a certain scanning radius parameter epsilon and the minimum points required for forming the high-density region.
In this embodiment, the S13 includes:
a. in each horizontal rectangular frame area, performing density analysis on the areas of all the white pixel points in the binarized image according to a preset size parameter;
the horizontal rectangular frames 21 of each detected zebra stripes in the step S11 are clustered according to a proper parameter designed according to the size, so that the zebra stripes with different sizes can be effectively clustered in a self-adaptive manner, and the zebra stripes and noise can be clustered by a DBSCAN algorithm for each rectangular frame with different sizes.
b. The densely degree analysis is to analyze the pixel point distribution positions of the white pixel point areas by using a DBSCAN algorithm, determine a position distribution gravity center by the pixel point distribution positions, determine the average position of the white pixel points in each horizontal rectangular frame area one by one according to the position distribution gravity center of the densely degree analysis, and take the average position as a clustering gravity center;
and respectively calculating the clustering gravity centers of each class obtained by the clustering algorithm, wherein the obtained gravity centers can be considered as the average positions of the points in the class due to the same pixel point density.
c. Performing linear fitting on all the cluster centers of gravity through a linear fitting algorithm;
by straight-fitting the center points to obtain a fitted straight line 27, the center of gravity of noise is greater from the center of gravity 26 of the cluster on the fitted straight line to the straight line, so that the elimination is set to black, and other pixels remain, such as the center of gravity 25 of the cluster on the fitted straight line as the pixel representing the zebra stripes. While the line fitted by the cluster centroid 25 on the left fitted line may represent the zebra crossing direction.
d. And eliminating the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line.
In this embodiment, the step of removing the area of the white pixel point corresponding to the cluster center deviating from the straight line includes: determining the area of the white pixel point corresponding to the clustering center deviating from the straight line as a noise area; and eliminating the noise area.
In this embodiment, the cluster centroid is a density centroid of a pixel point determined within the horizontal rectangular frame.
In this embodiment, the cluster analysis is performed according to a preset scan radius parameter and a minimum inclusion point parameter.
S14, obtaining an edge detection line 23 through edge detection in the binarized image after cluster analysis, selecting a contour extreme point A, B, C, D as shown in fig. 2, and extracting a zebra crossing contour extraction to locate a zebra crossing region.
In this embodiment, by extracting the outlines of the edge detection lines 23 on both sides of the zebra stripes and selecting the outline extremum point A, B, C, D, noise interference can be eliminated, and a polygonal zebra stripe outline can be obtained.
The present embodiment also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the positioning method of a zebra stripes.
Those of ordinary skill in the art will appreciate that: all or part of the steps for implementing the method embodiments described above may be performed by computer program related hardware. The aforementioned computer program may be stored in a computer readable storage medium. The program, when executed, performs steps including the method embodiments described above; and the aforementioned storage medium includes: various media that can store program code, such as ROM, RAM, magnetic or optical disks.
The embodiment solves the problems that the universality of the traditional method is not strong and the detection frame of the deep learning method does not reach the ideal positioning accuracy, combines the advantages of the deep learning method and the traditional method, mutually compensates the defects, and achieves the accurate positioning effect of the zebra stripes of the traffic intersections.
Example two
The embodiment provides a positioning system of zebra stripes, the positioning system of zebra stripes includes: the position selection module is used for detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in the image position area of each zebra crossing identified in the monitoring image; the binarization processing module is used for carrying out color space conversion on the monitoring image in the horizontal rectangular frame and carrying out image binarization processing so as to generate a binarized image of the monitoring image; the clustering processing module is used for carrying out clustering analysis on white pixel points in the binarized image and eliminating noise areas of non-zebra crossings; and the positioning module is used for selecting contour extreme points through edge detection in the binary image after cluster analysis, extracting zebra crossing contour extraction and positioning a zebra crossing region.
The zebra stripes positioning system provided in this embodiment will be described in detail with reference to the drawings. The zebra crossing positioning system of the embodiment is applied to the zebra crossing positioning method shown in fig. 1 and 2.
Referring to fig. 3, fig. 3 is a schematic system diagram of a zebra crossing positioning system according to an embodiment of the invention. As shown in fig. 3, the zebra stripes positioning system 3 includes: the device comprises a position selection module 31, a binarization processing module 32, a clustering processing module 33 and a positioning module 34.
Detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network by using a position selection module 31, and setting a horizontal rectangular frame for determining the position of the zebra crossing in an image position area of each zebra crossing identified in the monitoring image;
specifically, the location selection module 31 is configured to detect the collected monitoring image of the traffic intersection with a deep-learning zebra crossing detection network, and set a horizontal rectangular frame for determining the zebra crossing location in the image location area of each zebra crossing identified in the monitoring image.
Performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing through a binarization processing module 32 to generate a binarized image of the monitoring image;
specifically, the binarization processing module 32 is configured to perform color space conversion on the traffic monitoring image in the horizontal rectangular frame; drawing a cumulative histogram according to the proportion of the pixel points corresponding to the brightness values after the color space conversion in the total number of the pixel points; a proportional threshold is set in the cumulative histogram as a demarcation value of the white pixel point of the image binarization.
The clustering processing module 33 is used for clustering white pixel points in the binarized image and removing noise areas of non-zebra crossings;
specifically, the clustering module 33 is configured to perform, in each horizontal rectangular frame area, intensity analysis on areas of all the white pixels in the binary image according to a preset size parameter; determining the average position of the white pixel points in each horizontal rectangular frame area one by one according to the result of the density analysis, and taking the average position as the center of gravity of the cluster; performing straight line fitting on all the cluster centers of gravity; and eliminating the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line.
In this embodiment, a region of white pixel points corresponding to the cluster center deviating from a straight line is determined as a noise region; and eliminating the noise area.
In this embodiment, the cluster centroid is a density centroid of a pixel point determined within the horizontal rectangular frame.
In this embodiment, the cluster analysis is performed according to a preset scan radius parameter and a minimum inclusion point parameter.
And selecting contour extreme points through edge detection in the binary image after cluster analysis by a positioning module 34, and extracting zebra crossing contour extraction to position a zebra crossing region.
It should be noted that, it should be understood that the division of the modules of the above positioning system is merely a division of logic functions, and may be fully or partially integrated into a physical entity or may be physically separated. And these modules may all be implemented in software in the form of calls by the processing element; or can be realized in hardware; the method can also be realized in a form of calling software by a processing element, and the method can be realized in a form of hardware by a part of modules. For example, the x module may be a processing element that is set up separately, may be implemented in a chip of the positioning system, or may be stored in a memory of the positioning system in the form of program codes, and the functions of the x module may be called and executed by a processing element of the positioning system. The implementation of the other modules is similar. In addition, all or part of the modules can be integrated together or can be independently implemented. The processing element described herein may be an integrated circuit having signal processing capabilities. In implementation, each step of the above method or each module above may be implemented by an integrated logic circuit of hardware in a processor element or an instruction in a software form.
For example, the modules above may be one or more integrated circuits configured to implement the methods above, such as: one or more Application Specific Integrated Circuits (ASICs), or one or more microprocessors (DSPs), or one or more Field Programmable Gate Arrays (FPGAs), etc. For another example, when a module is implemented in the form of a processing element scheduler code, the processing element may be a general purpose processor, such as a Central Processing Unit (CPU) or other processor that may invoke the program code. For another example, the modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).
The embodiment solves the problems that the universality of the traditional method is not strong and the detection frame of the deep learning method does not reach the ideal positioning accuracy, combines the advantages of the deep learning method and the traditional method, mutually compensates the defects, and achieves the accurate positioning effect of the zebra stripes of the traffic intersections.
Example III
The present embodiment provides an apparatus comprising: a processor, memory, transceiver, communication interface, or/and system bus; the memory and the communication interface are connected to the processor and the transceiver through the system bus and perform communication with each other, the memory is used for storing a computer program, the communication interface is used for communicating with other devices, and the processor and the transceiver are used for running the computer program to enable the devices to execute the steps of the zebra stripes positioning method according to the first embodiment.
The system bus mentioned above may be a peripheral component interconnect standard (Peripheral Component Interconnect, PCI) bus or an extended industry standard architecture (Extended Industry Standard Architecture, EISA) bus, or the like. The system bus may be classified into an address bus, a data bus, a control bus, and the like. The communication interface is used for realizing communication between the database access device and other devices (such as a client, a read-write library and a read-only library). The memory may comprise random access memory (Random Access Memory, RAM) and may also comprise non-volatile memory (non-volatile memory), such as at least one disk memory.
The processor may be a general-purpose processor, including a central processing unit (Central Processing Unit, CPU for short), a network processor (Network Processor, NP for short), etc.; but also digital signal processors (Digital Signal Processing, DSP for short), application specific integrated circuits (Application Specific Integrated Circuit, ASIC for short), field programmable gate arrays (Field Programmable Gate Array, FPGA for short) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
The protection scope of the zebra stripes positioning method is not limited to the execution sequence of the steps listed in the embodiment, and all the schemes of step increase and decrease and step replacement in the prior art according to the principles of the invention are included in the protection scope of the invention.
The invention also provides a zebra crossing positioning system, which can realize the zebra crossing positioning method, but the device for realizing the zebra crossing positioning method comprises but is not limited to the structure of the zebra crossing positioning system listed in the embodiment, and all the structural modifications and substitutions of the prior art according to the principles of the invention are included in the protection scope of the invention.
In summary, the zebra stripes positioning method, system, medium and equipment provided by the invention can rapidly and accurately identify the zebra stripes in the images acquired by the traffic intersection cameras, can be suitable for accurately positioning the zebra stripes in different weather, time and seasons, greatly reduces the false detection rate of the zebra stripes, improves the accuracy of the zebra stripes positioning, provides a basis for complex vehicle driving analysis of the traffic intersection, and effectively overcomes various defects in the prior art so as to have high industrial utilization value.
The above embodiments are merely illustrative of the principles of the present invention and its effectiveness, and are not intended to limit the invention. Modifications and variations may be made to the above-described embodiments by those skilled in the art without departing from the spirit and scope of the invention. Accordingly, it is intended that all equivalent modifications and variations of the invention be covered by the claims, which are within the ordinary skill of the art, be within the spirit and scope of the present disclosure.
Claims (8)
1. The zebra stripes positioning method is characterized by comprising the following steps:
detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in an image position area of each identified zebra crossing in the monitoring image;
performing color space conversion on the monitoring image in the horizontal rectangular frame, and performing image binarization processing to generate a binarized image of the monitoring image;
clustering and analyzing white pixel points in the binary image, and removing noise areas of non-zebra crossings; in each horizontal rectangular frame area, performing density analysis on the areas of all the white pixel points in the binarized image according to a preset size parameter; determining the average position of the white pixel points in each horizontal rectangular frame area one by one according to the result of the density analysis, and taking the average position as the center of gravity of the cluster; performing straight line fitting on all the cluster centers of gravity; removing the areas of the white pixel points corresponding to the cluster gravity centers deviating from the straight line; the removing the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line comprises the following steps: determining the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line as a noise area; removing the noise area;
and selecting contour extreme points in the binarized images after cluster analysis through edge detection, and extracting zebra stripes to extract the zebra stripes so as to locate zebra stripes.
2. The method according to claim 1, wherein before the step of detecting the collected monitoring image of the traffic intersection with a deep-learning zebra crossing detection network and setting a horizontal rectangular frame for determining the zebra crossing position in the image position area of each zebra crossing identified in the monitoring image, the method further comprises:
training a deep learning zebra crossing detection model by the pre-collected monitoring images of a plurality of traffic intersections, and generating the zebra crossing detection network.
3. The method according to claim 1, wherein the step of performing color space conversion on the monitor image in the horizontal rectangular frame and performing image binarization processing to generate a binarized image of the monitor image includes:
performing color space conversion on the traffic monitoring image in the horizontal rectangular frame;
drawing a cumulative histogram according to the proportion of the pixel points corresponding to the brightness values after the color space conversion in the total number of the pixel points;
a proportional threshold is set in the cumulative histogram as a demarcation value of the white pixel point of the image binarization.
4. The method for locating a zebra stripes of claim 1,
and the cluster gravity center is the density gravity center of the pixel points determined in the horizontal rectangular frame.
5. The method for locating a zebra stripes of claim 1,
the clustering analysis is based on preset scanning radius parameters and minimum inclusion point parameters.
6. A zebra crossing positioning system, comprising:
the position selection module is used for detecting the collected monitoring image of the traffic intersection by using a deep-learning zebra crossing detection network, and setting a horizontal rectangular frame for determining the position of each zebra crossing in the image position area of each zebra crossing identified in the monitoring image;
the binarization processing module is used for carrying out color space conversion on the monitoring image in the horizontal rectangular frame and carrying out image binarization processing so as to generate a binarized image of the monitoring image;
the clustering processing module is used for carrying out clustering analysis on white pixel points in the binarized image and eliminating noise areas of non-zebra crossings; in each horizontal rectangular frame area, performing density analysis on the areas of all the white pixel points in the binarized image according to a preset size parameter; determining the average position of the white pixel points in each horizontal rectangular frame area one by one according to the result of the density analysis, and taking the average position as the center of gravity of the cluster; performing straight line fitting on all the cluster centers of gravity; removing the areas of the white pixel points corresponding to the cluster gravity centers deviating from the straight line; the removing the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line comprises the following steps: determining the area of the white pixel point corresponding to the cluster gravity center deviating from the straight line as a noise area; removing the noise area;
and the positioning module is used for selecting contour extreme points through edge detection in the binary image after cluster analysis, extracting zebra crossing contour extraction and positioning a zebra crossing region.
7. A computer-readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements a method for locating a zebra stripes as claimed in any one of claims 1 to 5.
8. An apparatus, comprising: a processor and a memory;
the memory is used for storing a computer program, and the processor is used for executing the computer program stored by the memory, so that the device executes the positioning method of the zebra stripes according to any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910185277.9A CN111695373B (en) | 2019-03-12 | 2019-03-12 | Zebra stripes positioning method, system, medium and equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910185277.9A CN111695373B (en) | 2019-03-12 | 2019-03-12 | Zebra stripes positioning method, system, medium and equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111695373A CN111695373A (en) | 2020-09-22 |
CN111695373B true CN111695373B (en) | 2024-02-02 |
Family
ID=72475678
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910185277.9A Active CN111695373B (en) | 2019-03-12 | 2019-03-12 | Zebra stripes positioning method, system, medium and equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111695373B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112241714B (en) * | 2020-10-22 | 2024-04-26 | 北京字跳网络技术有限公司 | Method and device for identifying designated area in image, readable medium and electronic equipment |
CN112446315B (en) * | 2020-11-19 | 2022-05-31 | 武汉中海庭数据技术有限公司 | High-precision map zebra crossing fusion method, system, server and storage medium |
CN112633151B (en) * | 2020-12-22 | 2024-04-12 | 浙江大华技术股份有限公司 | Method, device, equipment and medium for determining zebra stripes in monitoring images |
CN113435350A (en) * | 2021-06-30 | 2021-09-24 | 浙江大华技术股份有限公司 | Traffic marking detection method, device, equipment and medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104809433A (en) * | 2015-04-21 | 2015-07-29 | 电子科技大学 | Zebra stripe detection method based on maximum stable region and random sampling |
CN105718870A (en) * | 2016-01-15 | 2016-06-29 | 武汉光庭科技有限公司 | Road marking line extracting method based on forward camera head in automatic driving |
CN105893949A (en) * | 2016-03-29 | 2016-08-24 | 西南交通大学 | Lane line detection method under complex road condition scene |
JP2017223511A (en) * | 2016-06-14 | 2017-12-21 | 日本電信電話株式会社 | Road structuring device, road structuring method and road structuring program |
-
2019
- 2019-03-12 CN CN201910185277.9A patent/CN111695373B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104809433A (en) * | 2015-04-21 | 2015-07-29 | 电子科技大学 | Zebra stripe detection method based on maximum stable region and random sampling |
CN105718870A (en) * | 2016-01-15 | 2016-06-29 | 武汉光庭科技有限公司 | Road marking line extracting method based on forward camera head in automatic driving |
CN105893949A (en) * | 2016-03-29 | 2016-08-24 | 西南交通大学 | Lane line detection method under complex road condition scene |
JP2017223511A (en) * | 2016-06-14 | 2017-12-21 | 日本電信電話株式会社 | Road structuring device, road structuring method and road structuring program |
Non-Patent Citations (2)
Title |
---|
孙伟 ; 张小瑞 ; 唐慧强 ; 张为公 ; 闾军 ; .Hough变换和最小二乘拟合的车道线协调检测.光电工程.2011,(10),全文. * |
闫利 ; 黄亮 ; .街景影像中的斑马线检测与定位.测绘科学.(11),全文. * |
Also Published As
Publication number | Publication date |
---|---|
CN111695373A (en) | 2020-09-22 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111695373B (en) | Zebra stripes positioning method, system, medium and equipment | |
CN107545239B (en) | Fake plate detection method based on license plate recognition and vehicle characteristic matching | |
US8340420B2 (en) | Method for recognizing objects in images | |
CN109271937B (en) | Sports ground marker identification method and system based on image processing | |
CN109271991B (en) | License plate detection method based on deep learning | |
CN112686812B (en) | Bank card inclination correction detection method and device, readable storage medium and terminal | |
Ajmal et al. | A comparison of RGB and HSV colour spaces for visual attention models | |
CN107909081B (en) | Method for quickly acquiring and quickly calibrating image data set in deep learning | |
CN104134200B (en) | Mobile scene image splicing method based on improved weighted fusion | |
CN108960404B (en) | Image-based crowd counting method and device | |
CN106709500B (en) | Image feature matching method | |
Wang et al. | Recognition and localization of occluded apples using K-means clustering algorithm and convex hull theory: a comparison | |
CN109685045A (en) | A kind of Moving Targets Based on Video Streams tracking and system | |
CN103295013A (en) | Pared area based single-image shadow detection method | |
CN111382658B (en) | Road traffic sign detection method in natural environment based on image gray gradient consistency | |
CN113435407B (en) | Small target identification method and device for power transmission system | |
CN111161281A (en) | Face region identification method and device and storage medium | |
CN111161295A (en) | Background stripping method for dish image | |
CN111401364A (en) | License plate positioning algorithm based on combination of color features and template matching | |
CN111695374B (en) | Segmentation method, system, medium and device for zebra stripes in monitoring view angles | |
McFeely et al. | Shadow identification for digital imagery using colour and texture cues | |
TWI498830B (en) | A method and system for license plate recognition under non-uniform illumination | |
CN117475353A (en) | Video-based abnormal smoke identification method and system | |
Pratomo et al. | Parking detection system using background subtraction and HSV color segmentation | |
CN114926635B (en) | Target segmentation method in multi-focus image combined with deep learning 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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |