CN118097581A - Road edge recognition control method and device - Google Patents

Road edge recognition control method and device Download PDF

Info

Publication number
CN118097581A
CN118097581A CN202410516269.9A CN202410516269A CN118097581A CN 118097581 A CN118097581 A CN 118097581A CN 202410516269 A CN202410516269 A CN 202410516269A CN 118097581 A CN118097581 A CN 118097581A
Authority
CN
China
Prior art keywords
data
road
edge
lane
image
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.)
Granted
Application number
CN202410516269.9A
Other languages
Chinese (zh)
Other versions
CN118097581B (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.)
Shandong Leading Intelligent Transportation Technology Co ltd
Original Assignee
Shandong Leading Intelligent Transportation Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shandong Leading Intelligent Transportation Technology Co ltd filed Critical Shandong Leading Intelligent Transportation Technology Co ltd
Priority to CN202410516269.9A priority Critical patent/CN118097581B/en
Priority claimed from CN202410516269.9A external-priority patent/CN118097581B/en
Publication of CN118097581A publication Critical patent/CN118097581A/en
Application granted granted Critical
Publication of CN118097581B publication Critical patent/CN118097581B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Processing (AREA)

Abstract

The invention provides a road edge identification control method and a device, and relates to the technical field of data processing, wherein the method comprises the following steps: respectively calculating the average value of the first data and the second data to obtain fused first data and second data; calculating a dynamic influence factor, and obtaining fusion data according to the fused first data and second data and the dynamic influence factor; pre-positioning the lane lines in the fusion data, and fitting the data points on the lane lines to obtain a lane shape change model; and calculating final road edge data according to the lane shape change model. The invention can effectively extract and retain the key characteristics of the road data, thereby improving the accuracy of road edge identification.

Description

Road edge recognition control method and device
Technical Field
The invention relates to the technical field of data processing, in particular to a road edge identification control method and device.
Background
Along with the increasing development of urban intelligent traffic systems, the accuracy and real-time requirements on road edge identification are also higher and higher, and the road edge identification is a key technology in the fields of intelligent traffic management and the like. However, existing road edge identification techniques may have some drawbacks in practical applications.
For example, existing road edge identification methods are based on conventional image processing techniques, such as edge detection operators and morphological operations. These methods are particularly sensitive when dealing with images that contain significant amounts of noise and interference, and may create false or false recognition situations. Particularly in heavy traffic scenarios, the interference of vehicles, pedestrians and other dynamic elements can cause a great interference with the recognition of road edges.
Disclosure of Invention
The invention aims to solve the technical problem of providing a road edge identification control method and device, which can effectively extract and retain key characteristics of road data so as to improve the accuracy of road edge identification.
In order to solve the technical problems, the technical scheme of the invention is as follows:
in a first aspect, a road edge identification control method includes:
Acquiring road data in the current environment;
preprocessing road data in the current environment to obtain preprocessed road data;
decomposing the preprocessed road data to obtain first data and second data;
respectively calculating the average value of the first data and the second data to obtain fused first data and second data;
calculating a dynamic influence factor, and obtaining fusion data according to the fused first data and second data and the dynamic influence factor;
pre-positioning the lane lines in the fusion data, and fitting the data points on the lane lines to obtain a lane shape change model;
and calculating final road edge data according to the lane shape change model.
Further, decomposing the preprocessed road data to obtain first data and second data, including:
determining the number of layers of wavelet decomposition according to the complexity of the preprocessed road data and the required information granularity;
Carrying out wavelet decomposition on the preprocessed road data;
In the first layer decomposition, the preprocessed road data is filtered in the horizontal direction through a low-pass filter and a high-pass filter, and then one pixel is taken every other row or every other column to obtain an initial low-frequency approximate subgraph and an initial high-frequency detail subgraph;
Filtering and downsampling the initial low-frequency approximation subgraph in a vertical direction to obtain first data;
The initial high frequency detail sub-graph is high pass filtered and downsampled in the vertical direction to obtain second data.
Further, calculating the dynamic impact factor includes:
By passing through Calculating dynamic influence factorsWherein C represents low frequency contrast,/>Represents the maximum value of the low frequency contrast, S represents the low frequency sharpness,/>Represents the maximum value of low frequency sharpness, D represents the high frequency detail intensity,/>Represents the maximum value of the high frequency detail intensity, co represents the high frequency consistency,/>Maximum value representing high frequency uniformity,/>And/>Weight coefficient representing low frequency quality factor,/>And/>Weight coefficient representing high frequency quality factor,/>Representing the low frequency correlation factor,/>Representing a high frequency correlation factor.
Further, obtaining the fused data according to the fused first data, the fused second data and the dynamic influence factor, including:
According to dynamic influencing factors By/>Computing fusion data, wherein/>Pixel value representing the fused data at position (i, j)/>Weights representing the kth second data,/>Representing a low frequency image/>Pixel value at coordinates (i, j)/>Pixel values representing the kth high frequency resolution layer at the (i, j) coordinate locations; i and j are coordinate indexes in the two-dimensional image, representing rows and columns, respectively, and k represents a multi-scale high-frequency decomposition layer.
Further, the pre-positioning of the lane lines in the fusion data includes:
gaussian filtering is carried out on the lane lines in the fusion data so as to obtain filtering data;
calculating the gradient intensity and direction of each data point in the filtering data, inhibiting the response of a non-maximum value along the gradient direction, determining an edge by a double-threshold method, and connecting edge line segments to obtain binarized edge data;
Initializing a Hough space, converting each edge point in the edge data into a curve or a straight line in the Hough space, and accumulating in a corresponding parameter space to obtain accumulated values of all parameter points in the Hough space;
setting a distinguishing threshold according to accumulated values of all parameter points in the Hough space;
and screening the final straight line according to the distinguishing threshold value to realize the pre-positioning of the lane line.
Further, fitting the data points on the lane lines to obtain a lane shape change model, including:
extracting coordinate data of a group of lane line data points from the edge data;
determining a quadratic polynomial mathematical model according to the shape and complexity of the lane lines;
constructing an observation matrix according to a quadratic polynomial mathematical model, wherein the observation matrix comprises values of a basis function used for fitting the mathematical model on the positions of data points of the lane lines;
assembling the ordinate of the lane line data points into an observation vector;
And solving parameters of a quadratic polynomial mathematical model through the observation matrix and the observation vector, wherein the parameters of the quadratic polynomial mathematical model are coefficients of a lane shape change model.
Further, according to the lane shape change model, final road edge data is calculated, including:
Setting a search area in the edge data according to the lane shape change model, and searching for the actual lane line edge;
Detecting edges in a set search area;
matching the detected edge with a lane shape change model to obtain a matched edge point;
Fitting again according to the matched edge points to obtain the final lane line shape;
And determining the edge position of the road according to the final lane line shape.
In a second aspect, a road edge recognition control apparatus includes:
the acquisition module is used for acquiring road data in the current environment;
the preprocessing module is used for preprocessing the road data in the current environment to obtain preprocessed road data;
the decomposing module is used for decomposing the preprocessed road data to obtain first data and second data; respectively calculating the average value of the first data and the second data to obtain fused first data and second data;
The calculation module is used for calculating dynamic influence factors and obtaining fusion data according to the fused first data and second data and the dynamic influence factors;
The processing module is used for pre-positioning the lane lines in the fusion data and fitting the data points on the lane lines to obtain a lane shape change model; and calculating final road edge data according to the lane shape change model.
In a third aspect, a computing device includes:
one or more processors;
And a storage means for storing one or more programs that, when executed by the one or more processors, cause the one or more processors to implement the method.
In a fourth aspect, a computer readable storage medium has a program stored therein, which when executed by a processor, implements the method.
The scheme of the invention at least comprises the following beneficial effects:
The low frequency and the second data are obtained by decomposing the preprocessed road data, and the average values of the low frequency and the second data are calculated respectively to be fused, so that the key characteristics of the road data can be effectively extracted and reserved in the process, and the accuracy of road edge identification is improved.
By setting the dynamic influence factors, the fusion data can be dynamically adjusted according to the image characteristics under different environmental conditions, and the robustness and the adaptability of the identification method are enhanced.
By pre-positioning the lane lines and fitting the data points, a lane shape change model is established, and the shape and trend of the lane lines can be described more accurately, so that the accuracy of road edge identification is further improved.
Drawings
Fig. 1 is a flowchart of a road edge recognition control method according to an embodiment of the present invention.
Fig. 2 is a schematic flow chart of decomposing pre-processed road data to obtain first data and second data in the road edge recognition control method according to the embodiment of the present invention.
Fig. 3 is a schematic diagram of a road edge recognition control device according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
As shown in fig. 1, an embodiment of the present invention proposes a road edge recognition control method, which includes the following steps:
Step 11, obtaining road data in the current environment;
Step 12, preprocessing the road data in the current environment to obtain preprocessed road data;
step 13, decomposing the preprocessed road data to obtain first data and second data;
Step 14, respectively calculating the average value of the first data and the second data to obtain fused first data and second data;
step 15, calculating a dynamic influence factor, and obtaining fusion data according to the fused first data and second data and the dynamic influence factor;
step 16, pre-positioning the lane lines in the fusion data, and fitting the data points on the lane lines to obtain a lane shape change model;
and step 17, calculating final road edge data according to the lane shape change model.
In the embodiment of the invention, the road data is a road image, the fusion data is a fusion image, and the preprocessing can improve the image quality, reduce noise and unnecessary details and highlight the road edge characteristics. The image decomposition can separate different frequency components in the image, is favorable for extracting more image characteristic information, and can more effectively identify the road edge especially for complex road environments. By calculating the average value of the subgraphs, random noise in the images can be reduced, and main image characteristics are reserved, so that the fused images are smoother and have obvious characteristics. The dynamic influence factors are set, so that the proportion of different frequency components can be adjusted by the fusion data according to actual conditions, and the adaptability of images and the accuracy of road edge identification are improved. The pre-positioning and fitting operation is helpful for accurately identifying and tracking the lane lines, and the morphological change of the road edge can be better understood and predicted by establishing a lane line morphological change model. And the morphological change model is utilized to accurately identify the road edge, so that the driving safety and stability are improved.
In another preferred embodiment of the present invention, the step 11 may include:
step 111, setting initial parameters of a camera, including exposure time, focal length, white balance and the like;
Step 112, starting the camera equipment, setting the camera to be in a continuous capturing mode, adjusting the resolution and the frame rate of the camera, capturing the road image from the camera in real time, and transmitting the road image to the image processing module; reading a captured color image consisting of three color channels of red (R), green (G), blue (B); converting the RGB value of each pixel point into a gray value; by passing through Calculating the gray value/>, of each pixel pointAnd generates a new single-channel gray scale image.
Step 113, determining a distance parameter d and an angle parameterDistance parameter d and angle parameter/>Determining the relative position and direction between pixel pairs in the gray level co-occurrence matrix; traversing the gray level image, and finding a distance d and a direction/> from each pixel point in the imageCorresponding pixel points of the two pixel points are recorded; calculating the occurrence frequency of all gray value pairs, and constructing a gray co-occurrence matrix P (i, j), wherein i and j respectively represent two gray levels of a pixel pair, and P (i, j) represents the occurrence frequency or the frequency of the pixel pair with the gray level of i and j; from gray co-occurrence matrixExtracting contrast eigenvalues/>Wherein R, G and B represent the values of red, green, and blue color channels of the pixel point, respectively, and the number of L gray levels is 256 in the gray image (8-bit gray image); based on the history data, a threshold value is set for judging whether the image contrast is sufficiently high. For example, a value may be set, such as threshold=100; comparing the calculated contrast characteristic with a set threshold value, and if the contrast is greater than or equal to the contrast threshold value, considering that the contrast of the image is high enough; otherwise, the contrast of the image is considered to be low; and scoring the image according to the contrast calculation result and the set threshold value.
Step 114, setting a scoring rule according to the comparison result of the contrast and the threshold value, for example, the following rules may be set: if the contrast is greater than 120% of the threshold, the score is "good"; if the contrast is between 80% and 120% of the threshold, then a score of "good"; scoring "medium" if the contrast is between 50% and 80% of the threshold; if the contrast is less than 50% of the threshold, the score is "bad"; and scoring the image according to the calculated contrast and the set scoring rule. The score may be a continuous value (e.g., the contrast value itself) or a class label (e.g., "good," "medium," "bad"). Recording and outputting scoring results: the scoring of the image is recorded and may be output to a log, database or user interface.
Step 115, setting an initial population size (e.g., N individuals), each individual representing a set of camera parameters (exposure time, focal length, white balance, etc.); setting a search range and a step length for each parameter, and ensuring that the search process can cover all possible optimization spaces; performing actual camera settings for each individual (i.e., each set of camera parameters); capturing an image using the parameters and calculating a gray level co-occurrence matrix (GLCM) of the image according to the steps described previously; extracting contrast characteristics from the GLCM, and giving out image quality scores according to a set threshold and a scoring rule; taking the score as an fitness value of the individual; selecting excellent individuals to enter the next generation according to fitness values (image quality scores), wherein the selection is achieved by a roulette selection method, the purpose of the selection being to preserve excellent genes (i.e. camera parameter combinations) making them more likely to be inherited in the next generation; randomly pairing the selected individuals, and performing crossing operation at a certain crossing rate; the crossover operation may be a single point crossover, with the aim of combining the excellent genes of different individuals, resulting in new, possibly more excellent, individuals; performing mutation operation on the newly generated individuals with a certain mutation rate; the variation can be to randomly change the value of a certain parameter so as to increase the diversity of the population and avoid sinking into local optimum; repeating the steps until the preset iteration times are reached; in the iterative process, recording and outputting the optimal individual and fitness value of each generation, and outputting the optimal camera parameter combination and the corresponding image quality fraction; the actual camera settings are adjusted according to these parameters to obtain a high quality image capturing effect.
For example, in an intelligent traffic system in a certain city, the system needs to accurately identify and analyze road traffic conditions under various weather and lighting conditions to realize optimal control of intelligent traffic signals and smooth traffic flow. In preliminary tests, the system finds that the road image captured from the monitoring camera is not good in quality under certain light and weather conditions, which affects the accuracy of traffic situation analysis and may even lead to erroneous decisions of traffic signals.
To address this problem, the team decides to optimize the image processing modules in the intelligent transportation system. Through deep analysis, the team finds that the parameter setting of the monitoring camera and the selection of the image preprocessing algorithm have a critical influence on the image quality. In particular, under complex environmental conditions such as severe weather, strong light, weak light or shadow, unreasonable parameter setting and algorithm selection can cause image distortion, blurring or insufficient contrast, thereby affecting accurate analysis of traffic conditions.
Thus, the team proceeds to fully optimize the image processing module of the intelligent transportation system. First, parameters of the monitoring camera, such as exposure time, aperture, and white balance, are adjusted to ensure that a high quality road image can be obtained under various illumination and weather conditions. Second, image preprocessing algorithms, including noise reduction, enhancement, contrast adjustment, etc., are improved to further enhance image quality.
By means of the improvement measures, the recognition and analysis capability of the intelligent traffic system on road traffic conditions is remarkably improved. The system can more accurately detect traffic jams, accidents and other abnormal conditions, and timely adjust traffic signals to optimize traffic flow. The improvement provides more reliable and intelligent support for urban traffic management, and is helpful for improving the efficiency and safety of urban traffic.
In order to solve the above problems, the specific implementation steps are as follows:
In an intelligent traffic system in a certain city, in order to ensure accurate identification of road traffic conditions under various complex illumination and weather conditions, a team performs fine adjustment on camera parameters in the system. Several key parameters are selected for optimization, including exposure time, focal length, white balance, gain, etc., and a reasonable adjustment range is set for these parameters.
After the system is started, the monitoring camera is set to be in a continuous capturing mode, and road images are captured in real time. To simplify the subsequent processing, these images are converted into grayscale images. The team adopts the gray level co-occurrence matrix and other methods to extract the key characteristics of the image such as texture, contrast and the like. Based on these features, the quality of the image, in particular the contrast and sharpness, is evaluated and corresponding thresholds are set for determining whether the image meets the traffic situation recognition requirements.
To find the optimal combination of camera parameters, the team sets an initial solution set, each solution representing a particular set of camera parameters. In an actual road environment, a combination of camera parameters for each solution is tested by capturing a road image and evaluating its quality. According to the evaluation result, the parameter combination with the best performance is selected to enter the next round of optimization.
Through multiple iterations and optimizations, including crossover and mutation operations of solutions, the team eventually finds an optimal set of camera parameters. And applying the optimized parameters to a monitoring camera of the intelligent transportation system, and performing field test.
Test results show that under the setting of the optimized parameters, the quality of the road image captured by the camera is remarkably improved, especially under complex illumination and weather conditions. Therefore, the recognition accuracy of the intelligent traffic system to the road traffic condition is also greatly improved, and the false recognition rate is obviously reduced. The reliability and the accuracy of the intelligent traffic system are enhanced, greater convenience and efficiency are brought to urban traffic management, and the whole running level of urban traffic is improved.
In another preferred embodiment of the present invention, the step 12 may include:
Step 121, capturing a road image in the current environment through the monitoring camera with optimized parameter settings. These images are typically color, consisting of three color channels, red (R), green (G), blue (B); the captured color image is converted into a gray image, which can be achieved by calculating the average value of RGB channels of each pixel point or using a specific graying algorithm, and the converted gray image only contains brightness information, so that the subsequent edge detection and feature extraction are facilitated.
Step 122, byNoise reduction of gray scale images to reduce noise and clutter in the images, which may originate from camera sensors, disturbances in the image transmission process, or environmental factors, where/>Representing the filtered image at coordinates/>Pixel values at the pixel locations, the pixel values being calculated by normalized weighted average; /(I)Standard deviation of the gaussian function is shown; k represents half the size of the convolution kernel,Representing the value of the Gaussian function at coordinates (u, v)/(Representing pixel values of the original image at coordinates (x-u, y-v); m (x-u, y-v) represents the value of the mask function at coordinates (x-u, y-v), x being the horizontal coordinates of the pixel (generally increasing from left to right), y being the vertical coordinates of the pixel, u and v being index variables used to traverse all pixels within the filter footprint.
In step 123, in order to improve the visibility of important features of the road edge, the image is subjected to a contrast enhancement process. This may be achieved by means of histogram equalization or contrast-limited adaptive histogram equalization (CLAHE) or the like, which are able to redistribute the luminance values of the image such that the contrast of the image is enhanced, thereby making it easier to distinguish between different objects and edges.
And 124, selecting a proper threshold according to the gray level histogram of the captured road traffic image, and performing binarization processing on the image. In a binarized image, the pixel values will be reduced to two states: 0 (representing black, i.e., non-critical traffic element area) or 255 (representing white, i.e., critical traffic element area of a road, vehicle, etc.). The processing can highlight key information in the traffic image, and is convenient for subsequent traffic condition identification and analysis.
To determine the optimal binarization threshold, the Otsu algorithm may be used. The algorithm can automatically calculate the threshold value which maximizes the inter-class variance, thereby effectively separating the key traffic elements from the image background.
In addition, according to the actual requirement of the urban intelligent transportation system, a specific region in the image, namely a region of interest (ROI), can be further extracted. For example, the system may focus primarily on the road, vehicle, pedestrian, etc., critical traffic elements in the image, while ignoring surrounding sky, building, or other background information. This can be achieved by setting a suitable clipping region or using advanced image segmentation algorithms.
The extraction of the ROI is critical to improve the processing efficiency and accuracy of the system. Because the subsequent traffic situation recognition and analysis will be focused mainly on these critical areas, unnecessary waste of computing resources is avoided. By the method, the urban intelligent traffic system can recognize and analyze road traffic conditions more quickly and accurately, and provides powerful data support and intelligent decision basis for urban traffic management.
In general, urban intelligent transportation systems are able to more effectively identify and analyze traffic conditions by performing binarization processing and ROI extraction on captured road traffic images.
As shown in fig. 2, in a preferred embodiment of the present invention, the step 13 may include:
Step 131, determining the number of layers of wavelet decomposition according to the complexity of the preprocessed road data and the required information granularity;
step 132, performing wavelet decomposition on the preprocessed road data;
Step 133, in the first layer decomposition, the preprocessed road data is filtered in the horizontal direction through a low-pass filter and a high-pass filter, and then a pixel is taken every other line or column to obtain an initial low-frequency approximate subgraph and an initial high-frequency detail subgraph;
step 134, filtering and downsampling the initial low-frequency approximation subgraph in the vertical direction to obtain first data;
and step 135, performing high-pass filtering and downsampling on the initial high-frequency detail subgraph in the vertical direction to obtain second data.
In the embodiment of the invention, the first data and the second data are respectively obtained by filtering and downsampling the initial low-frequency approximate subgraph and the initial high-frequency detail subgraph in the vertical direction so as to obtain the low-frequency subgraph and the high-frequency subgraph, and the wavelet decomposition can provide information of the image under different scales. By decomposition, the low frequency part (approximate sub-graph) and the high frequency part (detailed sub-graph) of the image can be obtained, which is very useful for analyzing and understanding the local and global features of the image. Wavelet decomposition can be effectively used for image compression and denoising. Because the wavelet transformation has good time-frequency localization characteristics, the wavelet transformation can concentrate important information of an image on a few wavelet coefficients, and is convenient for compression storage. Meanwhile, noise can be effectively removed and image quality can be improved by setting a threshold processing wavelet coefficient. In the above steps, by filtering in the horizontal and vertical directions, high-frequency and low-frequency information of the image in different directions can be obtained. The wavelet transform has a faster computation speed and higher computation efficiency than the conventional fourier transform. In addition, through layer-by-layer decomposition, information can be selectively processed according to requirements on different decomposition levels, and the processing efficiency is further improved. The number of layers of wavelet decomposition may be adjusted according to the complexity of the image and the granularity of information required. This flexibility allows the method to accommodate different types of road images and different application requirements. Key features in the road image can be extracted more easily by wavelet decomposition.
In another preferred embodiment of the present invention, the step 131 may include: performing two-dimensional discrete Fourier transform on the preprocessed road image, and converting the road image into a frequency domain; calculating the amplitude of the Fourier transform result to form a Fourier spectrum; analyzing the Fourier spectrum, and observing the distribution condition of the high-frequency component and the low-frequency component; the high frequency components correspond to rapidly changing parts of the image, such as edges and texture details, while the low frequency components correspond to smooth regions of the image; the complexity of the image is quantified by calculating the ratio of the high-frequency component to the total energy of the whole frequency spectrum, and the higher the ratio is, the more high-frequency information in the image is indicated, namely the higher the image complexity is; judging the richness of information and the detail change in the image according to the evaluation result; based on the result of the fourier spectrum analysis, evaluating the intensity and distribution of the high frequency components in the image; if the high-frequency components occupy a larger area and are widely distributed, the detail and texture information in the image are rich; if the high frequency components are smaller or concentrated in certain specific areas, the details in the image are relatively less or more single; the purpose of the wavelet decomposition is determined.
The required granularity of information is determined according to the application requirements, e.g. for extracting features, compressing images, or image enhancement etc. For example, if it is for extracting road features, more detailed information may need to be retained; if the image is to be compressed, it may be more important to preserve the main contours of the image and ignore some details; determining the required information granularity, namely the level of detail of the image to be reserved, according to the task requirement; determining which levels of image detail need to be preserved according to requirements of specific tasks (e.g., road condition assessment, vehicle detection, etc.), and more high-frequency detail may need to be preserved for tasks requiring fine analysis; for tasks requiring only a rough contour, the retention of high frequency details can be reduced; setting a proper wavelet decomposition layer number by combining the complexity of the image and the information granularity requirement; the number of layers of wavelet decomposition is set by comprehensively considering the complexity of the image and the required information granularity, if the complexity of the image is high and the level of detail to be reserved is also high, the number of decomposition layers may need to be increased to extract more high-frequency information, and if the complexity of the image is low or only rough contour information needs to be reserved, the number of decomposition layers may be appropriately reduced to reduce the computational complexity.
Step 132, setting the number of layers (denoted as N) of the wavelet decomposition according to the appropriate number of layers determined in step 131, which determines the depth of the wavelet decomposition, i.e. how many different scale sub-images the image is to be decomposed into. A wavelet basis function, e.g., haar wavelet, suitable for analyzing road image features is selected. Initializing wavelet decomposition, and setting parameters of wavelet decomposition, including a decomposition layer number N and a wavelet basis function; using the selected wavelet basis function, N-layer wavelet decomposition is performed on the preprocessed road image, in each layer of decomposition, the original image or the low frequency approximation subgraph (LL) of the previous layer will be decomposed into four subgraphs:
low frequency approximation subgraph (LL): representing the general outline and the main information of the image.
Horizontal high frequency detail subgraph (LH): representing high frequency detail information of the image in the horizontal direction, such as horizontal edges.
Vertical high frequency detail subgraph (HL): representing high frequency detail information of the image in the vertical direction, such as vertical edges.
Diagonal high frequency detail subgraph (HH): high frequency detail information representing the image in the diagonal direction, such as diagonal edges and textures.
After N layers of decomposition, n+1 low frequency approximation subgraphs (each layer has one LL subgraph) and 3N high frequency detail subgraphs (each layer has three subgraphs of LH, HL, HH) will be obtained.
In step 133, the preprocessed road image is convolved with the low-pass filter and the high-pass filter, so as to perform filtering in the horizontal direction, and after filtering, the image is downsampled, that is, one pixel is taken every other row (or one column, depending on the filtering direction), so that a low-frequency approximate sub-image (LL 1) and a high-frequency detail sub-image (LH 1) in the horizontal direction can be obtained.
And step 134, performing convolution operation on the low-frequency approximation subgraph (LL 1) obtained in the previous step and the low-pass filter in the vertical direction, filtering, and performing downsampling in the vertical direction to obtain a low-frequency approximation subgraph (LL 2) of the next layer.
In step 135, the high-frequency detail sub-graph (LH 1) obtained by the decomposition of the first layer and the high-pass filter are convolved in the vertical direction, and after filtering, downsampling is performed in the vertical direction to obtain the high-frequency detail sub-graph (the high-frequency component in the vertical direction is denoted as LH 2) of the first layer.
For example, in an urban intelligent transportation system, a complex traffic scene image is processed that contains roads, vehicles, pedestrians, and various other traffic elements. In order to accurately extract and analyze these elements in order to understand traffic conditions and make corresponding management decisions, it is decided to employ wavelet decomposition techniques.
By wavelet decomposition, the complex traffic image can be decomposed into sub-images of multiple dimensions and directions. Therefore, the images can be finely analyzed in different scales and directions, so that key traffic elements such as vehicles, pedestrians and the like can be better identified and tracked, the accuracy of traffic condition analysis is improved, and important data support is provided for an intelligent traffic system. By the mode, the urban intelligent traffic system can monitor and manage urban traffic more effectively, and traffic efficiency and safety are improved.
The specific calculation process comprises the following steps: step 131, performing two-dimensional discrete Fourier transform on the road image to obtain a frequency domain representation thereof; the amplitude of the fourier spectrum is calculated and the distribution of the high frequency and low frequency components is observed. The high-frequency components are found to be larger and widely distributed, so that the detail and texture information in the image are rich; according to task demands (road condition analysis and vehicle detection), more high-frequency details need to be reserved; the number of layers of wavelet decomposition is set to 3 in combination with the image complexity and information granularity requirements. In step 132, a Haar wavelet is selected as a wavelet basis function, and 3-layer wavelet decomposition is performed on the road image because the Haar wavelet is simple to calculate and can effectively extract edge information. In each layer decomposition, 4 subgraphs are obtained: LL, LH, HL and HH are decomposed by 3 layers to obtain 4 low-frequency approximate subgraphs (LL 1, LL2, LL3, LL 4) and 9 high-frequency detail subgraphs (3 LH,3 HL,3 HH). In the first layer decomposition, the road image is convolved with the low-pass and high-pass filters, and then downsampled to obtain LL1 and LH1 subgraphs, the LL1 subgraph is low-pass filtered and downsampled in the vertical direction to obtain LL2 subgraphs, and the LH1 subgraph is high-pass filtered and downsampled in the vertical direction to obtain LH2 subgraphs, which can similarly obtain all other subgraphs.
In the embodiment of the invention, the characteristics of the image can be extracted on a plurality of scales through wavelet decomposition; through downsampling operation, the dimensionality of data can be reduced, the calculation efficiency of subsequent processing is improved, and as a plurality of high-frequency detail subgraphs are reserved, edge and texture information in an image can be captured well, wavelet decomposition provides flexible decomposition layer numbers and the capability of selecting different wavelet basis functions, and adjustment can be carried out according to specific task requirements.
In another preferred embodiment of the present invention, the step 14 may include:
in the process of computing the image fusion, the original image is decomposed into first data and second data. The first data contains mainly the general outline and the main information of the image, while the second data contains the details and texture information of the image. Step 14 involves calculating the average of these sub-images to preserve the main features and details of the original image during the fusion process, wherein the first data and the second data are the low frequency sub-image and the high frequency sub-image obtained by filtering and downsampling the initial low frequency approximation sub-image and the initial high frequency detail sub-image, respectively, in the vertical direction.
The specific calculation process is as follows:
Calculating the average value of the low-frequency subgraphs, wherein for the low-frequency subgraphs, the average value of pixel values is calculated, and two low-frequency subgraphs A and B are assumed, wherein the sizes of the two low-frequency subgraphs A and B are M multiplied by N; traversing each pixel position (i, j) of the two low frequency subgraphs, wherein i represents a row index and j represents a column index; for each location (i, j), calculating an average of the pixel values of A and B at that location; and (3) assigning the calculated average value to the pixel of the fused low-frequency subgraph at the (i, j) position.
And calculating the average value of the high-frequency subgraphs, wherein the average calculation of the high-frequency subgraphs is similar to that of the low frequency, but the detail information is processed, each pixel position (i, j) of the two high-frequency subgraphs is traversed, the average value of the pixel values A and B at each position (i, j) is calculated, and the result is given to the fused high-frequency subgraphs.
In the embodiment of the invention, the information of a plurality of source images can be fused by calculating the average value, so that a new image containing common characteristics of each source image is created, when a certain source image has data deletion or damage in certain areas, the robustness of the whole image can be improved by fusing with other images, and the average processing of a high-frequency subgraph is beneficial to preserving the detail information in the source image, so that the fused image is richer in detail.
In a preferred embodiment of the present invention, in the step 15, the calculating the dynamic influence factor includes:
By passing through Calculating dynamic influence factorsWherein C represents low frequency contrast,/>Represents the maximum value of the low frequency contrast, S represents the low frequency sharpness,/>Represents the maximum value of low frequency sharpness, D represents the high frequency detail intensity,/>Represents the maximum value of the high frequency detail intensity, co represents the high frequency consistency,/>Maximum value representing high frequency uniformity,/>And/>Weight coefficient representing low frequency quality factor,/>And/>Weight coefficient representing high frequency quality factor,/>Representing the low frequency correlation factor,/>Representing a high frequency correlation factor.
In the embodiment of the invention, key parameters such as low-frequency contrast C, low-frequency definition S, high-frequency detail intensity D, high-frequency consistency Co and the like of an image are collected and measured; the maximum values of these parameters, namely C max、Smax、Dmax and Co max, were determined; and comparing the actual measured value with the corresponding maximum value to obtain a normalized parameter value. For example, the normalized value of the low frequency contrast may be calculated as; Using weight coefficient/>And/>And carrying out weighted summation on the low-frequency contrast and the low-frequency definition to form a comprehensive index of low-frequency quality. Likewise, use/>And/>Carrying out weighted summation on the high-frequency detail intensity and the high-frequency consistency to form a comprehensive index of high-frequency quality; by setting the low frequency correlation factor/>And high frequency correlation factor/>These factors may be determined based on the correlation between the image content and the target application. The weighted low-frequency quality index is carried outMultiplying the weighted high-frequency quality index and/>And multiplying, and finally, adding the two products to obtain the dynamic influence factor.
In another preferred embodiment of the present invention, the low frequency correlation factorAnd high frequency correlation factor/>The calculation process of (2) may be different according to the specific application scenario and requirement, and the following is a specific calculation process:
Low frequency correlation factor Is calculated by (1):
First, low frequency features are extracted from an image, including low frequency contrast, low frequency sharpness, etc., which may be extracted by image processing techniques (e.g., filtering, etc.); according to specific tasks (such as road detection, vehicle identification and the like), the influence of the low-frequency characteristics on the task performance is evaluated by calculating the Pearson correlation coefficient; normalizing the values of the low frequency features to a range (e.g., between 0 and 1); calculating the correlation between the low-frequency characteristic and the task performance by using the normalized low-frequency characteristic value and combining the task performance evaluation result through a linear regression algorithm, wherein the correlation value can be used as a low-frequency correlation factor
High frequency correlation factorIs calculated by (1):
Extracting high-frequency features from the image, such as high-frequency detail intensity and the like, wherein the features can be extracted by image processing technologies such as a high-frequency filter and the like; evaluating the influence of the high-frequency characteristic on the performance of a specific task, and quantifying the correlation between the high-frequency characteristic and the performance of the task by calculating a Pearson correlation coefficient; normalizing the value of the high-frequency characteristic; using normalized high-frequency characteristic value and task performance evaluation result, calculating correlation between high-frequency characteristic and task performance by algorithm, wherein the correlation value can be used as high-frequency correlation factor
The invention comprehensively considers a plurality of quality parameters of the image in low frequency and high frequency, thereby being capable of more comprehensively evaluating the quality of the image; by adjusting the weight coefficient and the correlation factor, the method can be easily adapted to different application scenes and requirements. For example, low frequency contrast may be more emphasized in some applications, while high frequency details may be more emphasized in other applications; by carrying out normalization processing on each parameter, the influence of different parameter units and orders can be eliminated, so that the evaluation result is more accurate.
In a preferred embodiment of the present invention, in the step 15, obtaining the fused data according to the fused first data and second data and the dynamic influence factor includes:
According to dynamic influencing factors By/>Computing fusion data, wherein/>Pixel value representing the fused data at position (i, j)/>Weights representing the kth second data,/>Representing a low frequency image/>Pixel value at coordinates (i, j)/>Pixel values representing the kth high frequency resolution layer at the (i, j) coordinate locations; i and j are coordinate indexes in the two-dimensional image, representing rows and columns, respectively, and k represents a multi-scale high-frequency decomposition layer.
In an embodiment of the invention, dynamic influence factors are utilizedTo combine the information of the first data and the second data, thereby generating a fusion data, wherein the fusion data is a fusion graph. The specific calculation process is as follows:
Determining dynamic impact factors This factor determines the weight of the low frequency information and the high frequency information in the fused data,/>The closer to 1 the value of (2) is between 0 and 1, the greater the influence of the low frequency information is; the closer to 0, the greater the influence of the high-frequency information. Calculating the contribution of the low frequency part,/>Calculating the contribution of the pixel value of the first data at position (i, j) to the fused data; calculating the contribution of the high frequency part, for each second data, first calculating its weighted pixel value/>, at position (i, j)Then, the weighted pixel values of all the second data are summed to obtain the total contribution/>. Finally, this total contribution is (/ >)) Weighted to reflect the importance of the high frequency information in the fused data. Adding the contribution of the low frequency part and the contribution of the high frequency part to obtain the pixel value/>, at the position (i, j), of the fusion data
In the embodiment of the invention, the dynamic influence factors are adjustedAnd weight of the second data/>The method can flexibly control the proportion of low-frequency information and high-frequency information in the fused data so as to adapt to different application scenes and requirements, and can simultaneously reserve the rough outline and main information of the first data and the detail and texture information of the second data, so that the fused image contains the main characteristics of the original image and also reserves abundant detail information. Through reasonable weight distribution and adjustment of dynamic influence factors, fusion data with higher quality and better visual effect can be generated, and the overall quality and user experience of image processing are improved.
In a preferred embodiment of the present invention, in the step 16, the pre-positioning the lane lines in the fused data includes:
Step 161, performing gaussian filtering on the lane lines in the fusion data to obtain filtered data;
Step 162, calculating the gradient strength and direction of each data point in the filtered data, restraining the response of non-maximum values along the gradient direction, determining the edge by a double-threshold method, and connecting edge line segments to obtain binarized edge data;
step 163, initializing a hough space, converting each edge point in the edge data into a curve or a straight line in the hough space, and accumulating in the corresponding parameter space to obtain the accumulated value of each parameter point in the hough space;
step 164, setting a distinguishing threshold according to the accumulated value of each parameter point in the hough space;
And step 165, screening the final straight line according to the distinguishing threshold value to realize the pre-positioning of the lane line.
In the embodiment of the present invention, in step 161, the filtered data is a filtered image, and the gaussian filtering is implemented by convolving each data point in the image with a gaussian function, so as to implement smoothing processing of the image, reduce noise and details, and retain a larger image structure. In step 162, the data points are pixel points, the edge data is an edge image, and for the filtered image, gradient strength and direction of each data point are calculated; comparing the gradient intensity of the current data point with the gradient intensity of the adjacent data point in the gradient direction, and if the gradient intensity of the current data point is not the maximum, suppressing the current data point, namely setting the value of the current data point to 0; setting two thresholds, a high threshold and a low threshold, wherein data points with gradient strength higher than the high threshold are determined as edges; data points below the low threshold are excluded; data points between the two are also considered edges if connected to data points determined to be edges; and connecting the determined edge points to form continuous edge line segments.
The hough transform is used to detect simple shapes in the image, such as straight lines and circles, step 163. For line detection, the hough transform converts a line in image space into a point in parameter space. The corresponding points in the parameter space are accumulated by the accumulator, so that the parameters of the straight line can be obtained. In step 164, a threshold is set in the hough space according to the magnitude of the accumulated value, and the parameter points with the accumulated value higher than the threshold are considered as valid straight line parameters. In step 165, parameter points with accumulated values higher than a set threshold are selected from the hough space, and the points represent straight lines in the image. These lines are pre-positions of the lane lines.
For example, assume a fused road image of 640x480 pixels in size, obtained by a multi-source image fusion technique, that has fused information from different sensors, highlighting the features of the lane lines. In this image, two white lane lines can be clearly seen, which extend in the horizontal direction of the image, clearly dividing the road into three sections.
First, this image is subjected to gaussian filtering. The image is convolved by selecting a suitable gaussian kernel size, e.g., 5 x 5, and a moderate standard deviation, e.g., 1.0. By doing so, noise and details in the image can be effectively reduced, while retaining the main structure of the lane lines. The filtered image appears smoother and the contours of the lane lines become clearer.
Next, a Canny edge detection algorithm is used to calculate the gradient strength and direction for each pixel point in the filtered image. In the process, the gradient in the horizontal direction and the gradient in the vertical direction are calculated through a Sobel operator, and then the gradient in the two directions are combined to obtain the gradient strength and the gradient direction of each pixel point. Next, non-maximum suppression techniques are applied to refine the edges, i.e. to preserve only the pixels of local maximum gradient intensity, resulting in a finer edge image. To further remove weak edges and outliers, a double thresholding method is used for processing. A lower and a higher threshold value, e.g. 50 and 150, are set. Pixels with gradient intensity higher than 150 are determined as edges; pixels below 50 are excluded; pixels between 50 and 150 are also considered edges if connected to pixels determined to be edges. Through this series of operations, a binarized edge image is obtained in which the lane lines are clearly delineated.
Now, hough transforms are applied to detect straight lines in these edge images. In hough space, each line can be determined by its polar representation (ρ, θ). By traversing each non-zero pixel point in the edge image, a set of (ρ, θ) values is calculated from its coordinates and gradient direction, and then accumulated in hough space. Thus, the pixel points representing the same line are accumulated at the same position in the hough space, so as to form a peak value.
Finally, a suitable discrimination threshold, such as 80% of the accumulated value, is set to screen the line parameters representing the lane lines. Only the parameter points for which the accumulated value is above this threshold will be considered valid straight line parameters. By means of the parameter points, the positions and the directions of the lane lines in the image can be restored. By means of the concrete technical scheme, the lane line pre-positioning in the fusion road image is successfully achieved. The method is high in accuracy and robustness, and is suitable for various roads and illumination conditions.
According to the invention, through the steps of Gaussian filtering, gradient calculation and the like, the edge information of the lane line can be extracted more accurately. The hough transform has a certain robustness to noise and image deformation, so that lane lines can be stably detected under different road and illumination conditions.
In a preferred embodiment of the present invention, in the step 16, the fitting is performed on the data points on the lane lines to obtain a lane shape change model, which includes:
Step 166, extracting coordinate data of a set of lane line data points from the edge data;
step 167, determining a quadratic polynomial mathematical model according to the shape and complexity of the lane lines;
Step 168, constructing an observation matrix according to the quadratic polynomial mathematical model, wherein the observation matrix comprises values of a basis function for fitting the mathematical model on the positions of data points of the lane lines;
Step 169, assembling the ordinate of the lane line data points into an observation vector; and solving parameters of a quadratic polynomial mathematical model through the observation matrix and the observation vector, wherein the parameters of the quadratic polynomial mathematical model are coefficients of a lane shape change model.
In the embodiment of the invention, each pixel point is traversed in the binarized edge image subjected to preprocessing such as Gaussian filtering, edge detection and the like; for each pixel point, whether the pixel value is 255 is checked, if the pixel value is an edge point, and the position, the direction and the continuity of the pixel point are consistent with the characteristics of a lane line (such as the vicinity of the lane line which is preset by a Hough transformation method, etc.), the pixel point is identified as the pixel point of the lane line, and the coordinates (x, y) of all the pixel points identified as the lane line are recorded.
Determining a quadratic polynomial as a mathematical model, namely (y=ax 2 +bx+c), according to the shape and complexity of the lane lines, wherein the mathematical model is used for fitting the extracted lane line pixel points to represent a lane line morphological change model; initializing an observation matrix A, wherein the number of lines of the observation matrix A is the number of lane line pixel points, and the number of columns of the observation matrix A is 3 (corresponding to three coefficients a, b and c of a quadratic polynomial); for each lane line pixel point, calculating a corresponding basis function value: x 2, x and a constant of 1, these basis function values are filled into the corresponding rows of the observation matrix a. For example, if there is a lane line pixel with an x-coordinate of 2, the corresponding basis function values are 2 2 =4, 2, and 1, which will be filled into a certain row of the observation matrix.
Initializing an observation vector b, wherein the length of the observation vector b is the number of lane line pixel points, and filling the ordinate (y value) of each lane line pixel point into the corresponding position of the observation vector b. The parameters of the quadratic polynomial mathematical model are solved using the least squares method. The objective of the least squares method is to find a set of parameters (a, b, c) that minimize the difference between the observed vector b and the values predicted by the mathematical model, wherein the formula of the least squares method is applied: Wherein A is the observation matrix, b is the observation vector,/> The method is a parameter vector obtained by solving, and comprises coefficients a, b and c, wherein T represents transposition operation of a matrix; calculation/>And/>Then multiplying the two to obtain a parameter vector/>From/>Coefficients a, b and c are extracted from the model, and the coefficients form a lane line morphological change model.
In the embodiment of the invention, a continuous and smooth lane line model can be obtained by fitting the lane line pixel points, which is beneficial to improving the accuracy and reliability of lane line detection. The fitting process may reduce to some extent the effects of noise and outliers on lane line detection because the fitting is based on statistical information of the plurality of pixels.
In a preferred embodiment of the present invention, the step 17 may include:
step 171, setting a search area in the edge data according to the lane shape change model, for searching the actual lane line edge;
Step 172, detecting edges in the set search area;
Step 173, matching the detected edge with the lane form shape change model to obtain a matched edge point;
Step 174, fitting again according to the matched edge points to obtain the final lane line shape;
step 175, determining the edge position of the road according to the final lane line shape.
In the embodiment of the present invention, step 171 predicts y values corresponding to different x positions in the image using an established lane-line shape change model (e.g., y=ax 2 +bx+c); selecting a range of x values, for example from the leftmost to the rightmost side of the image, and then calculating the corresponding y values of these x values in the model; the upper and lower boundaries of the search area are determined according to the y value predicted by the model, and the left and right boundaries of the search area can be set according to the width of the image or the area of interest. According to the perspective effect or the trend of the lane lines in the image, a rectangle or trapezoid can be selected as the search area. In step 172, in the search area determined in step 171, edges are detected using a Canny edge detection algorithm, and the double threshold of the Canny algorithm is adjusted so as to suppress noise while maintaining the lane line edges, and the coordinates of all edge points detected in the search area are recorded. Step 173, for each detected edge point, a formula for the point-to-conic distance may be used to calculate its vertical distance to the lane-form shape change model; and setting a distance threshold value, if the distance from the edge point to the model is smaller than the threshold value, considering that the edge point is matched with the lane line model, and then screening out the edge point matched with the lane line model.
In step 174, the matching edge points screened in step 173 are used as a data point set, and the data points are fitted by using a least square method to obtain a new lane line morphological change model, for example, a fitting process is completed by solving a normal equation, and a fitting residual is calculated to evaluate the fitting quality. And step 175, calculating the intersection point of the lane line and the image boundary (such as the bottom boundary) by using the lane line model obtained by fitting in step 174, if the lane line is not completely displayed in the image, extrapolating by using the model to obtain the estimated position of the road edge, and taking the calculated intersection point or extrapolated point as the edge position of the road.
For example, in traffic monitoring of urban intelligent traffic systems, cameras capture real-time traffic images of urban arterial roads and transmit these images to a central processing module for analysis. The goal is to accurately identify and track vehicles, pedestrians, and traffic conditions on the road so that the urban intelligent transportation system can optimize traffic signal control and provide real-time traffic information based on these data.
By the method, the urban intelligent traffic system can manage urban traffic flow more effectively, congestion and traffic accidents are reduced, and traffic efficiency and safety are improved. At the same time, these data can also be used for city planning, traffic policy formulation and further optimization of intelligent traffic systems. The following is a specific case:
Step 171, assuming that there is already a model of lane shape change based on history data, the form is y=0.002 x 2 -0.1x+50, the x value range is set to [0, 800], and the corresponding y value is calculated according to the lane shape change model within the x value range. For example, when x=0, y=50; when x=800, y=186. Considering perspective effect and lane line trend, a trapezoid search area is set, the upper bottom is y=40, the lower bottom is y=200, and the height is 800 pixels in image width.
Step 172, applying a Canny edge detection algorithm in the trapezoid search area, wherein the double threshold is set to be 50 and 150; the detected edge point coordinates are recorded, for example: (100, 60), (150, 65), …, (750, 190).
For each detected edge point, its vertical distance to the lane line model is calculated, step 173. For example, the vertical distance of the points (100, 60) to the model is 5 pixels; and setting the distance threshold as 10 pixels, and screening out edge points matched with the model. Let (100, 60), (200, 75), …, (700, 175) be the matched edge points. Step 174, using the matched edge points screened in step 173 as a data point set, and performing least square fitting on the data points to obtain a new lane line model (y=0.0022x 2 -0.11x+52); and calculating a fitting residual error, and finding that the square sum of the residual errors is smaller, so that the fitting effect is good. Step 175, using the new lane line model, calculates the intersection with the image bottom boundary (assuming y=0). The intersection x-coordinates are 400 and 650, and therefore, the determined road edge positions are x=400 and x=650, and these information are transmitted to the central processing module for analysis, with the goal of accurately identifying and tracking vehicles, pedestrians and traffic conditions on the road.
As shown in fig. 3, an embodiment of the present invention further provides a road edge recognition control device 20, including:
an acquisition module 21, configured to acquire road data in a current environment;
the preprocessing module 22 is configured to preprocess the road data in the current environment to obtain preprocessed road data;
A decomposition module 23, configured to decompose the preprocessed road data to obtain first data and second data; respectively calculating the average value of the first data and the second data to obtain fused first data and second data;
the calculation module 24 is configured to calculate a dynamic impact factor, and obtain fused data according to the fused first data and second data and the dynamic impact factor;
the processing module 25 is used for pre-positioning the lane lines in the fusion data and fitting the data points on the lane lines to obtain a lane shape change model; and calculating final road edge data according to the lane shape change model.
Optionally, decomposing the preprocessed road data to obtain the first data and the second data, including:
determining the number of layers of wavelet decomposition according to the complexity of the preprocessed road data and the required information granularity;
Carrying out wavelet decomposition on the preprocessed road data;
In the first layer decomposition, the preprocessed road data is filtered in the horizontal direction through a low-pass filter and a high-pass filter, and then one pixel is taken every other row or every other column to obtain an initial low-frequency approximate subgraph and an initial high-frequency detail subgraph;
Filtering and downsampling the initial low-frequency approximation subgraph in a vertical direction to obtain first data;
The initial high frequency detail sub-graph is high pass filtered and downsampled in the vertical direction to obtain second data.
Optionally, calculating the dynamic impact factor includes:
By passing through Calculating dynamic influence factor/>Wherein C represents low frequency contrast,/>Represents the maximum value of the low frequency contrast, S represents the low frequency sharpness,/>Represents the maximum value of low frequency sharpness, D represents the high frequency detail intensity,/>Represents the maximum value of the high frequency detail intensity, co represents the high frequency consistency,/>Maximum value representing high frequency uniformity,/>And/>Weight coefficient representing low frequency quality factor,/>And/>Weight coefficient representing high frequency quality factor,/>Representing the low frequency correlation factor,/>Representing a high frequency correlation factor.
Optionally, obtaining the fused data according to the fused first data, the fused second data and the dynamic influence factor includes:
According to dynamic influencing factors By/>Computing fusion data, wherein/>Pixel value representing the fused data at position (i, j)/>Weights representing the kth second data,/>Representing a low frequency image/>Pixel value at coordinates (i, j)/>Pixel values representing the kth high frequency resolution layer at the (i, j) coordinate locations; i and j are coordinate indexes in the two-dimensional image, representing rows and columns, respectively, and k represents a multi-scale high-frequency decomposition layer.
Optionally, the pre-positioning the lane lines in the fusion data includes:
gaussian filtering is carried out on the lane lines in the fusion data so as to obtain filtering data;
calculating the gradient intensity and direction of each data point in the filtering data, inhibiting the response of a non-maximum value along the gradient direction, determining an edge by a double-threshold method, and connecting edge line segments to obtain binarized edge data;
Initializing a Hough space, converting each edge point in the edge data into a curve or a straight line in the Hough space, and accumulating in a corresponding parameter space to obtain accumulated values of all parameter points in the Hough space;
setting a distinguishing threshold according to accumulated values of all parameter points in the Hough space;
and screening the final straight line according to the distinguishing threshold value to realize the pre-positioning of the lane line.
Optionally, fitting the data points on the lane lines to obtain a lane shape change model, including:
extracting coordinate data of a group of lane line data points from the edge data;
determining a quadratic polynomial mathematical model according to the shape and complexity of the lane lines;
constructing an observation matrix according to a quadratic polynomial mathematical model, wherein the observation matrix comprises values of a basis function used for fitting the mathematical model on the positions of data points of the lane lines;
assembling the ordinate of the lane line data points into an observation vector;
And solving parameters of a quadratic polynomial mathematical model through the observation matrix and the observation vector, wherein the parameters of the quadratic polynomial mathematical model are coefficients of a lane shape change model.
Optionally, calculating final road edge data according to the lane shape change model includes:
Setting a search area in the edge data according to the lane shape change model, and searching for the actual lane line edge;
Detecting edges in a set search area;
matching the detected edge with a lane shape change model to obtain a matched edge point;
Fitting again according to the matched edge points to obtain the final lane line shape;
And determining the edge position of the road according to the final lane line shape.
It should be noted that the apparatus is an apparatus corresponding to the above method, and all implementation manners in the above method embodiment are applicable to this embodiment, so that the same technical effects can be achieved.
Embodiments of the present invention also provide a computing device comprising: a processor, a memory storing a computer program which, when executed by the processor, performs the method as described above. All the implementation manners in the method embodiment are applicable to the embodiment, and the same technical effect can be achieved.
Embodiments of the present invention also provide a computer-readable storage medium storing instructions that, when executed on a computer, cause the computer to perform a method as described above. All the implementation manners in the method embodiment are applicable to the embodiment, and the same technical effect can be achieved.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses and units may refer to corresponding procedures in the foregoing method embodiments, and are not repeated herein.
In the embodiments provided in the present invention, it should be understood that the disclosed apparatus and method may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of the units is merely a logical function division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a usb disk, a removable hard disk, a ROM, a RAM, a magnetic disk, or an optical disk, etc.
Furthermore, it should be noted that in the apparatus and method of the present invention, it is apparent that the components or steps may be disassembled and/or assembled. Such decomposition and/or recombination should be considered as equivalent aspects of the present invention. Also, the steps of performing the series of processes described above may naturally be performed in chronological order in the order of description, but are not necessarily performed in chronological order, and some steps may be performed in parallel or independently of each other. It will be appreciated by those of ordinary skill in the art that all or any of the steps or components of the methods and apparatus of the present invention may be implemented in hardware, firmware, software, or any combination thereof in any computing device (including processors, storage media, etc.) or network of computing devices, as would be apparent to one of ordinary skill in the art upon reading the present specification.
The object of the invention can thus also be achieved by running a program or a set of programs on any computing device. The computing device may be a well-known general purpose device. The object of the invention can thus also be achieved by merely providing a program product containing program code for implementing said method or apparatus. That is, such a program product also constitutes the present invention, and a storage medium storing such a program product also constitutes the present invention. It is apparent that the storage medium may be any known storage medium or any storage medium developed in the future. It should also be noted that in the apparatus and method of the present invention, it is apparent that the components or steps may be disassembled and/or assembled. Such decomposition and/or recombination should be considered as equivalent aspects of the present invention. The steps of executing the series of processes may naturally be executed in chronological order in the order described, but are not necessarily executed in chronological order. Some steps may be performed in parallel or independently of each other.
While the foregoing is directed to the preferred embodiments of the present invention, it will be appreciated by those skilled in the art that various modifications and adaptations can be made without departing from the principles of the present invention, and such modifications and adaptations are intended to be comprehended within the scope of the present invention.

Claims (10)

1. A road edge recognition control method, characterized in that the method comprises:
Acquiring road data in the current environment;
preprocessing road data in the current environment to obtain preprocessed road data;
decomposing the preprocessed road data to obtain first data and second data;
respectively calculating the average value of the first data and the second data to obtain fused first data and second data;
calculating a dynamic influence factor, and obtaining fusion data according to the fused first data and second data and the dynamic influence factor;
pre-positioning the lane lines in the fusion data, and fitting the data points on the lane lines to obtain a lane shape change model;
and calculating final road edge data according to the lane shape change model.
2. The road edge recognition control method according to claim 1, wherein decomposing the preprocessed road data to obtain the first data and the second data comprises:
determining the number of layers of wavelet decomposition according to the complexity of the preprocessed road data and the required information granularity;
Carrying out wavelet decomposition on the preprocessed road data;
In the first layer decomposition, the preprocessed road data is filtered in the horizontal direction through a low-pass filter and a high-pass filter, and then one pixel is taken every other row or every other column to obtain an initial low-frequency approximate subgraph and an initial high-frequency detail subgraph;
Filtering and downsampling the initial low-frequency approximation subgraph in a vertical direction to obtain first data;
The initial high frequency detail sub-graph is high pass filtered and downsampled in the vertical direction to obtain second data.
3. The road edge recognition control method according to claim 2, wherein calculating the dynamic influence factor includes:
By passing through Calculating dynamic influence factor/>Wherein C represents low frequency contrast,/>Represents the maximum value of the low frequency contrast, S represents the low frequency sharpness,/>Represents the maximum value of low frequency sharpness, D represents the high frequency detail intensity,/>Represents the maximum value of the high frequency detail intensity, co represents the high frequency consistency,/>Maximum value representing high frequency uniformity,/>And/>Weight coefficient representing low frequency quality factor,/>And/>Weight coefficient representing high frequency quality factor,/>Representing the low frequency correlation factor,/>Representing a high frequency correlation factor.
4. The road edge recognition control method according to claim 3, wherein obtaining the fused data according to the fused first data and second data and the dynamic influence factor comprises:
According to dynamic influencing factors By/>Computing fusion data, wherein/>Pixel value representing the fused data at position (i, j)/>Representing the weight of the kth second data,Representing a low frequency image/>Pixel value at coordinates (i, j)/>Pixel values representing the kth high frequency resolution layer at the (i, j) coordinate locations; i and j are coordinate indexes in the two-dimensional image, representing rows and columns, respectively, and k represents a multi-scale high-frequency decomposition layer.
5. The road edge recognition control method according to claim 4, wherein the pre-locating the lane lines in the fusion data includes:
gaussian filtering is carried out on the lane lines in the fusion data so as to obtain filtering data;
calculating the gradient intensity and direction of each data point in the filtering data, inhibiting the response of a non-maximum value along the gradient direction, determining an edge by a double-threshold method, and connecting edge line segments to obtain binarized edge data;
Initializing a Hough space, converting each edge point in the edge data into a curve or a straight line in the Hough space, and accumulating in a corresponding parameter space to obtain accumulated values of all parameter points in the Hough space;
setting a distinguishing threshold according to accumulated values of all parameter points in the Hough space;
and screening the final straight line according to the distinguishing threshold value to realize the pre-positioning of the lane line.
6. The method of claim 5, wherein fitting the data points on the lane lines to obtain a lane shape change model comprises:
extracting coordinate data of a group of lane line data points from the edge data;
determining a quadratic polynomial mathematical model according to the shape and complexity of the lane lines;
constructing an observation matrix according to a quadratic polynomial mathematical model, wherein the observation matrix comprises values of a basis function used for fitting the mathematical model on the positions of data points of the lane lines;
assembling the ordinate of the lane line data points into an observation vector;
And solving parameters of a quadratic polynomial mathematical model through the observation matrix and the observation vector, wherein the parameters of the quadratic polynomial mathematical model are coefficients of a lane shape change model.
7. The road edge recognition control method according to claim 6, wherein calculating final road edge data based on the lane shape change model comprises:
Setting a search area in the edge data according to the lane shape change model, and searching for the actual lane line edge;
Detecting edges in a set search area;
matching the detected edge with a lane shape change model to obtain a matched edge point;
Fitting again according to the matched edge points to obtain the final lane line shape;
And determining the edge position of the road according to the final lane line shape.
8. A road edge recognition control device, characterized by comprising:
the acquisition module is used for acquiring road data in the current environment;
the preprocessing module is used for preprocessing the road data in the current environment to obtain preprocessed road data;
the decomposing module is used for decomposing the preprocessed road data to obtain first data and second data; respectively calculating the average value of the first data and the second data to obtain fused first data and second data;
The calculation module is used for calculating dynamic influence factors and obtaining fusion data according to the fused first data and second data and the dynamic influence factors;
The processing module is used for pre-positioning the lane lines in the fusion data and fitting the data points on the lane lines to obtain a lane shape change model; and calculating final road edge data according to the lane shape change model.
9. A computing device, comprising:
one or more processors;
Storage means for storing one or more programs which when executed by the one or more processors cause the one or more processors to implement the method of any of claims 1 to 7.
10. A computer readable storage medium, characterized in that the computer readable storage medium has stored therein a program which, when executed by a processor, implements the method according to any of claims 1 to 7.
CN202410516269.9A 2024-04-28 Road edge recognition control method and device Active CN118097581B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410516269.9A CN118097581B (en) 2024-04-28 Road edge recognition control method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410516269.9A CN118097581B (en) 2024-04-28 Road edge recognition control method and device

Publications (2)

Publication Number Publication Date
CN118097581A true CN118097581A (en) 2024-05-28
CN118097581B CN118097581B (en) 2024-06-25

Family

ID=

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5848193A (en) * 1997-04-07 1998-12-08 The United States Of America As Represented By The Secretary Of The Navy Wavelet projection transform features applied to real time pattern recognition
KR20110001427A (en) * 2009-06-30 2011-01-06 태성전장주식회사 High speed road lane detection method based on extraction of roi-lb
CN102314599A (en) * 2011-10-11 2012-01-11 东华大学 Identification and deviation-detection method for lane
CN106228138A (en) * 2016-07-26 2016-12-14 国网重庆市电力公司电力科学研究院 A kind of Road Detection algorithm of integration region and marginal information
CN107944350A (en) * 2017-11-07 2018-04-20 浙江大学 A kind of monocular vision Road Recognition Algorithm merged based on appearance and geological information
WO2019085929A1 (en) * 2017-10-31 2019-05-09 比亚迪股份有限公司 Image processing method, device for same, and method for safe driving
WO2020146980A1 (en) * 2019-01-14 2020-07-23 京东方科技集团股份有限公司 Lane line recognizing method, lane line recognizing device, and nonvolatile storage medium
CN114693716A (en) * 2022-03-26 2022-07-01 苏州惠临充智能科技有限公司 Driving environment comprehensive identification information extraction method oriented to complex traffic conditions
WO2023097931A1 (en) * 2021-12-03 2023-06-08 江苏航天大为科技股份有限公司 Hough transform-based license plate tilt correction method
US20230182743A1 (en) * 2021-12-15 2023-06-15 Industrial Technology Research Institute Method and system for extracting road data and method and system for controlling self-driving car
CN116342444A (en) * 2023-02-14 2023-06-27 山东财经大学 Dual-channel multi-mode image fusion method and fusion imaging terminal

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5848193A (en) * 1997-04-07 1998-12-08 The United States Of America As Represented By The Secretary Of The Navy Wavelet projection transform features applied to real time pattern recognition
KR20110001427A (en) * 2009-06-30 2011-01-06 태성전장주식회사 High speed road lane detection method based on extraction of roi-lb
CN102314599A (en) * 2011-10-11 2012-01-11 东华大学 Identification and deviation-detection method for lane
CN106228138A (en) * 2016-07-26 2016-12-14 国网重庆市电力公司电力科学研究院 A kind of Road Detection algorithm of integration region and marginal information
WO2019085929A1 (en) * 2017-10-31 2019-05-09 比亚迪股份有限公司 Image processing method, device for same, and method for safe driving
CN107944350A (en) * 2017-11-07 2018-04-20 浙江大学 A kind of monocular vision Road Recognition Algorithm merged based on appearance and geological information
WO2020146980A1 (en) * 2019-01-14 2020-07-23 京东方科技集团股份有限公司 Lane line recognizing method, lane line recognizing device, and nonvolatile storage medium
WO2023097931A1 (en) * 2021-12-03 2023-06-08 江苏航天大为科技股份有限公司 Hough transform-based license plate tilt correction method
US20230182743A1 (en) * 2021-12-15 2023-06-15 Industrial Technology Research Institute Method and system for extracting road data and method and system for controlling self-driving car
CN114693716A (en) * 2022-03-26 2022-07-01 苏州惠临充智能科技有限公司 Driving environment comprehensive identification information extraction method oriented to complex traffic conditions
CN116342444A (en) * 2023-02-14 2023-06-27 山东财经大学 Dual-channel multi-mode image fusion method and fusion imaging terminal

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
黄妙华;黎洲;吴益鹏;: "基于多算法融合的复杂非结构化道路识别", 数字制造科学, no. 04, 15 December 2017 (2017-12-15) *

Similar Documents

Publication Publication Date Title
US8340420B2 (en) Method for recognizing objects in images
CN111080661B (en) Image-based straight line detection method and device and electronic equipment
CN110287791B (en) Screening method and system for face pictures
CN111507426B (en) Non-reference image quality grading evaluation method and device based on visual fusion characteristics
Paunwala et al. A novel multiple license plate extraction technique for complex background in Indian traffic conditions
CN102314599A (en) Identification and deviation-detection method for lane
Garg et al. Survey on multi-focus image fusion algorithms
CN109934216B (en) Image processing method, device and computer readable storage medium
Khalifa et al. Malaysian Vehicle License Plate Recognition.
Dixit et al. Image texture analysis-survey
CN114299002A (en) Intelligent detection system and method for abnormal road surface throwing behavior
CN115171218A (en) Material sample feeding abnormal behavior recognition system based on image recognition technology
CN115546127A (en) Engine lubricating oil abrasive particle image analysis method and device, medium and equipment
CN110348307B (en) Path edge identification method and system for crane metal structure climbing robot
CN115841633A (en) Power tower and power line associated correction power tower and power line detection method
CN108520252B (en) Road sign identification method based on generalized Hough transform and wavelet transform
CN111027564A (en) Low-illumination imaging license plate recognition method and device based on deep learning integration
US7231086B2 (en) Knowledge-based hierarchical method for detecting regions of interest
CN118097581B (en) Road edge recognition control method and device
WO2024016632A1 (en) Bright spot location method, bright spot location apparatus, electronic device and storage medium
CN116524269A (en) Visual recognition detection system
CN110633705A (en) Low-illumination imaging license plate recognition method and device
CN116665321A (en) Parking lot vehicle management method based on edge nano-tube technology
CN116152758A (en) Intelligent real-time accident detection and vehicle tracking method
CN116129195A (en) Image quality evaluation device, image quality evaluation method, electronic device, and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
GR01 Patent grant