Ground mark aggregation method, system and equipment and storage medium
By clustering and extracting geometric point sequences of ground mark data, correcting angles with trajectory data, and fitting and correcting using standard graphic templates, the problem of aggregation angles of ground mark graphics is solved, and the accuracy of aggregation is improved.
Patent Information
- Application Number
- CN202311743551.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-18
- Publication Date
- 2025-06-20
AI Technical Summary
During the high-precision map production process, the irregular ground signs collected by crowdsourcing map trucks are inconsistent in the angle of the ground sign graphic aggregation.
By obtaining the ground sign data collected by the target vehicle in the target area, clustering it to obtain the ground sign feature list, extracting the geometric point sequence and generating multiple polygon objects, combining the trajectory data to correct the angle, and fitting and correction with the help of standard graphic templates.
Effectively correct the correct angle of ground marks, shape correction and smoothing by calculating the difference between the object point sequence and the mean multiple times, and aligning and rotating with reference to the standard model, improving the accuracy of ground mark graphic aggregation.
Smart Images

Figure CN120176646A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of high-precision map production, and particularly to a method, system, device and computer-readable storage medium for aggregating ground signs. Background Art
[0002] Currently, in the process of high-precision map production, it is necessary to collect data on roads through crowdsourcing mapping vehicles, and draw corresponding high-precision maps based on the collected data. However, currently when crowdsourcing mapping vehicles collect data, when aggregating some irregular ground signs collected by the mapping vehicles, since the directions of the ground signs collected each time are not exactly the same, and due to the inability to correctly identify the overall direction, it will cause the angles of the aggregated ground sign graphics to be disordered.
[0003] Therefore, the prior art still needs to be improved and developed. Summary of the Invention
[0004] The main purpose of this application is to provide a method, system, device and computer-readable storage medium for aggregating ground signs, aiming to solve the problem in the prior art that when aggregating some irregular ground signs collected by a mapping vehicle, since the directions of the ground signs collected each time are not exactly the same, and due to the inability to correctly identify the overall direction, it will cause the angles of the aggregated ground sign graphics to be disordered.
[0005] The first aspect of the embodiments of this application provides a method for aggregating ground signs, including the following steps: obtaining ground sign data collected by a target vehicle in a target area, and clustering the ground sign data to obtain a ground sign feature list; extracting all geometric point sequences according to the semantic objects of the ground sign feature list, and generating a plurality of corresponding first polygon objects according to all the geometric point sequences, and storing all the first polygon objects in a first position list; generating a second polygon object according to the first position list, and generating an overall cluster contour according to the area of the second polygon object and the first position list; obtaining a corresponding standard graphic template according to the ground sign feature list, fitting and correcting the overall cluster contour with the standard graphic template, and outputting a fitting result.
[0006] According to the above technical means, in the embodiment of the present application, when aggregating some irregular ground signs collected by a mapping vehicle in the prior art, since the directions of the ground signs collected each time are not exactly the same, and due to the inability to correctly identify the overall direction judgment, the angle of aggregation of the ground sign graphics will be disordered. By effectively introducing trajectory data to correct the correct angle of the ground signs, and by calculating the difference between the object point sequence and the mean value multiple times for shape correction and smoothing, and aligning and rotating with reference to the standard model, it can be more in line with the aggregation output of irregular polygons and make it more accurate.
[0007] Optionally, in an embodiment of the present application, for the semantic object according to the ground sign feature list, all geometric body point sequences are extracted, and a plurality of corresponding first polygon objects are generated according to all the geometric body point sequences, and all the first polygon objects are stored in the first position list. Specifically, it includes: according to the ground sign feature list, extracting all geometric bodies of the semantic object in the ground sign feature list, and obtaining the geometric body point sequence forming each geometric body; extracting the coordinates in each geometric body point sequence, storing the coordinates in each geometric body point sequence in the second position list, and obtaining the centroid coordinates of the circumscribed shape of each geometric body according to the second position list; obtaining the centroid coordinates of each geometric body according to the coordinates in each geometric body point sequence, generating difference coordinates according to the centroid coordinates of each geometric body and the centroid coordinates of the corresponding circumscribed shape; generating a first polygon object for each geometric body point sequence according to the difference coordinates and the coordinates in each geometric body point sequence, and storing all the first polygon objects in the first position list.
[0008] According to the above technical means, in the embodiment of the present application, by obtaining the centroid coordinates of the polygon geometric body and the centroid coordinates of the circumscribed rectangle of the polygon geometric body, the difference between the two centroid coordinates is correspondingly obtained, and then the first polygon object is generated according to the difference of the centroid coordinates. Through this processing, the obtained first polygon object is more regular, which facilitates the subsequent processing of the overall cluster contour obtained from the first polygon object by the standard graphic template.
[0009] Optionally, in an embodiment of the present application, extracting the coordinates in each of the geometric body point sequences, storing the coordinates in each of the geometric body point sequences into a second position list, and obtaining the centroid coordinates of the circumscribed shape of each geometric body according to the second position list specifically includes: extracting the coordinates in each of the geometric body point sequences, and storing the coordinates in each of the geometric body point sequences into a second position list; generating a third polygon object for each geometric body according to the second position list, and obtaining the centroid coordinates of each third polygon object; generating a circumscribed rectangle for each third polygon object according to each third polygon object, and obtaining the centroid coordinates of the circumscribed rectangle of each third polygon object, so as to obtain the centroid coordinates of the circumscribed shape of each geometric body.
[0010] According to the above technical means, when obtaining the centroid coordinates of the circumscribed shape of a geometric body in an embodiment of the present application, by storing the coordinates of the geometric body point sequence, the geometric body can generate a corresponding third polygon object, and the centroid coordinates thereof can be conveniently obtained through the generated third polygon object. Moreover, the circumscribed rectangle of the third polygon object, that is, the circumscribed shape of the geometric body, can be more conveniently obtained from the obtained third polygon object. Through this circumscribed rectangle, the centroid coordinates of the circumscribed shape of each geometric body can be quickly, accurately and intuitively obtained.
[0011] Optionally, in an embodiment of the present application, generating a second polygon object according to the first position list, and generating an overall cluster profile according to the area of the second polygon object and the first position list specifically includes: merging all the first polygon objects in the first position list to obtain a second polygon object, and obtaining the area of the second polygon object; looping through the first position list, and calculating the area of each first polygon object in the first position list; calculating the ratio of the area of each first polygon object to the area of the second polygon object, and generating an overall cluster profile according to the ratio.
[0012] According to the above technical means, in an embodiment of the present application, a second polygon object is obtained from multiple first polygon objects, and an overall cluster profile is obtained from the first polygon objects according to the areas of the first polygon objects and the second polygon object, so that the best overall cluster profile can be obtained from the multiple first polygon objects in the present application, and a more accurate fitting point sequence can be generated subsequently according to the overall cluster profile.
[0013] Optionally, in an embodiment of the present application, calculating the ratio of the area of each of the first polygon objects to the area of the second polygon object, and generating an overall cluster profile according to the ratio specifically includes: calculating the ratio of the area of each of the first polygon objects to the area of the second polygon object; obtaining preselected first polygon objects with a ratio less than a preset ratio threshold from the first position list; generating a preselected overall cluster profile according to the preselected first polygon objects, and smoothing the preselected overall cluster profile to obtain an overall cluster profile.
[0014] According to the above technical means, in the embodiment of the present application, the overall cluster profile is obtained from multiple first polygon objects through the set preset ratio threshold, so that the area of the obtained overall cluster profile will not be lower than the set value; and when generating the overall cluster profile, the preselected overall cluster profile is smoothed to obtain the overall cluster profile, which makes the obtained overall cluster profile not contain redundant data, thus making it more convenient and fast to process the overall cluster profile subsequently.
[0015] Optionally, in an embodiment of the present application, obtaining a corresponding standard graphic template according to the ground mark feature list, fitting and correcting the overall cluster profile with the standard graphic template, and outputting a fitting result specifically includes: obtaining the most numerous ground mark type in the ground mark feature list, and obtaining a standard graphic template according to the ground mark type; obtaining the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, calculating the standard difference between the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, and respectively subtracting the point sequence of the standard graphic template from the standard difference to obtain a standard difference point coordinate list; generating a fourth polygon object according to the standard difference point coordinate list, and obtaining the centroid coordinates of the fourth polygon object; rotating the fourth polygon object according to the centroid coordinates of the fourth polygon object, and obtaining the position with the largest intersection area with the overall cluster profile during the rotation process, and obtaining a preset fitting point sequence according to the position; judging whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold, and if not less, taking the preset fitting point sequence as the fitting result and outputting it.
[0016] According to the above technical means, in the embodiment of the present application, a suitable standard graphic template can be obtained according to the ground mark feature list, and the position with the largest intersection area is selected as the position corresponding to the angle to be output in the present application through the intersection situation between the standard graphic template and the overall cluster profile. At the same time, by setting a preset output threshold, the situation of too small intersection area is prevented, and the situation of generating an incorrect fitting point sequence is prevented, making the fitting result output by the present application more accurate.
[0017] Optionally, in an embodiment of the present application, after determining whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than a preset output threshold, the method further includes: if the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold; obtaining the trajectory data collected by the target vehicle in the target area, obtaining the timestamp list of the semantic objects in the ground mark feature list according to the ground mark feature list, and obtaining the azimuth angle according to the timestamp list and the trajectory data; based on the azimuth angle, rotating the fourth polygon object according to the centroid coordinates of the fourth polygon object, and obtaining the updated position with the largest intersection area with the overall cluster contour during the rotation process, and obtaining an updated preset fitting point sequence according to the updated position; generating an updated fitting result according to the updated preset fitting point sequence and outputting it.
[0018] According to the above technical means, when the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold, the embodiment of the present application can further limit the acquisition range of the fitting point sequence by obtaining the approximate azimuth angle of the angle, so that a more accurate fitting point sequence can be obtained compared with the preset fitting point sequence whose intersection area between the preset fitting object constructed and the overall cluster contour is less than the preset output threshold.
[0019] An embodiment of the second aspect of the present application provides a ground mark aggregation system, which includes: a data acquisition module, configured to acquire the ground mark data collected by the target vehicle in the target area and cluster the ground mark data to obtain a ground mark feature list; a first polygon object acquisition module, configured to extract all geometric point sequences according to the semantic objects in the ground mark feature list, generate a plurality of corresponding first polygon objects according to all the geometric point sequences, and store all the first polygon objects in a first position list; an overall cluster contour acquisition module, configured to generate a second polygon object according to the first position list and generate an overall cluster contour according to the area of the second polygon object and the first position list; a result output module, configured to obtain a corresponding standard graphic template according to the ground mark feature list, perform fitting correction on the overall cluster contour and the standard graphic template, and output a fitting result.
[0020] Optionally, in an embodiment of the present application, the first polygon object acquisition module includes: a geometric body point sequence acquisition unit, configured to extract all geometric bodies of the semantic objects in the ground mark feature list according to the ground mark feature list, and acquire the geometric body point sequences forming each geometric body; a circumscribed shape centroid coordinate acquisition unit, configured to extract the coordinates in each geometric body point sequence, store the coordinates in each geometric body point sequence into a second position list, and acquire the centroid coordinates of the circumscribed shape of each geometric body according to the second position list; a difference coordinate generation unit, configured to acquire the centroid coordinates of each geometric body according to the coordinates in each geometric body point sequence, and generate difference coordinates according to the centroid coordinates of each geometric body and the centroid coordinates of the corresponding circumscribed shape; a first polygon object storage unit, configured to generate a first polygon object for each geometric body point sequence according to the difference coordinates and the coordinates in each geometric body point sequence, and store all the first polygon objects into a first position list.
[0021] Optionally, in an embodiment of the present application, the circumscribed shape centroid coordinate acquisition unit includes: a second position list storage subunit, configured to extract the coordinates in each geometric body point sequence and store the coordinates in each geometric body point sequence into a second position list; a third polygon object centroid coordinate acquisition subunit, configured to generate a third polygon object for each geometric body according to the second position list and acquire the centroid coordinates of each third polygon object; a circumscribed rectangle centroid coordinate acquisition subunit, configured to generate a circumscribed rectangle for each third polygon object according to each third polygon object and acquire the centroid coordinates of the circumscribed rectangle of each third polygon object, so as to obtain the centroid coordinates of the circumscribed shape of each geometric body.
[0022] Optionally, in an embodiment of the present application, the overall cluster contour acquisition module includes: a second polygon object acquisition unit, configured to merge all the first polygon objects in the first position list to obtain a second polygon object and acquire the area of the second polygon object; a first polygon object area calculation unit, configured to loop through the first position list and calculate the area of each first polygon object in the first position list; a calculation and generation of overall cluster contour unit, configured to calculate the ratio of the area of each first polygon object to the area of the second polygon object, and generate an overall cluster contour according to the ratio.
[0023] Optionally, in an embodiment of the present application, the calculation and generation of the overall cluster profile unit includes: a first area ratio calculation subunit, configured to calculate the ratio of the area of each of the first polygon objects to the area of the second polygon object; a preselected first polygon object acquisition subunit, configured to acquire preselected first polygon objects with a ratio less than a preset ratio threshold from the first position list; and a merged generation of the overall cluster profile subunit, configured to generate a preselected overall cluster profile based on the preselected first polygon objects, and perform smoothing processing on the preselected overall cluster profile to obtain the overall cluster profile.
[0024] Optionally, in an embodiment of the present application, the result output module includes: a standard graphic template acquisition unit, configured to acquire the most numerous ground mark type in the ground mark feature list, and acquire a standard graphic template according to the ground mark type; a difference point coordinate list acquisition unit, configured to acquire the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, calculate the standard difference between the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, and respectively subtract the point sequence of the standard graphic template from the standard difference to obtain a standard difference point coordinate list; a fourth polygon object centroid coordinate acquisition unit, configured to generate a fourth polygon object according to the standard difference point coordinate list, and acquire the centroid coordinates of the fourth polygon object; a preset fitting point sequence generation unit, configured to rotate the fourth polygon object according to the centroid coordinates of the fourth polygon object, and acquire the position with the largest intersection area with the overall cluster profile during the rotation process, and obtain a preset fitting point sequence according to the position; and a judgment and output unit, configured to judge whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold, and if not less, use the preset fitting point sequence as the fitting result and output it.
[0025] Optionally, in an embodiment of the present application, the judgment and output unit includes: an abnormality acquisition subunit, configured to if the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold; an azimuth angle acquisition subunit, configured to acquire trajectory data collected by a target vehicle in a target area, acquire a timestamp list of semantic objects in the ground mark feature list according to the ground mark feature list, and acquire an azimuth angle according to the timestamp list and the trajectory data; an updated preset fitting point sequence generation subunit, configured to rotate the fourth polygon object according to the centroid coordinates of the fourth polygon object based on the azimuth angle, and acquire an updated position with the largest intersection area with the overall cluster profile during the rotation process, and obtain an updated preset fitting point sequence according to the updated position; and a fitting point sequence re-output subunit, configured to generate an updated fitting result according to the updated preset fitting point sequence and output it.
[0026] In a third aspect embodiment of the present application, a terminal is provided. The terminal includes: a memory, a processor, and a ground mark aggregation program stored on the memory and executable on the processor. When the ground mark aggregation program is executed by the processor, the steps of the ground mark aggregation method described in the above embodiments are implemented.
[0027] In a fourth aspect embodiment of the present application, a computer-readable storage medium is provided. The computer-readable storage medium stores a ground mark aggregation program. When the ground mark aggregation program is executed by a processor, the steps of the ground mark aggregation method described in the above embodiments are implemented.
[0028] Advantages of the present application:
[0029] (1) In the embodiments of the present application, by introducing ground mark data to correct the correct angle of the ground marks on the ground, and by calculating the difference between the coordinate sequence and the mean value multiple times, and aligning and rotating with the aid of a standard graphic template, it can be more in line with the output of an irregular polygon, making the fitting result with ground mark angle information more accurate.
[0030] (2) In the embodiments of the present application, a second polygon object is generated through multiple first polygon objects, and the overall cluster contour is obtained from the multiple first polygon objects through the area of the second polygon object, so that the overall cluster contour obtained in the present invention is not less than a certain value, thereby making the fitting point sequence generated by means of the overall cluster contour also have certain limitations, and will not output a fitting point sequence with a large difference from the actual situation, that is, the fitting result output is more accurate through the overall cluster contour.
[0031] (3) In the embodiments of the present application, through the ground mark data obtained by the target vehicle in the target area, a fitting point sequence containing the ground mark data is correspondingly obtained, so that the present invention can accurately obtain the angle of the ground mark graphic aggregation for some irregular ground marks collected, and the obtained fitting result can be represented on the map where it is required to appear.
[0032] Additional aspects and advantages of the present application will be partially given in the following description, partially become obvious from the following description, or be understood through the practice of the present application. Description of the Drawings
[0033] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for use in the embodiments or the description of the prior art. Obviously, the following drawings are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0034] Figure 1 is a flowchart of a preferred embodiment of the ground mark aggregation method of the present application;
[0035] Figure 2 is a schematic diagram of an implementation manner of the ground mark aggregation method of the present application;
[0036] Figure 3 is a flowchart of the azimuth angle acquisition in the ground mark aggregation method of the present application;
[0037] Figure 4 is a flowchart of obtaining the centroid coordinates of the first polygon object of the geometric point sequence in the ground mark aggregation method of the present application;
[0038] Figure 5 is a flowchart of outputting the overall cluster contour in the ground mark aggregation method of the present application;
[0039] Figure 6 is a flowchart of aligning and rotating the standard graphic template with the centroid of the overall cluster contour in the ground mark aggregation method of the present application;
[0040] Figure 7 is a flowchart of outputting the fitting point sequence in the ground mark aggregation method of the present application;
[0041] Figure 8 is a schematic structural diagram of a preferred embodiment of the ground mark aggregation system of the present application;
[0042] Figure 9 is a schematic structural diagram of a preferred embodiment of the vehicle of the present application.
[0043] Among them, 10 - ground mark aggregation system; 100 - data acquisition module, 200 - first polygon object acquisition module, 300 - overall cluster contour acquisition module, and 400 - result output module; 501 - memory, 502 - processor, and 503 - communication interface. Specific Embodiments
[0044] The embodiments of the present application will be described in detail below. The examples of the embodiments are shown in the accompanying drawings, where the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to explain the present application and should not be construed as limiting the present application.
[0045] The following describes a ground sign aggregation method, system, device, and computer-readable storage medium according to embodiments of the present application. In view of the problem in the prior art mentioned in the above background art that when aggregating some irregular ground signs collected by a mapping vehicle, since the directions of the ground signs collected each time are not exactly the same and the overall direction judgment cannot be correctly identified, resulting in a disorder of the aggregation angles of the ground sign graphics, the present application provides a ground sign aggregation method. In this method, ground sign data collected by a target vehicle in a target area is obtained, and the ground sign data is clustered to obtain a ground sign feature list; according to the semantic objects in the ground sign feature list, all geometric point sequences are extracted, and multiple corresponding first polygon objects are generated based on all the geometric point sequences, and all the first polygon objects are stored in a first position list; a second polygon object is generated based on the first position list, and an overall cluster contour is generated based on the area of the second polygon object and the first position list; a corresponding standard graphic template is obtained according to the ground sign feature list, the overall cluster contour is fitted and corrected with the standard graphic template, and a fitting result is output. By introducing ground sign data to correct the correct angles of ground signs on the ground in the ground sign aggregation method, and by calculating the differences between the coordinate sequences and the mean multiple times and aligning and rotating with the aid of the standard graphic template, it can be more in line with the output of irregular polygons and make the output fitting point sequence with ground sign angle information more accurate.
[0046] Specifically, Figure 1 is a schematic flowchart of a ground sign aggregation method provided by an embodiment of the present application.
[0047] As Figure 1 shown, the ground sign aggregation method includes the following steps:
[0048] In step S101, ground sign data collected by a target vehicle in a target area is obtained, and the ground sign data is clustered to obtain a ground sign feature list.
[0049] It should be noted that in this application, the target vehicle is preferably a crowdsourcing mapping vehicle, and the ground mark data is preferably polygon ground mark data, such as an arrow; the target area is the area where the map needs to be drawn. The target vehicle travels multiple times on the same road in the area. When passing through the same relative position, multiple acquisition results will be formed, that is, the ground mark data collected by the target vehicle in the target area. Cluster the ground mark data, that is, the result list of aggregating semantic objects into clusters, to obtain the ground mark feature list. For example, when the semantic object is an arrow, cluster the arrows at the same relative position into a cluster to obtain the ground mark feature list feature_list. Among them, a single semantic object such as an arrow will have its geometric coordinates, angle, area, elevation and other attribute information.
[0050] In step S102, according to the semantic objects in the ground mark feature list, extract all geometric point sequences, and generate a plurality of corresponding first polygon objects according to all the geometric point sequences, and store all the first polygon objects in the first position list.
[0051] It should be noted that the ground mark feature list contains the geometric point sequences of semantic objects, where the semantic objects are ground marks, such as arrows, etc.; each semantic object is a closed three-dimensional figure, so there is its geometric point sequence. According to all the geometric point sequences, the first polygon object corresponding to each geometric point sequence can be generated correspondingly. The polygon object is a closed polygon object, and all the first polygon objects are stored in the first position list for convenient sorting and storage.
[0052] The step of extracting all geometric point sequences according to the semantic objects in the ground mark feature list, generating a plurality of corresponding first polygon objects according to all the geometric point sequences, and storing all the first polygon objects in the first position list specifically includes:
[0053] According to the ground mark feature list, extract all the geometric bodies of the semantic objects in the ground mark feature list, and obtain the geometric point sequences forming each geometric body;
[0054] Extract the coordinates in each geometric point sequence, store the coordinates in each geometric point sequence in the second position list, and obtain the centroid coordinates of the circumscribed shape of each geometric body according to the second position list;
[0055] According to the coordinates in each geometric point sequence, obtain the centroid coordinates of each geometric body, and generate difference coordinates according to the centroid coordinates of each geometric body and the centroid coordinates of the corresponding circumscribed shape;
[0056] Generate a first polygon object for each of the geometric point sequences based on the difference coordinates and the coordinates in each of the geometric point sequences, and store all the first polygon objects in a first position list.
[0057] Specifically, according to the list of ground mark features, extract the geometries of these semantic objects, obtain the geometric point sequences forming the geometries, extract the X and Y coordinates of the geometric point sequences, which can be represented in the form of a closed convex hull according to the coordinates, then obtain the coordinate points of the closed convex hull contour according to the closed convex hull, and store these coordinate points of the closed convex hull contour in a second position list. In an implementation manner of the present application, the second position list is the list hull. And obtain the centroid coordinate center_id1 of the closed convex hull contour formed by the second position list, and the centroid coordinate center_id2 of the circumscribed rectangle of the closed convex hull contour, where the centroid coordinate center_id2 of the circumscribed rectangle of the closed convex hull contour is the centroid coordinate of the circumscribed shape of each geometry, and calculate the average value center_id3 of the X and Y axes of the two coordinate points.
[0058] After that, loop through the entire list of ground mark features again, obtain the multiple centroid coordinates center_id4 of the semantic objects therein, calculate the difference center_id5 between center_id4 and center_id3, where center_id5 is the difference coordinate, then calculate the difference between the geometric point sequence of each geometry in the entire list of ground mark features and center_id5 in sequence, and form a new polygon object according to the obtained difference, which is the first polygon object, and store the first polygon object in the geos list, and the first position list is the geos list.
[0059] Further, the step of extracting the coordinates in each geometric point sequence, storing the coordinates in each geometric point sequence in a second position list, and obtaining the centroid coordinate of the circumscribed shape of each geometry according to the second position list specifically includes:
[0060] Extract the coordinates in each geometric point sequence and store the coordinates in each geometric point sequence in a second position list;
[0061] Generate a third polygon object for each geometry according to the second position list, and obtain the centroid coordinate of each third polygon object;
[0062] Generate a circumscribed rectangle for each third polygon object according to each third polygon object, and obtain the centroid coordinate of the circumscribed rectangle of each third polygon object, so as to obtain the centroid coordinate of the circumscribed shape of each geometry.
[0063] It should be noted that extracting the coordinates of the point sequence of the geometric body means extracting the X and Y coordinates of the point sequence of the geometric body. According to the second position list, a third polygon object, that is, a closed convex hull, of each geometric body is generated, and the centroid coordinates of each third polygon object are obtained; the centroid coordinates of the circumscribed rectangle of the third polygon object are the centroid coordinates of the circumscribed shape of each geometric body, that is, the centroid coordinates of the circumscribed rectangle of the third polygon object are center_id2.
[0064] In step S103, a second polygon object is generated according to the first position list, and an overall cluster profile is generated according to the area of the second polygon object and the first position list.
[0065] After obtaining the first position list, the point coordinates of the second polygon object are included in the first position list. Based on the first list, a second polygon object can be generated, where the second polygon object is the merged result of the first polygon objects obtained from the first position list. One of the first polygon objects is selected from the first position list according to the area of the second polygon object to generate the overall cluster profile.
[0066] Further, the generating a second polygon object according to the first position list and generating an overall cluster profile according to the area of the second polygon object and the first position list specifically includes:
[0067] Merge all the first polygon objects in the first position list to obtain a second polygon object, and obtain the area of the second polygon object;
[0068] Loop through the first position list and calculate the area of each first polygon object in the first position list;
[0069] Calculate the ratio of the area of each first polygon object to the area of the second polygon object, and generate an overall cluster profile according to the ratio.
[0070] Specifically, after obtaining the first position list, that is, obtaining the geos list, all the first polygon objects in the first position list, that is, polygon objects, are merged into a new polygon object, that is, the second polygon object, and its area area_all is obtained. Among them, all the first polygon objects in the first position list are reflected in the coordinates, and the area covered by all the first polygon objects in the first position list is used as the boundary of the second polygon object, thereby constructing the second polygon object and obtaining the area of the second polygon object.
[0071] Loop through the first position list "geos", sequentially obtain the areas of the first polygon objects from the first position list, and calculate the ratio of the area of the first polygon object to the area of the second polygon object. If the ratio of the area of the current first polygon object to the area of the second polygon object is less than the preset ratio threshold, delete the current first polygon object from the first position list; loop through all the first polygon objects in the first position list to finally obtain the updated first position list. If the length of the finally updated first position list is 0, that is, when the updated first position list does not contain any first polygon objects, take out the first semantic object in the ground marker feature list for storage and perform smoothing processing using the Douglas-Peucker thinning algorithm; if it is not 0, take out all the first polygon objects in the finally updated first position list for merging. If the merged type is MultiPolygon, that is, the merged type is a double-layer list, take out the first polygon object with the largest area as the preselected first polygon object for storage, generate a preselected overall cluster contour based on the preselected first polygon object, and smooth the preselected overall cluster contour to obtain the overall cluster contour; when the merged type is a single-layer list, take the only first polygon object in the updated first position list as the preselected first polygon object for storage, generate a preselected overall cluster contour based on the preselected first polygon object, and smooth the preselected overall cluster contour to obtain the overall cluster contour.
[0072] Further, the calculating the ratio of the area of each of the first polygon objects to the area of the second polygon object and generating an overall cluster contour based on the ratio specifically includes:
[0073] Calculate the ratio of the area of each of the first polygon objects to the area of the second polygon object;
[0074] Obtain the preselected first polygon objects with ratios less than the preset ratio threshold from the first position list;
[0075] Generate a preselected overall cluster contour based on the preselected first polygon objects, and smooth the preselected overall cluster contour to obtain the overall cluster contour.
[0076] It should be noted that the preset ratio threshold is set by the user according to prior knowledge. In an embodiment of the present application, preferably, the preset ratio threshold is set to 0.6; the smoothing processing of the preselected overall cluster contour is specifically performed using the Douglas-Peucker thinning algorithm.
[0077] In step S104, obtain the corresponding standard graphic template according to the ground marker feature list, fit and correct the overall cluster contour with the standard graphic template, and output the fitting result.
[0078] Specifically, in the present application, a standard graphic template is introduced as the shape of the fitting point sequence for the final output. The fitting point sequence is generated based on the previously obtained overall cluster contour and the standard graphic template. By introducing the standard graphic template, the final displayed ground sign is more beautiful and more in line with daily expressions. Among them, the standard graphic template is the standard shape and size released by the relevant region. For example, when an arrow is selected as the standard graphic template, the length, width, and various other information will be displayed in the relevant standard.
[0079] Furthermore, obtaining the corresponding standard graphic template according to the ground sign feature list, performing fitting correction on the overall cluster contour and the standard graphic template, and outputting the fitting result specifically includes:
[0080] Obtain the type of ground sign with the largest number in the ground sign feature list, and obtain the standard graphic template according to the type of ground sign;
[0081] Obtain the centroid coordinates of the overall cluster contour and the centroid coordinates of the standard graphic template, calculate the standard difference between the centroid coordinates of the overall cluster contour and the centroid coordinates of the standard graphic template, and subtract the point sequence of the standard graphic template from the standard difference respectively to obtain a list of standard difference point coordinates;
[0082] Generate a fourth polygon object according to the list of standard difference point coordinates, and obtain the centroid coordinates of the fourth polygon object;
[0083] Rotate the fourth polygon object according to the centroid coordinates of the fourth polygon object, and obtain the position with the largest intersection area with the overall cluster contour during the rotation process. According to this position, obtain a preset fitting point sequence;
[0084] Judge whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than a preset output threshold. If it is not less, then use the preset fitting point sequence as the fitting result and output it.
[0085] Specifically, judge the type of ground sign with the largest number according to the ground sign feature list, and obtain the standard model of the corresponding type and its subtypes from the model library, that is, the standard graphic template; and the fitting result is the fitting point sequence generated according to the preset fitting point sequence.
[0086] Randomly place the standard graphic template in the coordinate system, and obtain the standard deviation deviation of the centroid coordinates of the standard graphic template and the overall cluster contour; loop through the point sequence of the standard graphic template, subtract it from the deviation one by one to obtain the list of standard difference points template_data after subtraction. Through this process, the centroid coordinates of the standard graphic template are aligned with the centroid coordinates of the overall cluster contour. Further obtain the midpoint and relative offset coordinates of template_data, that is, generate a fourth polygon object according to the list of standard difference points coordinates, and obtain the centroid coordinates of the fourth polygon object. Among them, on the basis of having obtained template_data, generate a fourth polygon object, and obtain the midpoint, that is, form a polygon with template_data to obtain the fourth polygon object, and obtain its centroid coordinates. Among them, the relative offset coordinates are the coordinates of all points in template_dat.
[0087] Rotate the obtained midpoint counterclockwise around the centroid coordinates to obtain the list of intersection areas that can be produced during the rotation, that is, the inter_area list. Obtain the position with the largest intersection area with the overall cluster contour during the rotation from the inter_area list, record this position as the maximum position point, obtain the target point coordinates of the fourth polygon object at the maximum position point, and add the target point coordinates to the standard deviation to obtain the preset fitting point sequence. Determine whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold. If it is not less, then use the preset fitting point sequence as the fitting point sequence and output it. Since the fitting point sequence at this time is obtained at the position with the largest intersection area with the overall cluster contour during the rotation, the angle information can be obtained from the corresponding fitting point sequence. Among them, during the counterclockwise rotation, loop from 1 degree to 360 degrees in sequence until the position with the largest intersection area between the fourth polygon object and the overall cluster contour is found during the rotation.
[0088] Furthermore, after determining whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold, it further includes:
[0089] If the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold;
[0090] Obtain the trajectory data collected by the target vehicle in the target area, obtain the timestamp list of the semantic objects in the ground mark feature list according to the ground mark feature list, and obtain the azimuth angle according to the timestamp list and the trajectory data;
[0091] Based on the azimuth angle, rotate the fourth polygon object according to the centroid coordinates of the fourth polygon object, and obtain the updated position with the largest intersection area with the overall cluster contour during the rotation process. According to the updated position, obtain an updated preset fitting point sequence.
[0092] Generate an updated fitting result according to the updated preset fitting point sequence and output it.
[0093] Specifically, if the intersection area inter_area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold, rotate the fourth polygon object again according to the centroid coordinates of the fourth polygon object, update the intersection area list, obtain the updated position with the largest intersection area with the overall cluster contour during the rotation process from the inter_area list, obtain the target point coordinates of the fourth polygon object at the updated position, and add the target point coordinates to the standard deviation value to obtain an updated preset fitting point sequence. During this process, the rotation angle is limited within the azimuth angle. Further, obtain the minimum Z value, i.e., the elevation value, according to the updated preset fitting point sequence, update its elevation coordinates according to the elevation value, generate a target polygon object, assign the attribute of the cluster id to it, and output the fitting point sequence after fitting is completed. Among them, assigning the attribute of the cluster id means adding a unique identifier to it.
[0094] Furthermore, the steps of obtaining the azimuth angle specifically include: obtaining the trajectory data collected by the target vehicle in the target area, obtaining the timestamp list of the semantic objects in the ground landmark feature list according to the ground landmark feature list, and obtaining the azimuth angle according to the timestamp list and the trajectory data. Specifically, loop through the ground landmark feature list feature_list to obtain the timestamp list frame_id_s of the semantic objects in it. Sort frame_id_s in ascending order based on the timestamp, and recombine the sorted timestamp list of the trajectory data, that is, find the trajectory point corresponding to the first timestamp after reordering, and then find the trajectory point corresponding to the next timestamp. Among them, the trajectory point and the timestamp of the trajectory point are in one-to-one correspondence and are associated through a dictionary structure; therefore, the corresponding trajectory point can be found by finding the timestamp. Take out the sorted timestamp list time_tmp of the trajectory data. Take the trajectory point corresponding to the first timestamp of the sorted timestamp list time_tmp of the trajectory data as the starting point, find the trajectory point corresponding to the next timestamp of this trajectory point as the ending point, and calculate the azimuth angle degree between the starting point and the ending point.
[0095] Among them, the method for calculating the azimuth degree between the starting point and the ending point is specifically as follows: Obtain the longitude and latitude of point A, pointA(latA, lonA), and the longitude and latitude of point B, pointB(latB, lonB), where latA is the latitude of point A, lonA is the longitude of point A; latB is the latitude of point B, and lonB is the longitude of point B. First, convert the longitude and latitude of point A and point B into radians respectively, and the conversion is specifically carried out through the following formula:
[0096] rad_lat_a = math.radians(latA);
[0097] rad_lon_a = math.radians(lonA);
[0098] rad_lat_b = math.radians(latB);
[0099] rad_lon_b = math.radians(lonB);
[0100] Then the longitude difference between point A and point B is expressed as:
[0101] d_lon = rad_lon_b - rad_lon_a;
[0102] Then the azimuth degree is calculated through the following formula:
[0103]
[0104] degree = (angle + 360) % 360;
[0105] Among them, rad_lat_a and rad_lon_a are the radians corresponding to the latitude and the radians corresponding to the longitude of point A, rad_lat_b and rad_lon_b are the radians corresponding to the latitude and the radians corresponding to the longitude of point B, math.radians is to convert the longitude and latitude into radians, angel is the angle, degree is the azimuth, and math.degrees is to convert the angle from radians to degrees.
[0106] This application further describes an implementation manner of the ground mark aggregation method of this application through Figure 2 Specifically, it includes:
[0107] Step S21: Start;
[0108] Step S22: Input polygon ground mark data;
[0109] Step S23: Obtain the centroid coordinates of the first polygon object of the geometric body point sequence;
[0110] Step S24: Obtain the centroid coordinates of the circumscribed shape of the geometric body;
[0111] Step S25: Output the overall cluster contour;
[0112] Step S26: Obtain the corresponding standard graphic template from the model library;
[0113] Step S27: Align the centroid of the standard graphic template with the centroid of the overall cluster contour, rotate, obtain the maximum intersection area, and output;
[0114] Step S28: Output the fitting point sequence;
[0115] Step S29: End.
[0116] This application further describes the process of obtaining the azimuth angle in the ground mark aggregation method of this application through Figure 3 which specifically includes:
[0117] Step S31: Sort frame_id_s in ascending order based on the time stamp, and recombine the sorted time stamp list of the trajectory data to obtain the sorted time stamp list time_tmp of the trajectory data;
[0118] Step S32: Use the trajectory point corresponding to the first time stamp in the sorted time stamp list time_tmp of the trajectory data as the starting point;
[0119] Step S33: Find the trajectory point corresponding to the next time stamp of this trajectory point as the end point;
[0120] Step S34: Calculate the azimuth angle degree between the starting point and the end point.
[0121] This application further describes the process of obtaining the centroid coordinates of the first polygon object of the geometric body point sequence in the ground mark aggregation method of this application through Figure 4 which specifically includes:
[0122] Step S41: According to the ground mark feature list, extract the geometric bodies of these semantic objects to obtain the geometric body point sequence forming the geometric body;
[0123] Step S42: Obtain the closed convex hull contours of the geometric bodies, store the coordinate points of these closed convex hull contours in the second position list, obtain the centroid coordinate center_id1 of the closed convex hull contour formed by the second position list, and the centroid coordinate center_id2 of the circumscribed rectangle of the closed convex hull contour. The centroid coordinate center_id2 of the circumscribed rectangle of the closed convex hull contour is the centroid coordinate of the circumscribed shape of each geometric body. Calculate the average values center_id3 of the X and Y axes of the two coordinate points;
[0124] Step S43: Recursively loop through the entire ground marker feature list, obtain multiple centroid coordinates center_id4 of the semantic objects therein, calculate the difference center_id5 between center_id4 and center_id3. The center_id5 is the difference coordinate. Then, calculate the differences between the geometric point sequences of each geometric body in the entire ground marker feature list and center_id5 in sequence, and form a new polygon object based on the obtained differences, which is the first polygon object. Store the first polygon object in the geos list;
[0125] Step S44: Merge all the first polygon objects, i.e., polygon objects, in the first position list into a new polygon object, i.e., the second polygon object, and obtain its area area_all.
[0126] This application further describes the process of outputting the overall cluster contour in the ground marker aggregation method of this application through Figure 5 as follows. Specifically, it includes:
[0127] Step S51: Loop through the first position list geos. If the ratio of the area of the current first polygon object to the area of the second polygon object is less than the preset ratio threshold, delete the current first polygon object from the first position list. After the loop ends, obtain the updated first position list;
[0128] Step S52: If the length of the finally updated first position list is 0, take out the first semantic object in the ground marker feature list for storage, and perform smoothing processing using the Douglas-Peucker decimation algorithm;
[0129] Step S53: If it is not 0, take out and merge all the first polygon objects in the finally updated first position list;
[0130] Step S54: If the merged type is MultiPolygon, that is, the merged type is a double-layer list, then take out the first polygon object with the largest area as the preselected first polygon object for storage, generate a preselected overall cluster contour based on the preselected first polygon object, and smooth the preselected overall cluster contour.
[0131] This application further describes the process of aligning the standard graphic template with the centroid of the overall cluster contour and rotating it in the method for aggregating ground signs of this application, specifically including: Figure 6 Step S61: Obtain the standard deviation deviation of the centroid coordinates of the standard graphic template and the overall cluster contour; loop through the point sequence of the standard graphic template, subtract deviation from each point in turn to obtain the list of standard difference points template_data after subtraction;
[0132] Step S62: Further obtain the midpoint and relative offset coordinates of template_data;
[0133] Step S63: Rotate the obtained midpoint counterclockwise with the centroid coordinates as the rotation point to obtain the list of intersection areas that can be produced during the rotation process;
[0134] Step S64: Obtain the position with the largest intersection area with the overall cluster contour during the rotation process from the inter_area list, and obtain the preset fitting point sequence according to this position.
[0135] This application further describes the process of outputting the fitting point sequence in the method for aggregating ground signs of this application, specifically including:
[0136] This application further describes the process of outputting the fitting point sequence in the method for aggregating ground signs of this application, specifically including: Figure 7 Step S71: If the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster contour is less than the preset output threshold;
[0137] Step S72: Rotate the fourth polygon object again according to the centroid coordinates of the fourth polygon object, update the intersection area list, obtain the updated position with the largest intersection area with the overall cluster contour during the rotation process from the inter_area list, obtain the target point coordinates of the fourth polygon object at the updated position, and add the target point coordinates to the standard deviation to obtain the updated preset fitting point sequence. The rotation angle is limited within the azimuth angle during this process;
[0138] Step S73: Obtain the minimum Z value of the updated preset fitting point sequence, update its elevation coordinates according to the elevation value, generate a target polygon object, assign the attribute of the cluster id to it, and output the fitting completed fitting point sequence.
[0139] Step S73: Obtain the minimum Z value of the updated preset fitting point sequence, update its elevation coordinates according to the elevation value, generate a target polygon object, assign the attribute of the cluster id to it, and output the fitting completed fitting point sequence.
[0140] In the embodiment of the present application, by introducing ground marker data to correct the correct angle of the ground marker on the ground, and by calculating the difference between the coordinate sequence and the mean value multiple times, and aligning and rotating with the aid of a standard graphic template, it can be more in line with the output of an irregular polygon, making the output fitting point sequence with ground marker angle information more accurate; by generating a second polygon object through multiple first polygon objects, and obtaining the overall cluster contour from multiple first polygon objects through the area of the second polygon object, the overall cluster contour obtained in the present invention is not less than a certain value, so that the fitting point sequence generated subsequently with the aid of the overall cluster contour is also limited to a certain extent, and a fitting point sequence with a large difference from the actual situation will not be output, that is, the output fitting point sequence is made more accurate through the overall cluster contour; through the ground marker data obtained by the target vehicle in the target area, the corresponding fitting point sequence containing the ground marker data is obtained, so that the present invention can accurately obtain the aggregation angle of the ground marker graphics for some irregular ground markers collected, and the obtained fitting point sequence can be represented on the map where it needs to appear.
[0141] Next, a ground marker aggregation system according to an embodiment of the present application will be described with reference to the accompanying drawings.
[0142] Figure 8 It is a schematic structural diagram of the ground marker aggregation system according to an embodiment of the present application.
[0143] As Figure 8 shown, the ground marker aggregation system 10 includes: a data acquisition module 100, a first polygon object acquisition module 200, an overall cluster contour acquisition module 300, and a result output module 400.
[0144] Specifically, the data acquisition module 100 is configured to acquire ground marker data collected by a target vehicle in a target area, and cluster the ground marker data to obtain a ground marker feature list;
[0145] The first polygon object acquisition module 200 is configured to extract all geometric point sequences according to the semantic objects in the ground marker feature list, generate a plurality of corresponding first polygon objects according to all the geometric point sequences, and store all the first polygon objects in a first position list;
[0146] The overall cluster contour acquisition module 300 is configured to generate a second polygon object according to the first position list, and generate an overall cluster contour according to the area of the second polygon object and the first position list;
[0147] The result output module 400 is configured to obtain a corresponding standard graphic template according to the ground marker feature list, perform fitting correction on the overall cluster contour and the standard graphic template, and output a fitting result.
[0148] Optionally, in an embodiment of the present application, the first polygon object obtaining module 200 includes: a geometric body point sequence obtaining unit, configured to extract all geometric bodies of the semantic objects in the ground mark feature list according to the ground mark feature list, and obtain a geometric body point sequence forming each geometric body; a circumscribed shape centroid coordinate obtaining unit, configured to extract the coordinates in each geometric body point sequence, store the coordinates in each geometric body point sequence into a second position list, and obtain the centroid coordinates of the circumscribed shape of each geometric body according to the second position list; a difference coordinate generating unit, configured to obtain the centroid coordinates of each geometric body according to the coordinates in each geometric body point sequence, and generate difference coordinates according to the centroid coordinates of each geometric body and the centroid coordinates of the corresponding circumscribed shape; a first polygon object storing unit, configured to generate a first polygon object for each geometric body point sequence according to the difference coordinates and the coordinates in each geometric body point sequence, and store all the first polygon objects into a first position list.
[0149] Optionally, in an embodiment of the present application, the circumscribed shape centroid coordinate obtaining unit includes: a second position list storing sub-unit, configured to extract the coordinates in each geometric body point sequence and store the coordinates in each geometric body point sequence into a second position list; a third polygon object centroid coordinate obtaining sub-unit, configured to generate a third polygon object for each geometric body according to the second position list and obtain the centroid coordinates of each third polygon object; a circumscribed rectangle centroid coordinate obtaining sub-unit, configured to generate a circumscribed rectangle for each third polygon object according to each third polygon object and obtain the centroid coordinates of the circumscribed rectangle of each third polygon object, so as to obtain the centroid coordinates of the circumscribed shape of each geometric body.
[0150] Optionally, in an embodiment of the present application, the overall cluster profile obtaining module 300 includes: a second polygon object obtaining unit, configured to merge all the first polygon objects in the first position list to obtain a second polygon object and obtain the area of the second polygon object; a first polygon object area calculating unit, configured to loop through the first position list and calculate the area of each first polygon object in the first position list; a calculating and generating overall cluster profile unit, configured to calculate the ratio of the area of each first polygon object to the area of the second polygon object, and generate an overall cluster profile according to the ratio.
[0151] Optionally, in an embodiment of the present application, the calculation and generation of the overall cluster profile unit includes: a first area ratio calculation subunit, configured to calculate the ratio of the area of each of the first polygon objects to the area of the second polygon object; a preselected first polygon object acquisition subunit, configured to acquire preselected first polygon objects with a ratio less than a preset ratio threshold from the first position list; a merged overall cluster profile generation subunit, configured to generate a preselected overall cluster profile based on the preselected first polygon objects, and perform smoothing processing on the preselected overall cluster profile to obtain an overall cluster profile.
[0152] Optionally, in an embodiment of the present application, the result output module 400 includes: a standard graphic template acquisition unit, configured to acquire the most numerous ground mark type in the ground mark feature list, and acquire a standard graphic template according to the ground mark type; a difference point coordinate list acquisition unit, configured to acquire the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, calculate the standard difference between the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, and perform subtraction on the point sequence of the standard graphic template and the standard difference respectively to obtain a standard difference point coordinate list; a fourth polygon object centroid coordinate acquisition unit, configured to generate a fourth polygon object based on the standard difference point coordinate list, and acquire the centroid coordinates of the fourth polygon object; a preset fitting point sequence generation unit, configured to rotate the fourth polygon object based on the centroid coordinates of the fourth polygon object, and acquire the position with the largest intersection area with the overall cluster profile during the rotation process, and obtain a preset fitting point sequence according to the position; a judgment and output unit, configured to judge whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold, and if not less, use the preset fitting point sequence as the fitting result and output it.
[0153] Optionally, in an embodiment of the present application, the judgment and output unit includes: an abnormality acquisition subunit, configured to if the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold; an azimuth angle acquisition subunit, configured to acquire the trajectory data collected by the target vehicle in the target area, acquire the timestamp list of the semantic objects in the ground mark feature list according to the ground mark feature list, and acquire the azimuth angle according to the timestamp list and the trajectory data; an updated preset fitting point sequence generation subunit, configured to rotate the fourth polygon object based on the centroid coordinates of the fourth polygon object based on the azimuth angle, and acquire the updated position with the largest intersection area with the overall cluster profile during the rotation process, and obtain an updated preset fitting point sequence according to the updated position; a fitting point sequence re-output subunit, configured to generate an updated fitting result according to the updated preset fitting point sequence and output it.
[0154] It should be noted that the foregoing explanation of the embodiment of the ground mark aggregation method is also applicable to the ground mark aggregation system of this embodiment, and will not be elaborated here.
[0155] In view of the problem in the prior art that when aggregating some irregular ground marks collected by a mapping vehicle, since the directions of the ground marks collected each time are not exactly the same, and due to the inability to correctly identify the overall direction judgment, the angle of the ground mark graphic aggregation will be disordered. The present application provides a ground mark aggregation method. In this method, ground mark data collected by a target vehicle in a target area is obtained, and the ground mark data is clustered to obtain a ground mark feature list; according to the semantic objects of the ground mark feature list, all geometric point sequences are extracted, and a plurality of corresponding first polygon objects are generated according to all the geometric point sequences, and all the first polygon objects are stored in a first position list; a second polygon object is generated according to the first position list, and an overall cluster contour is generated according to the area of the second polygon object and the first position list; a corresponding standard graphic template is obtained according to the ground mark feature list, the overall cluster contour is fitted and corrected with the standard graphic template, and a fitting result is output.
[0156] Figure 9 The following is a schematic structural diagram of a terminal provided by an embodiment of the present application. The terminal may include:
[0157] A memory 501, a processor 502, and a computer program stored on the memory 501 and executable on the processor 502.
[0158] When the processor 502 executes the program, it implements the ground mark aggregation method provided in the foregoing embodiment.
[0159] Further, the terminal further includes:
[0160] A communication interface 503 for communication between the memory 501 and the processor 502.
[0161] The memory 501 is used to store a computer program executable on the processor 502.
[0162] The memory 501 may include a high-speed RAM memory, and may also include a non-volatile memory, such as at least one disk memory.
[0163] If the memory 501, the processor 502, and the communication interface 503 are implemented independently, the communication interface 503, the memory 501, and the processor 502 can be interconnected via a bus and communicate with each other. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 9 only a thick line is used in Figure 9 , but this does not mean that there is only one bus or one type of bus.
[0164] Optionally, in a specific implementation, if the memory 501, the processor 502, and the communication interface 503 are integrated on a single chip, the memory 501, the processor 502, and the communication interface 503 can communicate with each other via an internal interface.
[0165] The processor 502 may be a Central Processing Unit (CPU), or an Application Specific Integrated Circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present application.
[0166] This embodiment also provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the above-mentioned ground mark aggregation method is implemented.
[0167] In the description of this specification, the description with reference to terms such as "one embodiment", "some embodiments", "example", "specific example", or "some examples" means that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any one or N embodiments or examples in a suitable manner. In addition, without conflict, those skilled in the art can combine and combine the different embodiments or examples described in this specification and the features of different embodiments or examples.
[0168] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include at least one such feature. In the description of this application, the meaning of "N" is at least two, such as two, three, etc., unless otherwise specifically defined.
[0169] Any process or method description represented in a flowchart or described otherwise herein can be understood to represent a module, segment, or portion of code including one or N executable instructions for implementing a customized logical function or process. The scope of the preferred embodiments of this application includes additional implementations, where functions may be executed in a substantially simultaneous manner or in a reverse order according to the involved functions, rather than in the order shown or discussed, which should be understood by those skilled in the technical field to which the embodiments of this application pertain.
[0170] Logic and / or steps represented in a flowchart or described otherwise herein, for example, can be considered as an ordered list of executable instructions for implementing a logical function and can be specifically implemented in any computer-readable storage medium for use by an instruction execution system, apparatus, or vehicle (such as a computer-based system, a system including a processor, or other systems that can fetch and execute instructions from the instruction execution system, apparatus, or vehicle), or in conjunction with these instruction execution systems, apparatuses, or vehicles. For the purposes of this specification, a "computer-readable storage medium" can be any device that can contain, store, communicate, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or vehicle. More specific examples (non-exhaustive list) of computer-readable storage media include the following: an electrical connection portion with one or N wirings (electronic device), a portable computer diskette (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, a computer-readable storage medium can even be paper or other suitable media on which the program can be printed, because the program can be obtained electronically by optically scanning the paper or other media, followed by editing, interpretation, or other appropriate processing as necessary, and then stored in a computer memory.
[0171] It should be understood that each part of the present application can be implemented by hardware, software, firmware, or a combination thereof. In the above embodiments, the N steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, any one or a combination of the following techniques well known in the art can be used: discrete logic circuits with logic gate circuits for implementing logic functions on data signals, application specific integrated circuits with appropriate combinational logic gate circuits, programmable gate arrays (PGAs), field programmable gate arrays (FPGAs), etc.
[0172] Those of ordinary skill in the art can understand that all or part of the steps carried by the method of implementing the above embodiments can be completed by instructing relevant hardware through a program. The said program can be stored in a computer-readable storage medium. When the program is executed, it includes one or a combination of the steps of the method embodiments.
[0173] In addition, in each embodiment of the present application, the functional units can be integrated in a processing module, or each unit can exist physically alone, or two or more units can be integrated in a module. The above integrated module can be implemented in the form of hardware or in the form of a software functional module. When the above integrated module is implemented in the form of a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium.
[0174] The above-mentioned storage medium can be a read-only memory, a magnetic disk, an optical disc, etc. Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limiting the present application. Those of ordinary skill in the art can make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present application.
[0175] It should be understood that the application of the present application is not limited to the above examples. For those of ordinary skill in the art, improvements or transformations can be made according to the above description. All such improvements and transformations should fall within the protection scope of the appended claims of the present application.
Claims
1. A method for aggregating ground signs, characterized in that, The above-mentioned ground sign aggregation method includes: Obtain the ground sign data collected by a target vehicle in a target area, and cluster the ground sign data to obtain a ground sign feature list; According to the semantic objects in the ground sign feature list, extract all geometric point sequences, and generate a plurality of corresponding first polygon objects according to all the geometric point sequences, and store all the first polygon objects in a first position list; Generate a second polygon object according to the first position list, and generate an overall cluster contour according to the area of the second polygon object and the first position list; Obtain a corresponding standard graphic template according to the ground sign feature list, fit and correct the overall cluster contour with the standard graphic template, and output the fitting result.
2. The method for aggregating ground signs according to claim 1, characterized in that, The step of, according to the semantic objects in the ground sign feature list, extracting all geometric point sequences, generating a plurality of corresponding first polygon objects according to all the geometric point sequences, and storing all the first polygon objects in a first position list specifically includes: According to the ground sign feature list, extract all the geometric bodies of the semantic objects in the ground sign feature list, and obtain the geometric point sequences forming each geometric body; Extract the coordinates in each geometric point sequence, store the coordinates in each geometric point sequence in a second position list, and obtain the centroid coordinates of the circumscribed shape of each geometric body according to the second position list; According to the coordinates in each geometric point sequence, obtain the centroid coordinates of each geometric body, and generate difference coordinates according to the centroid coordinates of each geometric body and the centroid coordinates of the corresponding circumscribed shape; Generate a first polygon object for each geometric point sequence according to the difference coordinates and the coordinates in each geometric point sequence, and store all the first polygon objects in the first position list.
3. The method for aggregating ground signs according to claim 2, characterized in that, The step of extracting the coordinates in each geometric point sequence, storing the coordinates in each geometric point sequence in a second position list, and obtaining the centroid coordinates of the circumscribed shape of each geometric body according to the second position list specifically includes: Extract the coordinates in each geometric point sequence, and store the coordinates in each geometric point sequence in a second position list; Generate a third polygon object for each geometric body according to the second position list, and obtain the centroid coordinates of each third polygon object; generate a circumscribed rectangle for each third polygon object according to each third polygon object, and obtain the centroid coordinates of the circumscribed rectangle of each third polygon object, so as to obtain the centroid coordinates of the circumscribed shape of each geometric body.
4. The method for aggregating ground signs according to claim 1, characterized in that, The step of generating a second polygon object according to the first position list, and generating an overall cluster contour according to the area of the second polygon object and the first position list specifically includes: merging all the first polygon objects in the first position list to obtain a second polygon object, and obtaining the area of the second polygon object; Loop through the first position list, and calculate the area of each first polygon object in the first position list. Calculate the ratio of the area of each of the first polygon objects to the area of the second polygon object, and generate an overall cluster profile according to the ratio.
5. The method for aggregating ground signs according to claim 4, characterized in that, The step of calculating the ratio of the area of each of the first polygon objects to the area of the second polygon object and generating an overall cluster profile according to the ratio specifically includes: Calculate the ratio of the area of each of the first polygon objects to the area of the second polygon object; Obtain preselected first polygon objects with ratios less than a preset ratio threshold from the first position list; Generate a preselected overall cluster profile according to the preselected first polygon objects, and smooth the preselected overall cluster profile to obtain an overall cluster profile.
6. The method for aggregating ground signs according to claim 1, characterized in that, The step of obtaining a corresponding standard graphic template according to the ground mark feature list, fitting and correcting the overall cluster profile with the standard graphic template, and outputting a fitting result specifically includes: Obtain the most numerous ground mark type in the ground mark feature list, and obtain a standard graphic template according to the ground mark type; obtain the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, calculate the standard difference between the centroid coordinates of the overall cluster profile and the centroid coordinates of the standard graphic template, and subtract the point sequence of the standard graphic template from the standard difference respectively to obtain a standard difference point coordinate list; Generate a fourth polygon object according to the standard difference point coordinate list, and obtain the centroid coordinates of the fourth polygon object; Rotate the fourth polygon object according to the centroid coordinates of the fourth polygon object based on the azimuth angle, and obtain the position with the largest intersection area with the overall cluster profile during the rotation process. According to the position, obtain a preset fitting point sequence; Judge whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold. If it is not less, use the preset fitting point sequence as the fitting result and output it.
7. The method for aggregating ground signs according to claim 6, characterized in that, After judging whether the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold, it further includes: If the intersection area between the preset fitting object constructed by the preset fitting point sequence and the overall cluster profile is less than a preset output threshold; obtain the trajectory data collected by the target vehicle in the target area, obtain the timestamp list of the semantic objects in the ground mark feature list according to the ground mark feature list, and obtain the azimuth angle according to the timestamp list and the trajectory data; Based on the azimuth angle, rotate the fourth polygon object according to the centroid coordinates of the fourth polygon object, and obtain the updated position with the largest intersection area with the overall cluster profile during the rotation process. According to the updated position, obtain an updated preset fitting point sequence; Generate an updated fitting result according to the updated preset fitting point sequence and output it.
8. A system for aggregating ground signs, characterized in that, The ground mark aggregation system includes: A data acquisition module, configured to acquire ground mark data collected by a target vehicle in a target area, and cluster the ground mark data to obtain a ground mark feature list; The first polygon object acquisition module is configured to extract all geometric point sequences according to the semantic objects in the ground mark feature list, generate a plurality of corresponding first polygon objects based on all the geometric point sequences, and store all the first polygon objects in a first position list; The overall cluster contour acquisition module is configured to generate a second polygon object according to the first position list, and generate an overall cluster contour according to the area of the second polygon object and the first position list; The result output module is configured to obtain a corresponding standard graphic template according to the ground mark feature list, perform fitting correction on the overall cluster contour and the standard graphic template, and output a fitting result.
9. A terminal, characterized in that, The terminal includes: a memory, a processor, and a ground mark aggregation program stored on the memory and executable on the processor. When the ground mark aggregation program is executed by the processor, the steps of the ground mark aggregation method according to any one of claims 1-7 are implemented.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a ground mark aggregation program. When the ground mark aggregation program is executed by a processor, the steps of the ground mark aggregation method according to any one of claims 1-7 are implemented.