DXF data inspection system and method for pre-collision scene

The DXF data verification system automates the verification process by aligning aerial images with DXF drawings, addressing manual verification inefficiencies and inconsistencies, thereby enhancing the accuracy and efficiency of road geometry reconstruction for autonomous driving scenarios.

CN119091327APending Publication Date: 2024-12-06CHINA AUTOMOTIVE ENG RES INST
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411176725.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-26
Publication Date
2024-12-06

AI Technical Summary

Technical Problem

Manual verification of DXF data in pre-collision scenarios is time-consuming and prone to inconsistencies due to human factors, affecting the accuracy and efficiency of road geometry reconstruction for autonomous driving scenarios.

Method used

A DXF data verification system utilizing a server with modules for aerial image acquisition, shadow removal, semantic segmentation, data conversion, and comparison to automate the verification process, including historical data preprocessing and model training for improved accuracy and efficiency.

Benefits of technology

Automates DXF data verification, reducing manual labor, enhancing accuracy, and ensuring consistent results by aligning aerial images with DXF drawings, thus improving the efficiency and reliability of road geometry reconstruction for autonomous driving scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119091327A_ABST
    Figure CN119091327A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of data verification, in particular to a DXF data verification system and method for a pre-collision scene. The server side comprises an aerial image data acquisition module, a DXF image acquisition module, a shadow removal module, a semantic segmentation module, a data conversion module, a DXF image recognition module and a data comparison module, and the data comparison module is used for comparing the first coordinate and the layer data with the same coordinate according to the first coordinate and the layer data as well as the second coordinate and the layer data; comparing the aerial image with the corresponding image layer information between the first coordinate and the image layer data, and the corresponding image layer information between the second coordinate and the image layer data, if the comparison result is consistent, determining that the second coordinate and the image layer data corresponding to the aerial image are (x, y, 1), otherwise, determining that the second coordinate and the image layer data corresponding to the aerial image are (x, y, 0); and after all the coordinates are judged, recording data corresponding to the judgment result (x, y, 0) and forming corresponding verification result data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data verification, and in particular to a DXF data verification system and method for a pre-collision scene. Background Art

[0002] The main sources of autonomous driving scenarios are natural driving data, accident data, and expert experience data. Accident data can be used to generate scenarios. From accident data to scenario data, the data must first be processed. Data processing includes static CAD mapping to reconstruct the geometry of the accident road and dynamic PC Crash to reconstruct the dynamic trajectory of traffic participants.

[0003] The results of the reconstruction of the accident road geometry information by static CAD drawing are usually stored in the form of DXF files, which is convenient for outputting the road geometry and clarifying its characteristic attributes in the road traffic scene library based on these file information. This information is further used for the conversion of scene files (PCM) to achieve high-fidelity simulation of the real road environment.

[0004] Currently, the inspection of static reconstruction CAD mainly relies on manual verification. Specifically, the inspector needs to check one by one whether the road line shape and its attribute characteristics drawn in the CAD drawing are consistent with the actual road. Although this method is intuitive and effective, it has the following shortcomings in practical applications:

[0005] Manual verification requires a lot of time and manpower costs, which is particularly evident when dealing with large-scale road elements.

[0006] Cognitive differences among different inspectors may lead to poor consistency in inspection results, which in turn affects the accuracy of the final scene data conversion.

[0007] Based on this, there is an urgent need for a DXF data verification system and method for pre-collision scenarios, which can realize the automation of DXF data verification, improve data verification efficiency and reduce errors caused by human factors. Summary of the invention

[0008] One of the purposes of the present invention is to provide a DXF data verification system and method for pre-collision scenarios, which can realize the automation of DXF data verification, improve data verification efficiency and reduce errors caused by human factors.

[0009] In order to achieve the above object, a DXF data inspection system for a pre-collision scene is provided, comprising a server;

[0010] The server includes:

[0011] An aerial image data acquisition module is used to acquire the aerial images to be recorded;

[0012] The DXF drawing acquisition module is used to acquire the DXF drawing corresponding to the aerial image to be input;

[0013] A shadow removal module is used to perform shadow removal operations on the acquired aerial images to be recorded based on a pre-built shadow removal model;

[0014] A semantic segmentation module is used to output corresponding semantic segmentation result data based on the pre-built semantic segmentation model according to the aerial image to be recorded after the shadow removal operation; the semantic segmentation result data includes pixel point coordinate information (x1, y1) and pixel point attribute information c1;

[0015] The data conversion module is used to convert the pixel point attribute information c1 into the corresponding layer information c1' according to the output semantic segmentation result data; and then convert the pixel point coordinate information (x1, y1) and the layer information c1' into the corresponding first coordinate and layer data (x1, y1, c1');

[0016] The DXF image recognition module is used to recognize the acquired DXF image, identify the pixel coordinates (x2, y2) and the corresponding layer information c2 in the DXF image, and recognize them as the second coordinates and layer data (x2, y2, c2);

[0017] The data comparison module is used to compare the first coordinate and layer data (x1, y1, c1') and the second coordinate and layer data (x2, y2, c2) with the same coordinate (x, y) and the layer information c1' and c2 corresponding to the second coordinate and layer data. If the comparison results are consistent, it is determined that the second coordinate and layer data corresponding to the aerial image is (x, y, 1); otherwise, it is determined to be (x, y, 0);

[0018] After all coordinates are determined, the data corresponding to the determination result (x, y, 0) is recorded and the corresponding verification result data is formed.

[0019] Technical principles and effects of this solution: In this solution, the aerial images to be recorded and the corresponding DXF drawings are first obtained. In this process, it is also necessary to perform shadow removal operations on the acquired aerial images to be recorded based on the pre-built shadow removal model. During the process of collecting images by drone aerial photography, due to the shooting angle of the drone, shadows may appear on the collected images, blocking the road information. In order to facilitate subsequent aerial image recognition, the shadows of the aerial images are removed.

[0020] After that, the aerial image and DXF drawing can be processed separately. Specifically, the aerial image after the shadow removal operation is input into the pre-built semantic segmentation model to output the corresponding semantic segmentation result data. The corresponding semantic segmentation result data includes the pixel coordinate information (x1, y1) and the pixel attribute information c1 corresponding to the aerial image. After that, the pixel attribute information c1 can be converted into the corresponding layer information c1', and then the corresponding conversion is performed according to the pixel coordinate information (x1, y1) and the layer information c1', and converted into the corresponding first coordinate and layer data (x, y, c1').

[0021] At the same time, the DXF drawing corresponding to the acquired aerial image will also be identified, so as to identify the pixel coordinates (x2, y2) and the corresponding layer information c2 in the DXF drawing, and then convert them into the second coordinates and layer data (x2, y2, c2), thereby realizing the data recognition and conversion of the DXF drawing.

[0022] After completing the conversion of the first coordinate and layer data and the second coordinate and layer data, select the first coordinate and layer data and the second coordinate and layer data with the same corresponding coordinates (x, y) according to the first coordinate and layer data (x1, y1, c1') and the second coordinate and layer data (x2, y2, c2), that is, (x=x1=x2, y=y1=y2). When it is determined that the corresponding coordinates are the same, compare the first coordinate and layer data and the layer information c1' and c2 corresponding to the second coordinate and layer data. If the comparison results are consistent, that is, c1'=c2, then the second coordinate and layer data corresponding to the corresponding DXF drawing is determined to be (x, y, 1), that is, under the premise that x and y remain unchanged, c2 is changed to 1. Otherwise, it is determined to be (x, y, 0), that is, under the premise that x and y remain unchanged, c2 is changed to 0.

[0023] After completing the judgment of all coordinates, the data corresponding to the judgment result (x, y, 0) is recorded and the corresponding verification result data is formed, so as to realize the automatic judgment of the correctness of the DXF layer, and the manual positioning of the wrong position of the DXF layer is invalid. While improving the judgment accuracy of the DXF drawing, it reduces the work time consumption and improves the judgment efficiency.

[0024] Furthermore, the server also includes:

[0025] A historical data acquisition module is used to acquire historical aerial images and annotate the historical aerial images at the pixel level according to different classifications to form an annotated historical aerial image set;

[0026] A data preprocessing module, used to perform data preprocessing operations on the annotated historical aerial image set, wherein the data preprocessing operations include image cutting operations, data balancing operations, and data enhancement operations;

[0027] Semantic segmentation model building module, used to build a semantic segmentation model;

[0028] The first model training module is used to input the preprocessed annotated historical aerial images into the constructed semantic segmentation model, iteratively train the model based on the preset model training strategy, and output the corresponding trained semantic segmentation model after the training conditions are met.

[0029] Beneficial effects: Collect and organize historical aerial images and annotate them at the pixel level. This step is very important because high-quality datasets are the basis for training high-performance machine learning models. A series of preprocessing operations are performed on the annotated historical aerial image set to optimize the model training process and improve model performance. The preprocessed annotated historical aerial images are used to train the semantic segmentation model. Certain training strategies are adopted during the training process, such as the selection of loss functions, the configuration of optimization algorithms, etc. Use labeled historical aerial images as input to supervise the learning process of the model. Continuously adjust the model parameters through multiple rounds of iterations until the predetermined convergence criteria are reached. Regularly evaluate model performance during the training process to monitor the progress of training. From data preparation to model training, the entire process can be automated to reduce labor costs. Through a well-designed data preprocessing and model training process, the accuracy and robustness of the model can be significantly improved.

[0030] Furthermore, the preset model training strategy is:

[0031] Step 1: Define the search range of the corresponding hyperparameters lr and dropout in the semantic segmentation model in space;

[0032] Step 2: Initialize the hyperparameters in the space, namely lr0 and dropout0, to form the corresponding hyperparameter combination;

[0033] Step 3: In the current iteration, based on the determined hyperparameter combination, the search range of the corresponding hyperparameter is divided to form multiple division intervals corresponding to the hyperparameters lr and dropout, the center points in the corresponding division intervals are identified, and the center point sets corresponding to the hyperparameters lr and dropout are formed. Based on the two center point sets, the center points in the center point sets are combined in pairs to form several hyperparameter combinations;

[0034] Step 4: Divide the annotated historical aerial image set into a training set and a validation set. Based on the formed hyperparameter combinations, the semantic segmentation models are trained respectively. After the training is completed, the trained semantic segmentation model is verified by the data of the validation set to form the corresponding prediction results.

[0035] Step 5: According to the prediction results and the annotated historical aerial image set in the validation set, the goodness of fit corresponding to each hyperparameter combination is calculated based on the goodness of fit function calculation formula;

[0036] The goodness of fit function calculation formula is:

[0037]

[0038] Where IoU is the goodness of fit, λ1 and λ2 are the weight coefficients of Focal loss and Dice loss respectively, y′ is the output category confidence, ranging from 0 to 1, and α is the weight parameter; X represents the true sample label, Y represents the segmentation result of the network, |X∩Y| represents the intersection of X and Y, that is, the position where the segmentation result overlaps with the sample, |X| and |Y| represent the number of elements of X and Y respectively;

[0039] Step 6: According to the goodness of fit corresponding to each hyperparameter combination, select the hyperparameter combination with the smallest goodness of fit, and determine whether the corresponding goodness of fit is less than the preset value F min Or whether the corresponding current number of iterations is greater than the preset number of iterations. If so, the training is judged to be completed, and the hyperparameter combination corresponding to the current number of iterations is used as the optimal hyperparameter of the semantic segmentation model. Otherwise, the hyperparameter combination with the smallest goodness of fit and the division interval where the corresponding hyperparameter combination is located are recorded, and the division interval where the corresponding hyperparameter combination is recorded is used as the search interval corresponding to the next iteration, and step three is re-executed to start the next iteration.

[0040] Beneficial effects: In this scheme, the range of the model's hyperparameters is first limited and initialized. According to the hyperparameter values ​​in the current iteration, the search interval is subdivided into multiple small intervals. The center point of each interval is calculated and a center point set is formed. The center points are combined to form a new hyperparameter combination, and the data set is divided into a training set and a validation set. The semantic segmentation model is trained using different hyperparameter combinations. The model performance is evaluated using the validation set. The IoU indicator is calculated based on the predicted results and the true labels. The loss function is calculated using a weighted combination of Focal Loss and Dice Loss. The optimal hyperparameter combination is selected based on the IoU indicator. Check whether the termination condition is met (IoU is less than the preset threshold or the maximum number of iterations is reached).

[0041] By iteratively adjusting the learning rate and dropout, we can automatically find the hyperparameter combination that best suits the current task, avoiding the tedious process of manual parameter adjustment.

[0042] Using a goodness-of-fit function that combines Focal loss and Dice loss can more comprehensively evaluate model performance, taking into account both classification accuracy and segmentation accuracy.

[0043] By automatically adjusting the hyperparameters during the training process, the robustness of the model can be improved so that it can maintain good performance when facing different data sets. That is, automatic hyperparameter tuning is achieved through the setting of the entire logic, reducing the workload of manual parameter adjustment. By gradually refining the search interval and selecting the center point, the hyperparameter space can be explored more efficiently. By using IOU as an evaluation indicator and combining Focal Loss and Dice Loss, the performance of the model on unbalanced data sets can be improved, especially for small objects or multi-category segmentation tasks.

[0044] Further, the shadow removal module includes:

[0045] A data acquisition module, used to acquire initial images for shadow removal model training to form an initial image set;

[0046] The data processing module is used to select a specific shadow mask M from the initial image set according to the acquired initial image set. S , and its corresponding shadow image I S , M S Application S The shadow part of the image is cut out to get the corresponding shadow area P S , and the pixels in the remaining area of ​​the image are automatically set to 0;

[0047] It is also used to pick another random shadow mask M from the initial image set. n and apply it to I S The unshaded part of the n , whose area is the same as the shaded area P S The area is close to that of the other, and the end condition is:

[0048] Area(P n ) / Area(P s )∈(1-β,1+β)

[0049] Among them, Area(P n ) operation is responsible for calculating the area of ​​a given unshaded region;

[0050] It is also used to obtain the shadow area P Sand the unshaded area P n , constructed to include the shadow area P S and the unshaded area P n Unpaired training data;

[0051] It is also used to convert P in the unpaired training data according to the constructed unpaired training data. n Input into the preset artifact generator to get the output artifact image P ps In this process, by setting the first discriminator, the generated artifact image P ps The identification is false, for the shaded area P S The identification is judged to be true;

[0052] A shadow removal model building module, used to build a shadow removal model;

[0053] The second model training module is used to convert P in the unpaired training data n The output artifact image P generated by the artifact generator is ns , and P n Together as the input of the shadow removal model, the output is the shadow-free area P of the corresponding model f , determine the output shadow-free area P at this time f and the unshaded area P in the unpaired training data n The shadow similarity between them is calculated, and based on the shadow similarity, it is determined whether the corresponding shadow removal model has completed training. If not, the second model training module is re-executed.

[0054] Beneficial effect: In this scheme, the initial image for shadow removal model training is first obtained to form an initial image set; at this time, each initial image in the initial image set is an image without shadow. Compared with the existing image acquisition technology, it is usually to acquire an image without shadow and then acquire an image with shadow at the same position, which is not only complicated in operation but also has low acquisition accuracy and may have different similarities. In this scheme, a specific shadow mask M is selected from the initial image set. S , and its corresponding shadow image I s , M s Application s The shadow part of the image is cut out to get the corresponding shadow area P s , and the remaining area pixels of the image are automatically set to 0; it is also used to select another random shadow mask M from the initial image set n and apply it to I s The unshaded part of the n , whose area is the same as the shaded area P SThe area of ​​the shadow area P is close to S and the unshaded area P n The unpaired training data is constructed so that the data set includes images with shadows and corresponding images without shadows. The reliability and efficiency of the generation of two contrasting images are greatly improved through this automatic generation method.

[0055] At the same time, when training the corresponding shadow removal model, the input is P n The output P produced by the artifact generator is ps , together with P n Together, at this time theoretically P f With P n The content of P is exactly the same. In this training process, due to n and P ps The shadowed / non-shadowed areas of the same content in the image can be regarded as paired training data, thereby establishing a learning model similar to weak supervision.

[0056] Furthermore, the shadow removal module further includes:

[0057] Output refinement module, used to remove the shadow-free area P output by the shadow removal model f , embedded into the original input shadow image I S The corresponding output is P e , and P e With shadow mask M n Perform concatenate operation to get the corresponding output image P m , the output image P m It has 4 feature channels, including P e The 3 channels of the image and M n 1 channel of the mask; according to the output image P m , based on the result refiner, through the original shadow image I S The contextual semantic features of the image are used to improve the quality of the image after removing shadows and restoring the reconstruction, and the final output shadow-free image P is obtained. o .

[0058] Beneficial effect: By refining the result of the shadow-free area input by the shadow removal model, the final shadow-free image can ensure high-quality shadow removal while improving the quality of the restored and reconstructed image.

[0059] Furthermore, the server also includes:

[0060] The image adjustment module is used to automatically adjust the aerial image and the corresponding DXF drawing based on a preset image adjustment strategy after acquiring the aerial image and the corresponding DXF drawing to be input;

[0061] The image adjustment strategy is:

[0062] According to the origin corresponding to the DXF drawing, the corresponding road line is identified in the DXF drawing;

[0063] Identify the angle ∝ between the horizontal axis in the clockwise direction and the road line through the origin in DXF, and then use the origin as the rotation base point to rotate all elements in the DXF drawing counterclockwise by ∝ degrees to ensure that the road direction of the basic road lines drawn in DXF is horizontal;

[0064] According to the aerial image, the coordinates of the starting point and the end point corresponding to the road determined manually in the aerial image are identified, the starting point is the corresponding origin, and based on the coordinates of the starting point and the end point, the angle δ between the connecting line of the starting point and the end point and the horizontal axis is calculated, and then the determined origin is used as the rotation base point to rotate the aerial image counterclockwise by δ degrees to ensure that the road direction in the aerial image is horizontal;

[0065] Identify the length L of the road line passing through the origin in the DXF image and the length L between the start and end points in the aerial image ′ ;

[0066] Take the origin in the aerial image as the reference point and L ′ / L ratio to scale the aerial image and DXF image.

[0067] Beneficial effects: In this solution, by identifying the origin of the DXF drawing and determining the corresponding road line passing through the origin, and calculating the angle between the road line and the horizontal axis, the origin is used as the rotation center, and the corresponding angles of all elements in the DXF image are rotated counterclockwise to make the road line roughly horizontal. Then, the aerial image is rotated by manually determining the starting point and end point of the road, so that the road in the aerial image also remains horizontal. In this way, the aerial image and the road in the DXF drawing can be at the same level, which facilitates the subsequent unified scaling operation based on the origin of the aerial image, ensuring that the DXF image and the aerial image can be accurately aligned. The automated process reduces the time and labor cost of manual adjustment, and ensures that data from different sources have the same spatial reference system for easy integration and comparison.

[0068] The present invention also provides a DXF data verification method for a pre-collision scene, using the above-mentioned DXF data verification system for a pre-collision scene. BRIEF DESCRIPTION OF THE DRAWINGS

[0069] Figure 1This is a logic block diagram of a DXF data verification system for a pre-collision scenario in the first embodiment of the present invention. DETAILED DESCRIPTION

[0070] The following is further described in detail through specific implementation methods:

[0071] Embodiment 1

[0072] A DXF data verification system for pre-collision scenes, basically as follows Figure 1 As shown, including the server;

[0073] The server includes:

[0074] An aerial image data acquisition module is used to acquire the aerial images to be recorded;

[0075] The DXF drawing acquisition module is used to acquire the DXF drawing corresponding to the aerial image to be input;

[0076] The image adjustment module is used to automatically adjust the aerial image and the corresponding DXF drawing based on a preset image adjustment strategy after acquiring the aerial image and the corresponding DXF drawing to be input;

[0077] The image adjustment strategy is:

[0078] According to the origin corresponding to the DXF drawing, the corresponding road line is identified in the DXF drawing;

[0079] Identify the angle ∝ between the horizontal axis in the clockwise direction and the road line through the origin in DXF, and then use the origin as the rotation base point to rotate all elements in the DXF drawing counterclockwise by ∝ degrees to ensure that the road direction of the basic road lines drawn in DXF is horizontal;

[0080] According to the aerial image, the coordinates of the starting point and the end point corresponding to the road determined manually in the aerial image are identified, the starting point is the corresponding origin, and based on the coordinates of the starting point and the end point, the angle δ between the connecting line of the starting point and the end point and the horizontal axis is calculated, and then the determined origin is used as the rotation base point to rotate the aerial image counterclockwise by δ degrees to ensure that the road direction in the aerial image is horizontal;

[0081] Identify the length L of the road line passing through the origin in the DXF image and the length L between the start and end points in the aerial image ′ ;

[0082] Take the origin in the aerial image as the reference point and L ′ / L ratio to scale the aerial image and DXF image. After the corresponding scaling is completed, the corresponding aerial image and DXF drawing are grid checked in. At this time, the aerial image and DXF drawing are grid checked in at the same ratio, and the origin and coordinate direction of the two are the same.

[0083] The shadow removal module is used to perform shadow removal operations on the acquired aerial images to be recorded based on a pre-built shadow removal model. During the process of collecting images by drone aerial photography, due to the shooting angle of the drone, shadows may appear on the collected images, blocking the road information. In order to facilitate subsequent aerial image recognition, the shadows of the aerial images are removed.

[0084] The shadow removal module comprises:

[0085] A data acquisition module, used to acquire initial images for shadow removal model training to form an initial image set;

[0086] The data processing module is used to select a specific shadow mask M from the initial image set according to the acquired initial image set. S , and its corresponding shadow image I S , M S Application S The shadow part of the image is cut out to get the corresponding shadow area P S , and the pixels in the remaining area of ​​the image are automatically set to 0;

[0087] It is also used to pick another random shadow mask M from the initial image set. n and apply it to I S The unshaded part of the n , whose area is the same as the shaded area P S The area is close to that of the other, and the end condition is:

[0088] Area(P n ) / Area(P s )∈(1-β,1+β)

[0089] Among them, Area(P n ) operation is responsible for calculating the area of ​​a given unshaded area; β is a preset positive number less than 1, which is used to define the allowable deviation range of the area ratio. In this embodiment, it is set to 0.2.

[0090] It is also used to obtain the shadow area P S and the unshaded area P n , constructed to include the shadow area P S and the unshaded area P n Unpaired training data;

[0091] It is also used to convert P in the unpaired training data according to the constructed unpaired training data. n Input into the preset artifact generator to get the output artifact image P ps In this process, by setting the first discriminator, the generated artifact image P ps The identification is false, for the shaded area P S The identification is determined to be true; in this embodiment, the discriminator helps train the artifact generator through a loss function penalty mechanism so that its output is closer to the shadow image of the real distribution.

[0092] A shadow removal model building module, used to build a shadow removal model;

[0093] The second model training module is used to convert P in the unpaired training data n The output artifact image P generated by the artifact generator is ps , and P n Together as the input of the shadow removal model, the output is the shadow-free area P of the corresponding model f , determine the output shadow-free area P at this time f and the unshaded area P in the unpaired training data n The shadow similarity between them is calculated, and based on the shadow similarity, it is determined whether the corresponding shadow removal model has completed training. If not, the second model training module is re-executed. In this embodiment, theoretically, P f With P n The content of P is exactly the same. In this training process, due to n and P ps The shadowed / non-shadowed areas of the same content in the image can be regarded as paired training data, thereby establishing a learning model similar to weak supervision.

[0094] Output refinement module, used to remove the shadow-free area P output by the shadow removal model f , embedded into the original input shadow image I S The corresponding output is P e , and P e With shadow mask M n Perform concatenate operation to get the corresponding output image P m , the output image P m It has 4 feature channels, including P e The 3 channels of the image and M n 1 channel of the mask; according to the output image P m , based on the result refiner, through the original shadow image I SThe contextual semantic features of the image are used to improve the quality of the image after removing shadows and restoring the reconstruction, and the final output shadow-free image P is obtained. o In this embodiment, P m The color may be different from the original input image I S The colors of the original shadow image I are not completely consistent, and the quality of the generated image is poor. To this end, the result refiner R is introduced to make full use of the original shadow image I S The contextual semantic features are used to improve the quality of the image after removing shadows and restoring the reconstruction, and the final output shadow-free image P is obtained. o In this process, a second discriminator is introduced. For the output P of the result refiner o , the discriminator should judge it as false, and for the real original input image I S , then it is judged to be true.

[0095] A semantic segmentation module is used to output corresponding semantic segmentation result data based on the pre-built semantic segmentation model according to the aerial image to be recorded after the shadow removal operation; the semantic segmentation result data includes pixel point coordinate information (x1, y1) and pixel point attribute information c1;

[0096] The data conversion module is used to convert the pixel point attribute information c1 into the corresponding layer information c1' according to the output semantic segmentation result data; and then convert the pixel point coordinate information (x1, y1) and the layer information c1' into the corresponding first coordinate and layer data (x1, y1, c1');

[0097] The DXF image recognition module is used to recognize the acquired DXF image, identify the pixel coordinates (x2, y2) and the corresponding layer information c2 in the DXF image, and convert them into the second coordinates and layer data (x2, y2, c2);

[0098] The data comparison module is used to compare the first coordinate and layer data (x1, y1, c1') and the second coordinate and layer data (x2, y2, c2) with the same coordinate (x, y) and the layer information c1' and c2 corresponding to the second coordinate and layer data. If the comparison results are consistent, it is determined that the second coordinate and layer data corresponding to the aerial image is (x, y, 1); otherwise, it is determined to be (x, y, 0);

[0099] After all coordinates are determined, the data corresponding to the determination result (x, y, 0) is recorded and the corresponding verification result data is formed. In this embodiment, in addition to recording the data corresponding to the determination result (x, y, 0), the corresponding coordinates are searched in the aerial image and the point is marked. This marking method can quickly determine the points in the aerial image that are different from the DXF image.

[0100] A historical data acquisition module is used to acquire historical aerial images and annotate the historical aerial images at the pixel level according to different classifications to form an annotated historical aerial image set;

[0101] A data preprocessing module, used to perform data preprocessing operations on the annotated historical aerial image set, wherein the data preprocessing operations include image cutting operations, data balancing operations, and data enhancement operations;

[0102] Semantic segmentation model building module, used to build a semantic segmentation model;

[0103] The first model training module is used to input the preprocessed annotated historical aerial images into the constructed semantic segmentation model, iteratively train the model based on the preset model training strategy, and output the corresponding trained semantic segmentation model after the training conditions are met.

[0104] The preset model training strategy is:

[0105] Step 1: Define the search range of the corresponding hyperparameters lr and dropout in the semantic segmentation model in space;

[0106] Step 2: Initialize the hyperparameters in the space, namely lr0 and dropout0, to form the corresponding hyperparameter combination;

[0107] Step 3: In the current iteration, based on the determined hyperparameter combination, the search range of the corresponding hyperparameter is divided to form multiple division intervals corresponding to the hyperparameters lr and dropout, the center points in the corresponding division intervals are identified, and a center point set corresponding to the hyperparameters lr and dropout is formed. Based on the two center point sets, the center points in the center point sets are combined in pairs to form several hyperparameter combinations. In this embodiment, in the hyperparameter combination corresponding to the initialized hyperparameters, the search range is divided into two division intervals. At this time, each hyperparameter will identify two center points. At this time, the center points are combined in pairs to form four hyperparameter combinations. Then, the model is trained and verified respectively to calculate the corresponding goodness of fit. Then, the hyperparameter combination with the smallest goodness of fit is selected, and the corresponding The judgment conditions are used to determine whether the current hyperparameter combination meets the requirements. If so, the current hyperparameter combination is the optimal hyperparameter combination. If not, the hyperparameter combination with the smallest goodness of fit selected this time and the partition interval corresponding to the hyperparameter combination can further narrow the selection range of the hyperparameters. The search range is only in each partition interval, and then based on the preset partition interval, the search range is re-divided. At this time, the two hyperparameters will each obtain several partition intervals, and the center points will be identified again. For example, the hyperparameter lr corresponds to KK center points, and the hyperparameter dropout corresponds to TT center points. At this time, if they are combined in pairs, KK×TT hyperparameter combinations will be obtained, and then their respective training and verification are carried out. This is repeated until the requirements are met.

[0108] Step 4: Divide the annotated historical aerial image set into a training set and a validation set. Based on the formed hyperparameter combinations, the semantic segmentation models are trained respectively. After the training is completed, the trained semantic segmentation model is verified by the data of the validation set to form the corresponding prediction results.

[0109] Step 5: According to the prediction results and the annotated historical aerial image set in the validation set, the goodness of fit corresponding to each hyperparameter combination is calculated based on the goodness of fit function calculation formula;

[0110] The goodness of fit function calculation formula is:

[0111]

[0112] Where IoU is the goodness of fit, λ1 and λ2 are the weight coefficients of Focal loss and Dice loss respectively, y′ is the output category confidence, ranging from 0 to 1, α is the weight parameter; X represents the true sample label, Y represents the segmentation result of the network, |X∩Y| represents the intersection of X and Y, that is, the position where the segmentation result overlaps with the sample, |X| and |Y| represent the number of elements of X and Y respectively; γ is the focusing parameter;

[0113] Step 6: According to the goodness of fit corresponding to each hyperparameter combination, select the hyperparameter combination with the smallest goodness of fit, and determine whether the corresponding goodness of fit is less than the preset value F min Or whether the corresponding current number of iterations is greater than the preset number of iterations. If so, the training is judged to be finished, and the hyperparameter combination corresponding to the current number of iterations is used as the optimal hyperparameter of the semantic segmentation model. Otherwise, the hyperparameter combination with the smallest goodness of fit and the division interval where the corresponding hyperparameter combination is located are recorded, and the division interval where the corresponding hyperparameter combination is recorded is used as the search interval corresponding to the next iteration, and step three is re-executed to start the next iteration. In this embodiment, when the sample belongs to an easy-to-classify sample, the category confidence output of Focal loss is higher, so that the modulation factor tends to 0, thereby reducing the contribution of the easy-to-classify sample to the overall loss. On the contrary, when the sample belongs to a difficult-to-classify sample, the category confidence output is lower, so that the modulation coefficient tends to 1, and the original loss contribution is not changed. In summary, Focal loss is equivalent to increasing the loss contribution of difficult-to-classify samples, so that the loss function is tilted towards samples that are difficult to classify, thereby increasing the model's learning ability for image pixel features.

[0114] Dice loss can consider all pixels of the same category as a whole and calculate the proportion of the intersection in the whole, which can reduce the impact of a large number of road background pixels.

[0115] This embodiment also discloses a DXF data verification method for a pre-collision scene, using the above-mentioned DXF data verification system for a pre-collision scene.

[0116] The above is only an embodiment of the present invention. The common sense such as the known specific structure and characteristics in the scheme is described too much here. The ordinary technicians in the relevant field know all the common technical knowledge in the technical field of the invention before the application date or priority date, can know all the existing technologies in the field, and have the ability to apply the conventional experimental means before that date. The ordinary technicians in the relevant field can improve and implement this scheme in combination with their own abilities under the enlightenment given by this application. Some typical known structures or known methods should not become obstacles for ordinary technicians in the relevant field to implement this application. It should be pointed out that for those skilled in the art, without departing from the structure of the present invention, several deformations and improvements can be made, which should also be regarded as the protection scope of the present invention, which will not affect the effect of the implementation of the present invention and the practicality of the patent. The protection scope required by this application shall be based on the content of its claims, and the specific implementation methods and other records in the specification can be used to interpret the content of the claims.

Claims

1. A DXF data verification system for pre-collision scenarios, characterized in that: Including the server side; The server includes: An aerial image data acquisition module is used to acquire the aerial images to be recorded; The DXF drawing acquisition module is used to acquire the DXF drawing corresponding to the aerial image to be input; A shadow removal module is used to perform shadow removal operations on the acquired aerial images to be recorded based on a pre-built shadow removal model; A semantic segmentation module is used to output corresponding semantic segmentation result data based on the pre-built semantic segmentation model according to the aerial image to be recorded after the shadow removal operation; the semantic segmentation result data includes pixel point coordinate information (x1, y1) and pixel point attribute information c1; The data conversion module is used to convert the pixel point attribute information c1 into the corresponding layer information c1' according to the output semantic segmentation result data; and then convert the pixel point coordinate information (x1, y1) and the layer information c1' into the corresponding first coordinate and layer data (x1, y1, c1'); The DXF image recognition module is used to recognize the acquired DXF image, identify the pixel coordinates (x2, y2) and the corresponding layer information c2 in the DXF image, and recognize them as the second coordinates and layer data (x2, y2, c2); The data comparison module is used to compare the first coordinate and layer data (x1, y1, c1') and the second coordinate and layer data (x2, y2, c2) with the same coordinate (x, y) and the layer information c1' and c2 corresponding to the second coordinate and layer data. If the comparison results are consistent, it is determined that the second coordinate and layer data corresponding to the aerial image is (x, y, 1); otherwise, it is determined to be (x, y, 0); After all coordinates are determined, the data corresponding to the determination result (x, y, 0) is recorded and the corresponding verification result data is formed.

2. A DXF data verification system for pre-crash scenarios according to claim 1, characterized in that: The server also includes: A historical data acquisition module is used to acquire historical aerial images and annotate the historical aerial images at the pixel level according to different classifications to form an annotated historical aerial image set; A data preprocessing module, used to perform data preprocessing operations on the annotated historical aerial image set, wherein the data preprocessing operations include image cutting operations, data balancing operations, and data enhancement operations; Semantic segmentation model building module, used to build a semantic segmentation model; The first model training module is used to input the preprocessed annotated historical aerial images into the constructed semantic segmentation model, iteratively train the model based on the preset model training strategy, and output the corresponding trained semantic segmentation model after the training conditions are met.

3. A DXF data verification system for pre-crash scenarios according to claim 2, characterized in that: The preset model training strategy is: Step 1: Define the search range of the corresponding hyperparameters lr and dropout in the semantic segmentation model in space; Step 2: Initialize the hyperparameters in the space, namely lr0 and dropout0, to form the corresponding hyperparameter combination; Step 3: In the current iteration, based on the determined hyperparameter combination, the search range of the corresponding hyperparameter is divided to form multiple division intervals corresponding to the hyperparameters lr and dropout, the center points in the corresponding division intervals are identified, and the center point sets corresponding to the hyperparameters lr and dropout are formed. Based on the two center point sets, the center points in the center point sets are combined in pairs to form several hyperparameter combinations; Step 4: Divide the annotated historical aerial image set into a training set and a validation set. Based on the formed hyperparameter combinations, the semantic segmentation models are trained respectively. After the training is completed, the trained semantic segmentation model is verified by the data of the validation set to form the corresponding prediction results. Step 5: According to the prediction results and the annotated historical aerial image set in the validation set, the goodness of fit corresponding to each hyperparameter combination is calculated based on the goodness of fit function calculation formula; The goodness of fit function calculation formula is: Where IoU is the goodness of fit, λ1 and λ2 are the weight coefficients of Focal loss and Dice loss respectively, y′ is the output category confidence, ranging from 0 to 1, and α is the weight parameter; X represents the true sample label, Y represents the segmentation result of the network, |X∩Y| represents the intersection of X and Y, that is, the position where the segmentation result overlaps with the sample, |X| and |Y| represent the number of elements of X and Y respectively; Step 6: According to the goodness of fit corresponding to each hyperparameter combination, select the hyperparameter combination with the smallest goodness of fit, and determine whether the corresponding goodness of fit is less than the preset value F min Or whether the corresponding current number of iterations is greater than the preset number of iterations. If so, the training is judged to be completed, and the hyperparameter combination corresponding to the current number of iterations is used as the optimal hyperparameter of the semantic segmentation model. Otherwise, the hyperparameter combination with the smallest goodness of fit and the division interval where the corresponding hyperparameter combination is located are recorded, and the division interval where the corresponding hyperparameter combination is recorded is used as the search interval corresponding to the next iteration, and step three is re-executed to start the next iteration.

4. A DXF data verification system for pre-crash scenarios according to claim 3, characterized in that: The shadow removal module comprises: A data acquisition module, used to acquire initial images for shadow removal model training to form an initial image set; The data processing module is used to select a specific shadow mask M from the initial image set according to the acquired initial image set. S , and its corresponding shadow image I S , M S Application S The shadow part of the image is cut out to get the corresponding shadow area P S , and the pixels in the remaining area of ​​the image are automatically set to 0; It is also used to pick another random shadow mask M from the initial image set. n , and apply it to I S The unshaded part of the n , whose area is the same as the shaded area P S The area is close to that of the other, and the end condition is: Area(P n ) / Area(P s )∈(1-β,1+β) Among them, Area(P n ) operation is responsible for calculating the area of ​​a given unshaded region; It is also used to obtain the shadow area P S and the unshaded area P n , constructed to include the shadow area P S and the unshaded area P n Unpaired training data; It is also used to convert P in the unpaired training data according to the constructed unpaired training data. n Input into the preset artifact generator to get the output artifact image P ps In this process, by setting the first discriminator, the generated artifact image P ps The identification is false, for the shaded area P S The identification is judged to be true; A shadow removal model building module, used to build a shadow removal model; The second model training module is used to convert P in the unpaired training data n The output artifact image P generated by the artifact generator is ps , and P n Together as the input of the shadow removal model, the output is the shadow-free area P of the corresponding model f , determine the output shadow-free area P at this time f and the unshaded area P in the unpaired training data n The shadow similarity between them is calculated, and based on the shadow similarity, it is determined whether the corresponding shadow removal model has completed training. If not, the second model training module is re-executed.

5. A DXF data verification system for pre-crash scenarios according to claim 4, characterized in that: The shadow removal module also includes: Output refinement module, used to remove the shadow-free area P output by the shadow removal model f , embedded into the original input shadow image I S The corresponding output is P e , and P e With shadow mask M n Perform concatenate operation to get the corresponding output image P m , the output image P m It has 4 feature channels, including P e The 3 channels of the image and M n 1 channel of the mask; according to the output image P m , based on the result refiner, through the original shadow image I S The contextual semantic features of the image are used to improve the quality of the image after removing shadows and restoring the reconstruction, and the final output shadow-free image P is obtained. o .

6. A DXF data verification system for pre-crash scenarios according to claim 5, characterized in that: The server also includes: The image adjustment module is used to automatically adjust the aerial image and the corresponding DXF drawing based on a preset image adjustment strategy after acquiring the aerial image and the corresponding DXF drawing to be input; The image adjustment strategy is: According to the origin corresponding to the DXF drawing, the corresponding road line is identified in the DXF drawing; Identify the angle ∝ between the horizontal axis in the clockwise direction and the road line through the origin in DXF, and then use the origin as the rotation base point to rotate all elements in the DXF drawing counterclockwise by ∝ degrees to ensure that the road direction of the basic road lines drawn in DXF is horizontal; According to the aerial image, the coordinates of the starting point and the end point corresponding to the road determined manually in the aerial image are identified, the starting point is the corresponding origin, and based on the coordinates of the starting point and the end point, the angle δ between the connecting line of the starting point and the end point and the horizontal axis is calculated, and then the determined origin is used as the rotation base point to rotate the aerial image counterclockwise by δ degrees to ensure that the road direction in the aerial image is horizontal; Identify the length L of the road line passing through the origin in the DXF image, and the length L′ between the start and end points in the aerial image; Taking the origin in the aerial image as the reference point, the aerial image and DXF image are scaled at the ratio of L′ / L.

7. A DXF data verification method for a pre-collision scene, characterized in that: A DXF data verification system for a pre-crash scene using any one of claims 1 to 6.