Three-dimensional data benchmark conversion method and device, computer equipment and storage medium
By textualizing and partitioning the three-dimensional data and performing reference conversion for each sub-region, the problem of insufficient reference conversion efficiency of three-dimensional data in the prior art is solved, and more efficient data processing and conversion is achieved.
Patent Information
- Application Number
- CN202411955230.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-04-04
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing three-dimensional data reference conversion method is very computationally effective when processing large-scale and complex three-dimensional data, resulting in insufficient conversion efficiency of computer hardware and affecting surveying and mapping geographic information production operations.
By textualizing the three-dimensional data, the text data set is obtained, and the data set is partitioned according to the data volume, the processing efficiency and division strategy of the computing device, and plane reference conversion and elevation conversion are performed for each sub-region, reducing the calculation amount and improving efficiency.
Through partition processing and multi-dimensional coordinate conversion, the amount of data processed at one time is reduced, the calculation efficiency of surveying and mapping geographic information data production is improved, and the efficiency of coordinate reference conversion is improved.
Smart Images

Figure CN119761310A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a three-dimensional data reference conversion method, device, computer equipment, storage medium and computer program product. Background Art
[0002] With the acceleration of cross-border integration of information technology and surveying and mapping geographic information technology, the refinement of urban management, and the diversification of social needs, the development of 3D technology has put forward higher requirements for spatial reference services. In 3D data processing, reference conversion is a core link. Reference conversion is used to unify 3D data in different coordinate systems into the same coordinate system for subsequent analysis, modeling, visualization and other operations.
[0003] The benchmark conversion method in the related art adopts a globally unified pixel-by-pixel or point-by-point processing strategy, which requires high computing power of computer hardware to support. When processing large-scale and complex three-dimensional data through the benchmark conversion method, due to the large amount of calculation required by the benchmark conversion method, the existing computer hardware level cannot support the conversion within the preset time, resulting in insufficient conversion efficiency of computer hardware, thus affecting the actual surveying and mapping geographic information production operations. Summary of the invention
[0004] Based on this, it is necessary to provide a three-dimensional data benchmark conversion method, device, computer equipment, computer-readable storage medium and computer program product that can improve the benchmark conversion efficiency in response to the above technical problems.
[0005] In a first aspect, the present application provides a three-dimensional data benchmark conversion method. The method comprises:
[0006] Performing text processing on the three-dimensional data to obtain a text data set corresponding to the three-dimensional data; the text data set is used to represent the position information of each unit data in the three-dimensional data in structured text; the unit data includes pixel or point data;
[0007] According to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each of the three-dimensional data, the text data set is partitioned to obtain a plurality of sub-areas; the data volume is determined based on the pixel size or point data volume of the three-dimensional data; the processing efficiency is determined based on the timeliness value of the conversion task, the number of cores of the computing device and the point-by-point processing speed; the three-dimensional data includes at least one of digital elevation model DEM data, digital surface model DSM data and laser scanning LAS data;
[0008] For each sub-region, the original coordinates of each unit data in the sub-region are determined, and the plane coordinates in the original coordinates are subjected to plane reference transformation according to an affine transformation model to obtain the plane coordinates after the transformation of each unit data in the sub-region; the affine transformation model is obtained by solving a polynomial model determined by grid points by the least square method;
[0009] Determine the elevation anomaly value of each unit data in the sub-area, and perform elevation conversion on the elevation coordinates of the original coordinates by using the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-area; the elevation anomaly value is determined based on a weight function within a fitting radius and an interpolation function model;
[0010] The converted plane coordinates and the converted elevation coordinates are determined as the converted coordinates of the unit data reference.
[0011] In one embodiment, the text processing of the three-dimensional data to obtain a text data set corresponding to the three-dimensional data includes:
[0012] When the three-dimensional data is DEM data or DSM data, the three-dimensional data is parsed to obtain a text data set consisting of textual plane coordinates and elevation coordinates; the file header of the text data set includes row and column information, the lower left corner coordinates of the lower left corner pixel, and the pixel size;
[0013] When the three-dimensional data is LAS data, the public file header of the LAS data is parsed to obtain basic information and metadata; the point data record of the LAS data is read to obtain coordinate information and attribute information; the variable-length record and extended variable-length record of the LAS data are read to obtain additional metadata; and the basic information, the metadata, the coordinate information, the attribute information and the additional metadata are determined to be a text data set corresponding to the LAS data.
[0014] In one embodiment, the text data set is partitioned according to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each of the three-dimensional data to obtain a plurality of sub-areas, including:
[0015] Determine the total number of pixels or points in the text data set, and the quotient of the total number of pixels or points and the processing efficiency of the computing device is the number of partitions; the processing efficiency is the product of the time value of the conversion task, the number of cores of the computing device, and the point-by-point processing speed;
[0016] According to the division strategy corresponding to the data type of the three-dimensional data and the number of partitions, the text data set is divided to obtain multiple sub-areas; the division strategy corresponding to the DEM data and DSM data is a parallel division strategy, and the division strategy corresponding to the LAS data is a row and column random division strategy.
[0017] In one embodiment, determining the original coordinates of each unit data in the sub-area includes:
[0018] In the case where the three-dimensional data is DEM data or DSM data, the number of data rows of the sub-region is determined according to the row and column information of the text data set; the lower left corner coordinates of the sub-region are determined based on the number of data rows and the pixel size of the text data set; the center point coordinates of each pixel in the sub-region are determined according to the lower left corner coordinates and the pixel size, and the center point coordinates are determined as the original coordinates;
[0019] When the three-dimensional data is LAS data, the coordinate information of the LAS data is restored according to the offset coordinates and scaling factors of the LAS data to obtain the original coordinates of each point data; the offset coordinates and scaling factors of each sub-area are the same.
[0020] In one embodiment, performing a plane reference transformation on the plane coordinates in the original coordinates according to the affine transformation model to obtain the plane coordinates after the transformation of each unit data in the sub-region includes:
[0021] Based on the grid points with the same name between the source coordinate system and the target coordinate system, a polynomial model is determined; the coefficients of the polynomial model include a pixel width, a first rotation parameter, a horizontal coordinate value of the center of the upper left pixel, a second rotation parameter, a negative pixel height, and a vertical coordinate value of the center of the upper left pixel;
[0022] Solving the coefficients of the polynomial model based on the least squares method until the sum of square errors of all grid points in the polynomial model is less than a preset value, thereby obtaining an affine transformation model;
[0023] The plane coordinates in the original coordinates are input into the affine transformation model to obtain the transformed plane coordinates.
[0024] In one embodiment, determining the elevation anomaly value of each pixel in the sub-region includes:
[0025] For each unit data in the sub-area, determining the distance between the to-be-converted data point corresponding to each unit data and the grid data point of the quasi-geoid refined model;
[0026] Determining a weight function value corresponding to the distance according to the weight function within the fitting radius;
[0027] The weight function value is input into the interpolation function model to obtain the elevation anomaly value corresponding to the data point to be converted.
[0028] In one embodiment, performing elevation conversion on the elevation coordinates of the original coordinates by using the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-area includes:
[0029] The elevation coordinate of the original coordinate is subtracted from the elevation anomaly value to obtain the converted elevation coordinate.
[0030] In a second aspect, the present application also provides a three-dimensional data reference conversion device. The device comprises:
[0031] A data text module, used for text processing of the three-dimensional data to obtain a text data set corresponding to the three-dimensional data; the text data set is used to represent the position information of each unit data in the three-dimensional data in structured text; the unit data includes pixel or point data;
[0032] A data partitioning module, for partitioning the text data set to obtain a plurality of sub-areas according to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each of the three-dimensional data; the data volume is determined based on the pixel size or point data volume of the three-dimensional data; the processing efficiency is determined based on the timeliness value of the conversion task, the number of cores of the computing device and the point-by-point processing speed; the three-dimensional data includes at least one of digital elevation model DEM data, digital surface model DSM data and laser scanning LAS data;
[0033] A first conversion module is used to determine, for each sub-region, the original coordinates of each unit data in the sub-region, and perform a plane reference conversion on the plane coordinates in the original coordinates according to an affine transformation model to obtain the converted plane coordinates of each unit data in the sub-region; the affine transformation model is obtained by solving a polynomial model determined by grid points by a least square method;
[0034] A second conversion module is used to determine the elevation anomaly value of each unit data in the sub-area, and perform elevation conversion on the elevation coordinates of the original coordinates through the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-area; the elevation anomaly value is determined based on a weight function within a fitting radius and an interpolation function model;
[0035] The coordinate determination module is used to determine the converted plane coordinates and the converted elevation coordinates, which are the coordinates converted from the unit data reference.
[0036] In a third aspect, the present application further provides a computer device, wherein the computer device comprises a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the method described in the first aspect are implemented.
[0037] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the method described in the first aspect are implemented.
[0038] In a fifth aspect, the present application further provides a computer program product, wherein the computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the method described in the first aspect are implemented.
[0039] The above-mentioned three-dimensional data benchmark conversion method, device, computer equipment, storage medium and computer program product obtain a text data set corresponding to the three-dimensional data by text processing the three-dimensional data, and partition the text data set according to the data volume of the text data set, the processing efficiency of the computing device, and the division strategy of the three-dimensional data to obtain multiple sub-areas. For each sub-area, benchmark conversion can be performed separately. Since the three-dimensional data can be at least one of digital elevation model DEM data, digital surface model DSM data and laser scanning LAS data, the data volume of the three-dimensional data can be determined by the pixel size or the point data volume. For different types of three-dimensional data, the original coordinates of each unit data in the sub-area can be determined, and the original coordinates are plane benchmark transformed through the affine transformation model to obtain the plane coordinates after the conversion of each unit data; the original coordinates are elevation transformed through the elevation outlier to obtain the elevation coordinates after the conversion of each unit data. Finally, the converted plane coordinates and elevation coordinates are merged to obtain the three-dimensional data after benchmark conversion. By partitioning the three-dimensional data and matching the partition size so that the partition can adapt to the computing power provided by the computing device, the amount of data processed at one time can be reduced, and the calculation efficiency of surveying and mapping geographic information data production can be improved. In addition, the original coordinates are converted through plane reference conversion and elevation conversion to convert the coordinate data of three dimensions respectively, reducing the number of dimensions converted at the same time, which can improve the efficiency of coordinate reference conversion. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the drawings required for use in the embodiments or the related technical descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0041] Figure 1 A diagram showing an application environment of a three-dimensional data reference conversion method in one embodiment;
[0042] Figure 2 A schematic diagram of a process flow of a method for converting a three-dimensional data reference in one embodiment;
[0043] Figure 3 A schematic diagram of a process flow of a plane reference conversion step in an embodiment;
[0044] Figure 4 A schematic diagram of a flow chart of a step of determining an elevation abnormal value in one embodiment;
[0045] Figure 5 A block diagram of a reference conversion device for three-dimensional data in one embodiment;
[0046] Figure 6 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0047] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0048] The three-dimensional data reference conversion method provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network, and the terminal 102 can obtain the collected three-dimensional data, for example, collect three-dimensional data of scenes such as cities and farmlands through the collection equipment, and return it to the terminal 102 for storage. The terminal 102 can send the three-dimensional data to the server 104 for processing. The server 104 can perform text processing on the three-dimensional data to obtain a text data set corresponding to the three-dimensional data, thereby determining the position information of each unit data in the three-dimensional data. The server 104 performs partition processing on the text data set according to the data volume of the text data set, the processing efficiency of the server 104, and the partitioning strategy corresponding to different three-dimensional data, and divides the text data set into multiple sub-areas. Each sub-area contains part of the data of the text data set. For each sub-area, the server 104 can first determine the original coordinates of each unit data, and perform a plane reference transformation on the plane coordinates in the original coordinates through a pre-established affine transformation model to obtain the transformed plane coordinates. The server 104 can determine the elevation anomaly value of each unit data, and perform an elevation transformation on the elevation coordinates of the original coordinates through the elevation anomaly value to obtain the transformed elevation coordinates. Finally, the server 104 obtains the coordinates of each unit data benchmark after conversion.
[0049] The data storage system can store data that the server 104 needs to process. The data storage system can be integrated on the server 104, or placed on the cloud or other network servers. Among them, the terminal 102 can be, but is not limited to, various personal computers, laptops, smart phones and tablet computers. The terminal 102 can also be a three-dimensional data acquisition device, such as a topographic instrument, a level, a laser rangefinder, a digital camera, a scanner, etc. The server 104 can be implemented as an independent server or a server cluster consisting of multiple servers.
[0050] In an exemplary embodiment, Figure 2 As shown, a three-dimensional data benchmark conversion method is provided, which is applied to Figure 1 The server 104 in the example is used as an example to illustrate the method, which includes the following steps S202 to S210. Among them:
[0051] Step S202: Perform text processing on the three-dimensional data to obtain a text data set corresponding to the three-dimensional data.
[0052] The text dataset is used to represent the location information of each unit data in the three-dimensional data in structured text; the unit data includes pixel or point data. The data type of the three-dimensional data can be digital elevation model DEM (Digital Elevation Model) data, digital surface model DSM (Digital Surface Model) data or laser scanning LAS (Laser Scanning Data) data. For DEM data and DSM data, the unit data of this data type is pixel, and for LAS data, the unit data of this data type is point data.
[0053] Specifically, the server can parse the three-dimensional data according to the parsing strategies of different types of three-dimensional data, and read the basic information and position information of each unit data in the three-dimensional data. The basic information may include the row and column information of the unit data, the size of the unit data, and the data volume of the three-dimensional data. The position information is used to indicate the coordinates of each unit data in the three-dimensional data. In addition, different types of three-dimensional data may also include additional data specific to the type of three-dimensional data. For example, the variable-length records and extended variable-length records in LAS data may include additional data, while the DEM data and DSM data may include the position information corresponding to the lower left corner pixel.
[0054] Step S204 , partitioning the text data set into multiple sub-areas according to the data volume of the text data set, the processing efficiency of the computing device, and the partitioning strategy corresponding to each three-dimensional data.
[0055] The data volume is determined based on the pixel size or point data volume of the three-dimensional data; the processing efficiency is determined based on the timeliness value of the conversion task, the number of cores of the computing device, and the point-by-point processing speed; the three-dimensional data includes at least one of the digital elevation model DEM data, the digital surface model DSM data, and the laser scanning LAS data. The pixel size is inversely proportional to the data volume. The larger the pixel size, the larger the geographical area that can be represented by each pixel, and a smaller number of pixels can be used as the data volume. The point data volume is directly proportional to the data volume.
[0056] Specifically, there is a relationship of dynamic balance between the data volume of the text data set and the processing efficiency of the computing device. If the processing efficiency is higher, then when the text data set is partitioned, the data volume of each partition can be increased. If the processing efficiency is lower, then when the text data set is partitioned, the number of partitions can be increased, and the data volume of each partition can be reduced. The server determines the number of partitions and the data volume of each partition according to the data volume of the text data set and the relationship between the processing efficiency of the computing device. For different types of three-dimensional data, the server can adopt different partitioning strategies to split the text data set corresponding to the three-dimensional data, and obtain multiple sub-areas corresponding to the partition data volume and the number of partitions. In an example, a parallel partitioning method can be adopted for DEM data and DSM data, and a row and column random partitioning method can be adopted for LAS data.
[0057] Step S206 , for each sub-region, determining the original coordinates of each unit data in the sub-region, and performing a plane reference transformation on the plane coordinates in the original coordinates according to an affine transformation model to obtain the transformed plane coordinates of each unit data in the sub-region.
[0058] Among them, the affine transformation model is obtained by solving the polynomial model determined by the grid points through the least squares method. The polynomial model can be used to establish the transformation relationship between the coordinates of different plane references. The same grid points under different plane references can determine the plane coordinates corresponding to the unit data in the grid points through the transformation relationship.
[0059] Specifically, the server can solve the established polynomial model according to multiple sets of three-dimensional data of different plane references to obtain an affine transformation model. The server can input the original coordinates of multiple unit data in the sub-area into the affine transformation model to obtain the plane coordinates after the reference transformation, thereby completing the transformation of the two-dimensional plane coordinates. The server can transform the plane coordinates of all unit data in the sub-area and the plane coordinates of the unit data in all sub-areas by traversing.
[0060] Step S208, determining the elevation anomaly value of each unit data in the sub-region, and performing elevation conversion on the elevation coordinates of the original coordinates according to the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-region.
[0061] Among them, the elevation anomaly value is determined based on the weight function within the fitting radius and the interpolation function model. The elevation anomaly value is an important concept in the field of surveying and mapping science and technology. It refers to the difference between the quasi-geoid and the reference ellipsoid. Accurately determining the elevation anomaly value to obtain the results of the quasi-geoid refined model is a process of refining the quasi-geoid. This model can be used to achieve high-precision conversion between local elevation or national elevation and geodetic elevation. The weight function refers to the mathematical description of the degree of influence of the data points around the fixed point on the interpolation result during the spatial interpolation process. The weight function can define the importance of each known data point in calculating the value of a target point, and its value is usually related to the distance. When the distance between the target point and the known data point is within the fitting radius, the target point can determine the weight value through the corresponding weight function. The server can determine the elevation anomaly value corresponding to the weight value through the interpolation function model.
[0062] Specifically, the server uses the data points corresponding to each unit data in the sub-area as the data points to be converted. The server can determine the weight value corresponding to each data point to be converted by fitting the weight function within the radius, and determine the elevation anomaly value corresponding to each weight value through the interpolation function model. Based on the elevation anomaly value corresponding to each data point to be converted, the server converts the elevation coordinates in the original coordinates corresponding to each data point to be converted to obtain the elevation coordinates after the conversion of each unit data. The server can convert the elevation coordinates corresponding to the unit data in each sub-area.
[0063] Step S210, determining the converted plane coordinates and the converted elevation coordinates as the converted coordinates of the unit data reference.
[0064] Specifically, for the unit data at the same location, the server combines the plane coordinates after the benchmark transformation and the elevation coordinates after the benchmark transformation corresponding to the unit data to obtain the original coordinates after the benchmark transformation. For example, the plane coordinates after the transformation are (X1, Y1), and the elevation coordinates after the transformation are (Z1), and the combination results in (X1, Y1, Z1).
[0065] In the above-mentioned three-dimensional data benchmark conversion method, the text data set corresponding to the three-dimensional data is obtained by text processing the three-dimensional data, and the text data set is partitioned according to the data volume of the text data set, the processing efficiency of the computing device, and the partitioning strategy of the three-dimensional data to obtain multiple sub-areas. For each sub-area, the benchmark conversion can be performed separately. Since the three-dimensional data can be at least one of the digital elevation model DEM data, the digital surface model DSM data and the laser scanning LAS data, the data volume of the three-dimensional data can be determined by the pixel size or the point data volume. For different types of three-dimensional data, the original coordinates of each unit data in the sub-area can be determined, and the original coordinates are plane benchmark transformed through the affine transformation model to obtain the plane coordinates after the conversion of each unit data; the original coordinates are elevation transformed through the elevation anomaly value to obtain the elevation coordinates after the conversion of each unit data. Finally, the converted plane coordinates and elevation coordinates are merged to obtain the three-dimensional data after the benchmark conversion. By partitioning the three-dimensional data and matching the partition size so that the partition can adapt to the computing power provided by the computing device, the amount of data processed at one time can be reduced, and the calculation efficiency of surveying and mapping geographic information data production can be improved. In addition, the original coordinates are converted through plane reference conversion and elevation conversion to convert the coordinate data of three dimensions respectively, reducing the number of dimensions converted at the same time, which can improve the efficiency of coordinate reference conversion.
[0066] In an exemplary embodiment, the specific implementation process of the step of "processing the three-dimensional data into text to obtain a text data set corresponding to the three-dimensional data" includes:
[0067] When the three-dimensional data is DEM data or DSM data, the three-dimensional data is parsed to obtain a text data set consisting of textual plane coordinates and elevation coordinates.
[0068] The file header of the text dataset contains row and column information, the lower left corner coordinates of the lower left corner pixel, and the pixel size. The row and column information is used to indicate the number of data rows and columns contained in the three-dimensional data.
[0069] Specifically, the server can parse the rasterized pixel data according to the regularized characteristics of the DEM data or DSM data to obtain the text data corresponding to each pixel, such as a text data set composed of plane coordinates (X, Y) and elevation coordinates (Z). The text data set can also be parsed from the file header to obtain the number of rows and columns of the DEM data or DSM data, the lower left corner coordinates of each lower left corner pixel in the DEM data or DSM data, the pixel size corresponding to the DEM data or DSM data, and the value of the pixel without data.
[0070] When the three-dimensional data is LAS data, the public file header of the LAS data is parsed to obtain basic information and metadata; the point data records of the LAS data are read to obtain coordinate information and attribute information; the variable-length records and extended variable-length records of the LAS data are read to obtain additional metadata; the basic information, metadata, coordinate information, attribute information and additional metadata are determined to be a text data set corresponding to the LAS data.
[0071] Specifically, LAS data includes a public file header, point data records, variable-length records, and extended variable-length records. Under different LAS versions, the LAS data is parsed according to the binary storage method corresponding to the LAS data to obtain a text data set in a readable text format. For the public file header, the server can parse to obtain basic information and metadata. For point data records, the server can extract the coordinate information and attribute information of each point. For variable-length records and extended variable-length records, the additional metadata and additional information stored in the record can be read.
[0072] In this embodiment, by parsing different types of three-dimensional data, the three-dimensional data can be converted from image data into a structured text data set, and the coordinate information of each unit data in the three-dimensional data can be quickly obtained to facilitate subsequent improvement of reading and processing efficiency.
[0073] In an exemplary embodiment, the specific implementation process of the step of "partitioning the text data set to obtain a plurality of sub-areas according to the data volume of the text data set, the processing efficiency of the computing device, and the partitioning strategy corresponding to each three-dimensional data" includes:
[0074] The total number of pixels or points in the text data set is determined, and the quotient of the total number of pixels or points in the text data set and the processing efficiency of the computing device is the number of partitions; the text data set is divided according to the partitioning strategy and the number of partitions corresponding to the data type of the three-dimensional data to obtain multiple sub-areas.
[0075] The processing efficiency is the product of the time value of the conversion task, the number of cores of the computing device, and the point-by-point processing speed; the partitioning strategy corresponding to the DEM data and DSM data is the parallel partitioning strategy, and the partitioning strategy corresponding to the LAS data is the row-column random partitioning strategy.
[0076] Specifically, when the three-dimensional data type corresponding to the text data set is DEM data or DSM data, the server obtains the total number of pixels in the text data set. The server obtains the processing efficiency of the computing device used to provide computing power. The server can determine the maximum completion time configured for the benchmark conversion task as the timeliness value of the conversion task, the server can determine the number of cores of the computing device, and the server can determine the conversion efficiency under the pixel-by-pixel or point-by-point processing strategy as the point-by-point processing speed. Based on this, the server determines the product of the timeliness value of the conversion task, the number of cores of the computing device, and the point-by-point processing speed as the processing efficiency. The server determines that the quotient of the total number of pixels and the processing efficiency is the number of partitions, and the number of partitions is the number of sub-areas. When the three-dimensional data corresponding to the text data set is LAS data, the server obtains the total number of points in the text data set, and determines that the quotient of the total number of points and the processing efficiency is the number of partitions.
[0077] After determining the number of partitions, the server can determine the amount of data contained in each sub-region based on the number of partitions and the amount of data in the text dataset. The text dataset is divided according to the division strategy corresponding to the data type of the three-dimensional data and the amount of data in each sub-region. If the data type is DEM data and DSM data, the corresponding division strategy is the parallel division strategy. The server can use each row of the text dataset as a dividing line, and divide the text dataset into a sub-region based on the amount of data in each sub-region, until the number of sub-regions reaches the number of partitions. If the data type is LAS data, the corresponding division strategy is the row and column division strategy. The server can use each row and column of the text dataset as a dividing line, and randomly divide the text dataset into a sub-region based on the amount of data in each sub-region, until the number of sub-regions reaches the number of partitions.
[0078] In this embodiment, the number of partitions can be determined based on the total number of pixels and the total number of points in the text data set, as well as the processing efficiency of the computing device. The text data set can be partitioned according to the division strategy of different data types and the limit on the number of partitions to obtain multiple sub-regions that meet the carrying capacity of the computing device and the requirements of the benchmark conversion task, thereby improving the conversion stability and efficiency of each sub-region after partitioning.
[0079] In an exemplary embodiment, the specific implementation process of the step of "determining the original coordinates of each unit data in the sub-area" includes:
[0080] When the three-dimensional data is DEM data or DSM data, the number of data rows in the sub-area is determined according to the row and column information of the text data set; the lower left corner coordinates of the sub-area are determined based on the number of data rows and the pixel size of the text data set; the center point coordinates of each pixel in the sub-area are determined according to the lower left corner coordinates and the pixel size, and the center point coordinates are determined as the original coordinates.
[0081] Specifically, when the three-dimensional data is DEM data or DSM data, the server can determine the quotient of the total number of rows and the number of partitions according to the total number of rows in the row and column information of the text data set, which is the number of data rows in each sub-region. Usually, the number of data rows in the last sub-region may not reach the number of data rows in other sub-regions. Therefore, the quotient of the total number of rows and the number of partitions can be the number of data rows in other sub-regions except the last sub-region. The number of data rows in the last sub-region is the difference between the total number of rows and the number of data rows except the last sub-region. Based on this, the server can calculate the number of data rows in each sub-region.
[0082] For each sub-region, the server can calculate the product of the number of data rows, the partition identifier corresponding to the sub-region, and the pixel size to obtain the lower left corner coordinates of each sub-region. Since the lower left corner coordinates of adjacent sub-regions can be completely divided by the product of the number of data rows, the partition identifier and the pixel size, there will be no duplicate coordinates between adjacent sub-regions. Since the sub-regions are divided according to rows, the horizontal coordinates of each pixel corresponding to each sub-region are the same. The vertical coordinates of each sub-region can be determined according to the product of the number of data rows, the partition identifier and the pixel size.
[0083] For each pixel in each sub-region, the server can determine the number of rows and columns of each sub-region, and use the pixel size as the coordinate interval between two pixels. The server can use the coordinate of the lower left corner of the sub-region as the reference, and use the coordinate interval required for each pixel to be away from the lower left corner coordinate as additional data, and add the vertical coordinate and horizontal coordinate of the lower left corner coordinate to the corresponding additional data to obtain the center point coordinate corresponding to each pixel. For example, if the coordinate of the lower left corner of the sub-region is (0,0), and the pixel size is 2, if the horizontal distance between the pixel and the coordinate of the lower left corner is two coordinate intervals, and the vertical distance between the pixel and the coordinate of the lower left corner is one coordinate interval, the coordinate of the lower left corner of the pixel can be determined to be (2,4). Since the pixel size is 2, half of the pixel size needs to be taken when determining the coordinate of the center point of the pixel, and added to the coordinate, and the coordinate of the center point of the pixel is (3,5).
[0084] When the three-dimensional data is LAS data, the coordinate information of the LAS data is restored according to the offset coordinates and scaling factors of the LAS data to obtain the original coordinates of each point data, wherein the offset coordinates and scaling factors of each sub-area are the same.
[0085] Specifically, for the coordinate information of each point data in the LAS data, the server can multiply the coordinate value of each dimension in the coordinate information with the scaling factor corresponding to each dimension to obtain the product result of each dimension, and add the product result of each dimension to the offset coordinate of the corresponding dimension to obtain the coordinate value corresponding to each dimension, thereby obtaining the restored original coordinates.
[0086] In this embodiment, by analyzing the number of data rows and pixel size of DEM data and DSM data, the lower left corner coordinates of each sub-region can be determined, and based on the lower left corner coordinates, the original coordinates of each pixel in the sub-region can be determined. By performing readable analysis on the coordinate information such as scaling and offset of LAS data, the original coordinates of each point data in each sub-region are determined, ensuring the efficiency and accuracy of determining the original coordinates.
[0087] In an exemplary embodiment, Figure 3 As shown, the specific implementation process of the step of "performing a plane reference transformation on the plane coordinates in the original coordinates according to the affine transformation model to obtain the plane coordinates after the transformation of each unit data in the sub-area" includes steps S302 to S306. Among them:
[0088] Step S302: determining a polynomial model based on the grid points with the same name between the source coordinate system and the target coordinate system.
[0089] The coefficients of the polynomial model include pixel width, the first rotation parameter, the horizontal coordinate value of the center of the upper left pixel, the second rotation parameter, the negative height of the pixel, and the vertical coordinate value of the center of the upper left pixel.
[0090] Specifically, the server can establish a polynomial model in the entire city area or the range of the data to be processed through the grid points with the same name. In one example, an affine first-order polynomial can be used, and the affine first-order polynomial is as follows:
[0091]
[0092] Among them, (x, y) is the grid data coordinate in the source coordinate system, (X, Y) is the grid data coordinate in the target coordinate system, the affine first-order polynomial contains six unknown parameters, A is the pixel width calculated in map units, B is the first rotation parameter, C is the horizontal coordinate value of the center of the upper left pixel, D is the second rotation parameter, E is the negative height of the pixel calculated in map units, and F is the vertical coordinate value of the center of the upper left pixel.
[0093] Step S304, solving the coefficients of the polynomial model based on the least square method until the sum of square errors of all grid points in the polynomial model is less than a preset value, thereby obtaining an affine transformation model.
[0094] Specifically, the server can solve the coefficients in the polynomial model by the least square method, and optimize with the goal of minimizing the sum of square errors of all grid points. When the number of optimization iterations or the sum of square errors meets a preset condition, the solved polynomial model can be obtained and used as the affine transformation model. The preset condition can be that the number of optimization iterations meets a preset number, or the sum of square errors is less than a preset value.
[0095] Step S306: input the plane coordinates in the original coordinates into the affine transformation model to obtain the transformed plane coordinates.
[0096] Specifically, for each pixel in the sub-area, the server can input the plane coordinates in the original coordinates of the pixel into the affine transformation model. The affine transformation model can transform the plane coordinates from the source coordinate system to the target coordinate system through calculation to obtain the plane coordinates after the reference transformation.
[0097] Optionally, when the three-dimensional data is LAS data, the server can use the polynomial model constructed above to perform benchmark conversion. In addition, since LAS data can also establish a polynomial model based on the connection between the affine transformation model and the four-parameter transformation model. The four-parameter transformation model is used to represent the six unknown parameters in the polynomial model with four parameters. In one example, the original four-parameter transformation model is:
[0098]
[0099] in, and are two translation parameters, is the scale factor, is the rotation parameter. The conversion formulas for each parameter include: , , , , , .
[0100] In this embodiment, by establishing an affine transformation model, the model parameters of the conversion coordinate system can be solved, and the plane coordinates of each pixel or point data can be input into the model to obtain the converted plane coordinates, which can ensure the accuracy and efficiency of the reference transformation.
[0101] In an exemplary embodiment, Figure 4 As shown, the specific implementation process of the step "determining the elevation abnormal value of each pixel in the sub-region" includes steps S402 to S406. Among them:
[0102] Step S402: for each unit data in the sub-area, determine the distance between the to-be-converted data point corresponding to each unit data and the grid data point of the quasi-geoid refined model.
[0103] The grid data points of the quasi-geoid refined model are various known data points obtained through the quasi-geoid refined model.
[0104] Specifically, the server can traverse each unit data in the sub-area, and determine the distance between the to-be-converted data point corresponding to the unit data and the grid data point of the quasi-geoid refined model through the distance calculation formula. For example, the distance can be expressed as r i To express.
[0105] Step S404: Determine the weight function value corresponding to the distance according to the weight function within the fitting radius.
[0106] Specifically, the server can i Whether the size of exceeds the fitting radius, and the ratio relationship with the fitting radius, determine the weight function corresponding to the data point to be converted. i If it exceeds the fitting radius, the weight function is determined to be 0. If it is less than the fitting radius and greater than one-third of the fitting radius, r can be determined. i If it is less than one-third of the fitting radius, r can be determined. i The weight function is as follows:
[0107]
[0108] After determining the weight function, the server can determine the weight function value of the data point to be converted through the weight function and the distance.
[0109] Step S406, inputting the weight function value into the interpolation function model to obtain the elevation anomaly value corresponding to the data point to be converted.
[0110] Specifically, the interpolation function model can be shown as follows:
[0111]
[0112] in, . is the grid data point of the quasi-geoid refined model, that is, the point location of the known elevation anomaly value, is the location of the data point to be converted, is the distance used to calculate the weight function The value of It is an elevation outlier.
[0113] In this embodiment, the Shepard fitting method and the local interpolation model can be used to estimate the data points to be converted, and the elevation anomaly values corresponding to each unit data can be obtained, which can improve the accuracy of the elevation anomaly values.
[0114] In an exemplary embodiment, the specific implementation process of the step of "converting the elevation coordinates of the original coordinates by using the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-area" includes:
[0115] Subtract the elevation coordinate of the original coordinate from the elevation anomaly value to obtain the converted elevation coordinate.
[0116] Specifically, the formula is as follows: In the formula, is the geodetic height, i.e. the elevation coordinate, is the elevation anomaly value. Optionally, the data in the same partition can use the same elevation anomaly value to meet the accuracy requirement, which can further improve the efficiency of the conversion.
[0117] In this embodiment, the converted elevation coordinates are obtained by subtracting the elevation coordinates from the elevation anomaly value, so that the coordinates can be quickly benchmarked and the conversion efficiency can be improved.
[0118] The specific implementation process of the above-mentioned three-dimensional data benchmark conversion method is described in detail below in conjunction with a specific embodiment. The embodiment of the present application applies adaptive partitioning technology to the benchmark conversion of three-dimensional DEM / DSM / LAS data to achieve efficient data processing. Intelligent partitioning can be performed according to characteristics such as the pixel size or point data volume of the data, and the partition size and number can be automatically matched, greatly improving the production and calculation efficiency of surveying and mapping geographic information data. The embodiment of the present application adopts a three-dimensional integrated conversion technology of data plane and elevation information, performs benchmark conversion on each three-dimensional sub-area in parallel, uses a high-precision quasi-geoid model, and adopts an improved local approximation model Shepard interpolation algorithm to achieve high-precision conversion of geoid elevation and local elevation, ensuring the accuracy and efficiency of the conversion.
[0119] Among them, DEM (Digital Elevation Model) is a digital geographic data used to describe the topography of the earth's surface. It is an important original data for studying and analyzing topography, watersheds, and identifying land features. It can measure the surface elevation through technical means such as laser radar, satellite remote sensing, and aerial photography, and then generate DEM data. DEM data can reflect local terrain features with a certain resolution. Through DEM, a large amount of surface morphological information can be extracted, which can be used to draw contour lines, slope maps, aspect maps, stereo perspective maps, and stereo landscape maps, and can be used to make orthophotos, stereo terrain models, and map revisions.
[0120] DSM (Digital Surface Model) is a ground elevation model that includes the heights of buildings, bridges, trees, etc. DEM only contains the elevation information of the terrain, and does not include other surface information. DSM is based on DEM and further covers the elevation of other surface information besides the ground.
[0121] LAS (Laser Scanning Data) is a file format used to store laser scanning data, mainly used to store airborne laser radar data. LAS files follow the specifications set by the American Society for Photogrammetry and Remote Sensing. Each laser point cloud data predefines a large number of attributes, including the location, reflection intensity, classification and other information of the point cloud. The LAS file format supports the classification of each point, such as ground points, building points, etc.
[0122] Based on this, DEM / DSM / LAS data is a data set of plane coordinates (X, Y) and elevations (Z) of regular points within a certain range. DEM / DSM is usually stored in raster form, that is, the surface is divided into regular grids, and each grid cell contains an elevation value. DEM is the basic data for describing the ground morphology. DSM is based on DEM and further covers the elevation of other surface information besides the ground. LAS data is an industry standard binary format specifically used to store lidar data. Each laser point cloud data predefines a large amount of location and attribute information.
[0123] The following is a method for high-precision adaptive partitioning and benchmark conversion of DEM / DSM / LAS data, which specifically includes the following steps:
[0124] Step 1: Data analysis and processing.
[0125] (1) DEM / DSM data text. Based on the regularization characteristics of three-dimensional DEM / DSM data, the rasterized data is parsed into a textual data set of plane coordinates (X, Y) and their elevation (Z), forming a regularized standard format, and the elevation value is output in the order of rows and columns of the original data. The file header in the text records the number of columns and rows of data, the coordinates of the lower left corner of the lower left grid pixel, the size of the grid pixel, and the value of the pixel without data.
[0126] (2) LAS binary data decoding. Since its release, the LAS format has undergone many updates and improvements, and there are multiple versions, mainly including the public file header, point data record, variable length record and extended variable length record. The server can parse the LAS data into a normal readable text format according to the binary storage method of different versions of data. First, read and parse the public file header to obtain the basic information and metadata of the file; second, read the point data record to extract the coordinates and attribute information of each point. Finally, process the variable length record and extended variable length record, read and process these records to obtain additional metadata and information.
[0127] Step 2: Adaptive partitioning.
[0128] Intelligent partitioning is performed based on the characteristics of the pixel size / point data volume of the three-dimensional DEM / DSM / LAS data. The number of partition sizes is adaptively determined based on the computer's data processing performance, the empirical efficiency value of the conversion, and the timeliness of the task. To facilitate data fusion, DEM / DSM data uses a parallel partitioning method, that is, the content of each row is kept unchanged and the row content is intercepted; LAS data uses a random partitioning method based on the amount of partition data. It should be noted that the partitioned data should be numbered and output according to the sequential rules. The general algorithm formula for adaptively dividing three-dimensional data into multiple sub-areas is as follows:
[0129]
[0130] in, It is the total number of pixels or points of the original 3D DEM / DSM / LAS data; It is the conversion efficiency under the pixel-by-pixel or point-by-point processing strategy, and the unit is per hour; It is the timeliness of the task, which is based on not exceeding the concurrent performance of the data processing computer. It is suitable for processing tasks that require urgent data. The unit is day. The default value is 1. It is the number of cores in the computer's CPU, which determines the number of physical computing units that execute tasks in parallel; is the number of partitions.
[0131] This adaptive partitioning method can generate partition boundaries with multi-dimensional features, ensuring that each sub-region has a high degree of internal consistency. The data after partition conversion can be seamlessly connected without affecting the characteristics of the original three-dimensional data.
[0132] Step 3: Benchmark conversion.
[0133] (1) Calculation of original coordinates. The process of determining the original coordinates of a single pixel of DEM / DSM data in different partitions is as follows:
[0134] Assume that the number of rows and columns of the original DEM / DSM data is N1 and N2 respectively, the number of partitions is NUM, the coordinates of the lower left corner of the data are (Y, X), the pixel size is CELL, and the coordinates of the lower left corner of the partitioned data are (Y n ,X n ), where n represents the nth partition data, in order from bottom to top. The number of data rows NZ1 in the first NUM-1 partitions is calculated as follows:
[0135]
[0136] The calculation of the number of data rows NZX1 in the NUMth partition is as follows:
[0137]
[0138] The coordinate calculation of the lower left corner of the nth partition data is as follows:
[0139]
[0140] The number of rows and columns of the nth partition data are and respectively, then the coordinates of the center point of the pixel in the nth row and column are:
[0141]
[0142] The calculation method of single point coordinates of LAS data in different partitions is as follows:
[0143] Assume that the offset coordinates of the LAS data are (X0, Y0, Z0) and the scaling factor is (Xscale, Yscale, Zscale).
[0144] The offset and scaling factors of different partitions take the same value; the record value of the LAS data file is (X1, Y1, Z1).
[0145] The restored real point coordinates (X, Y, Z) are as follows:
[0146]
[0147] During the partitioning process, in order to reduce the amount of calculation, the LAS data of different partitions use the same offset and scale factor.
[0148] (2) Three-dimensional integrated datum conversion.
[0149] For a planar datum transformation, the process is as follows:
[0150] DEM / DSM data: Using the grid conversion method, the size of the grid can be fixed or adaptively adjusted according to the four-dimensional range of the DEM / DSM data. The grid is used in conjunction with the source coordinate system and the target coordinate system. Grids of the same size also ensure the uniformity of grid point distribution. The basic principles are as follows:
[0151] a) Establish a polynomial model based on the established grid points with the same name. The order and form of the polynomial depends on the terrain conditions, and usually an affine first-order polynomial can be used, including translation, scaling and rotation.
[0152]
[0153] Where (x, y) is the source grid data coordinate; (X, Y) is the target grid data coordinate; A is the pixel width calculated in map units; B is the rotation parameter. C is the horizontal coordinate value of the center of the upper left pixel. D is the rotation parameter; E is the negative height of the pixel calculated in map units; F is the vertical coordinate value of the center of the upper left pixel.
[0154] b) Solve the polynomial coefficients by the least squares algorithm to minimize the error between the actual coordinates of the grid points within the grid range and the coordinates calculated by the affine polynomial. The six coefficients A, B, C, D, E, and F are solved by minimizing the sum of squares of the errors of all grid points.
[0155] c) Apply the calculated affine transformation model to the entire DEM / DSM data to achieve geo-reference. For each pixel in the DEM / DSM, apply the affine transformation model according to its coordinates to calculate its position in the target coordinate system.
[0156] LAS data: The same affine transformation formula is used to change the plane coordinates of the point data, but the same set of affine transformation parameters is used throughout the city. The affine transformation parameters can be calculated using the control points of the same name that are evenly distributed throughout the city. At the same time, the relationship between the affine transformation model and the four-parameter conversion model is calculated to ensure the consistency of the parameters.
[0157] The original four-parameter transformation model is:
[0158]
[0159] in, and are two translation parameters, is the scale factor, is the rotation parameter. , , , , , .
[0160] For elevation conversion, the process is as follows:
[0161] The conversion of DEM / DSM / LAS data elevation requires the use of high-precision quasi-geoid model results, which are elevation anomaly datasets composed of 2×2 or 2.5×2.5 grids in the entire city. Based on the refined quasi-geoid model results, the improved local approximation model Shepard interpolation algorithm is used to calculate the elevation anomaly values of unknown points (data points to be converted) to achieve the conversion of geodetic elevation and local elevation.
[0162] The Shepard fitting method takes the position of the data to be converted as the center, takes the fitting radius R as the calculation range of the known weight function, calculates the distance between the grid data points of the quasi-geoid refined model and the data points to be converted within the range, and uses different weight functions to calculate the weight according to the distance. In the local interpolation model, R=0.25° is generally selected.
[0163] Among them, the weight function is:
[0164]
[0165] The interpolation function model is:
[0166]
[0167] Where:
[0168]
[0169] is the point location of known elevation anomalies in the quasi-geoid refined model, is the location of the data point to be converted, For distance, Used to calculate the value of the weight function.
[0170] Local high Calculation: .
[0171] In the formula, For the earth is high, It is an elevation outlier.
[0172] DEM / DSM / LAS partition interpolation can greatly improve the efficiency of conversion. Under reasonable partitioning conditions, data in the same partition can meet the accuracy requirements using the same elevation anomaly value, which can further improve the efficiency of conversion.
[0173] Step 4: Merge the converted sub-region data to form a unified 3D data set. Before merging, the results of the partition conversion should be arranged and checked in order, and the complete conversion results will be formed after confirmation. The results of the DEM / DSM / LAS data partition conversion can be seamlessly connected, without affecting the characteristics of the original 3D data, and have strong versatility.
[0174] This embodiment adopts a high-precision adaptive partition benchmark conversion method for DEM / DSM / LAS data, fully utilizes the same point data set attributes of DEM / DSM / LAS, and performs adaptive partition processing and three-dimensional integrated conversion according to the characteristics of different data. In large data volume application scenarios, the computer hardware level is fully utilized, resource utilization and benchmark conversion efficiency are greatly improved, and labor costs are saved.
[0175] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0176] Based on the same inventive concept, the embodiment of the present application also provides a three-dimensional data reference conversion device for implementing the three-dimensional data reference conversion method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations of one or more three-dimensional data reference conversion device embodiments provided below can refer to the limitations of the three-dimensional data reference conversion method above, and will not be repeated here.
[0177] In an exemplary embodiment, Figure 5 As shown, a three-dimensional data reference conversion device 500 is provided, comprising: a data text module 501, a data partitioning module 502, a first conversion module 503, a second conversion module 504 and a coordinate determination module 505, wherein:
[0178] The data text module 501 is used to process the three-dimensional data into text, and obtain a text data set corresponding to the three-dimensional data; the text data set is used to represent the position information of each unit data in the three-dimensional data in structured text; the unit data includes pixel or point data;
[0179] The data partitioning module 502 is used to partition the text data set to obtain multiple sub-areas according to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each three-dimensional data; the data volume is determined based on the pixel size or point data volume of the three-dimensional data; the processing efficiency is determined based on the timeliness value of the conversion task, the core number of the computing device and the point-by-point processing speed; the three-dimensional data includes at least one of digital elevation model DEM data, digital surface model DSM data and laser scanning LAS data;
[0180] The first conversion module 503 is used to determine the original coordinates of each unit data in each sub-region, and perform plane reference conversion on the plane coordinates in the original coordinates according to an affine transformation model to obtain the converted plane coordinates of each unit data in the sub-region; the affine transformation model is obtained by solving a polynomial model determined by grid points by the least square method;
[0181] The second conversion module 504 is used to determine the elevation anomaly value of each unit data in the sub-region, and perform elevation conversion on the elevation coordinates of the original coordinates through the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-region; the elevation anomaly value is determined based on the weight function within the fitting radius and the interpolation function model;
[0182] The coordinate determination module 505 is used to determine the converted plane coordinates and the converted elevation coordinates, which are the converted coordinates of the unit data reference.
[0183] Furthermore, the data text module 501 is specifically used for: when the three-dimensional data is DEM data or DSM data, parsing the three-dimensional data to obtain a text data set consisting of textual plane coordinates and elevation coordinates; the file header of the text data set contains row and column information, the lower left corner coordinates of the lower left corner pixel and the pixel size; when the three-dimensional data is LAS data, parsing the public file header of the LAS data to obtain basic information and metadata; reading the point data records of the LAS data to obtain coordinate information and attribute information; reading the variable length records and extended variable length records of the LAS data to obtain additional metadata; determining that the basic information, metadata, coordinate information, attribute information and additional metadata are the text data set corresponding to the LAS data.
[0184] Furthermore, the data partitioning module 502 is specifically used to: determine the total number of pixels or points in the text data set, and the quotient of the total number of pixels or points and the processing efficiency of the computing device is the number of partitions; the processing efficiency is the product of the time value of the conversion task, the number of cores of the computing device and the point-by-point processing speed; divide the text data set according to the partitioning strategy and the number of partitions corresponding to the data type of the three-dimensional data to obtain multiple sub-areas; the partitioning strategy corresponding to the DEM data and the DSM data is a parallel partitioning strategy, and the partitioning strategy corresponding to the LAS data is a random row and column partitioning strategy.
[0185] Furthermore, the first conversion module 503 is specifically used to: when the three-dimensional data is DEM data or DSM data, determine the number of data rows in the sub-area according to the row and column information of the text data set; determine the lower left corner coordinates of the sub-area based on the number of data rows and the pixel size of the text data set; determine the center point coordinates of each pixel in the sub-area according to the lower left corner coordinates and the pixel size, and determine the center point coordinates as the original coordinates; when the three-dimensional data is LAS data, restore the coordinate information of the LAS data according to the offset coordinates and scaling factor of the LAS data to obtain the original coordinates of each point data; the offset coordinates and scaling factors of each sub-area are the same.
[0186] Furthermore, the first conversion module 503 is specifically used to: determine a polynomial model based on the same-name grid points between the source coordinate system and the target coordinate system; the coefficients of the polynomial model include pixel width, a first rotation parameter, a horizontal coordinate value of the center of the upper left pixel, a second rotation parameter, a negative pixel height, and a vertical coordinate value of the center of the upper left pixel; solve the coefficients of the polynomial model based on the least squares method until the sum of square errors of all grid points in the polynomial model is less than a preset value to obtain an affine transformation model; input the plane coordinates in the original coordinates into the affine transformation model to obtain the converted plane coordinates.
[0187] Furthermore, the second conversion module 504 is specifically used to: determine, for each unit data in the sub-area, the distance between the data point to be converted corresponding to each unit data and the grid data point of the quasi-geoid refined model; determine the weight function value corresponding to the distance based on the weight function within the fitting radius; input the weight function value into the interpolation function model to obtain the elevation anomaly value corresponding to the data point to be converted.
[0188] Furthermore, the second conversion module 504 is further specifically used to: subtract the elevation coordinate of the original coordinate from the elevation anomaly value to obtain the converted elevation coordinate.
[0189] Each module in the above three-dimensional data reference conversion device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.
[0190] In an exemplary embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as shown in FIG. Figure 6 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store three-dimensional data or textualized text data sets. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a three-dimensional data benchmark conversion method is implemented.
[0191] Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0192] In an exemplary embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.
[0193] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0194] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0195] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0196] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0197] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0198] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A three-dimensional data benchmark conversion method, characterized in that: The method comprises: Performing text processing on the three-dimensional data to obtain a text data set corresponding to the three-dimensional data; the text data set is used to represent the position information of each unit data in the three-dimensional data in structured text; the unit data includes pixel or point data; According to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each of the three-dimensional data, the text data set is partitioned to obtain a plurality of sub-areas; the data volume is determined based on the pixel size or point data volume of the three-dimensional data; the processing efficiency is determined based on the timeliness value of the conversion task, the number of cores of the computing device and the point-by-point processing speed; the three-dimensional data includes at least one of digital elevation model DEM data, digital surface model DSM data and laser scanning LAS data; For each sub-region, the original coordinates of each unit data in the sub-region are determined, and the plane coordinates in the original coordinates are subjected to plane reference transformation according to an affine transformation model to obtain the plane coordinates after the transformation of each unit data in the sub-region; the affine transformation model is obtained by solving a polynomial model determined by grid points by the least square method; Determine the elevation anomaly value of each unit data in the sub-area, and perform elevation conversion on the elevation coordinates of the original coordinates by using the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-area; the elevation anomaly value is determined based on a weight function within a fitting radius and an interpolation function model; The converted plane coordinates and the converted elevation coordinates are determined as the converted coordinates of the unit data reference.
2. The method according to claim 1, characterized in that The text processing of the three-dimensional data to obtain a text data set corresponding to the three-dimensional data includes: When the three-dimensional data is DEM data or DSM data, the three-dimensional data is parsed to obtain a text data set consisting of textual plane coordinates and elevation coordinates; the file header of the text data set includes row and column information, the lower left corner coordinates of the lower left corner pixel, and the pixel size; When the three-dimensional data is LAS data, the public file header of the LAS data is parsed to obtain basic information and metadata; the point data record of the LAS data is read to obtain coordinate information and attribute information; the variable-length record and extended variable-length record of the LAS data are read to obtain additional metadata; and the basic information, the metadata, the coordinate information, the attribute information and the additional metadata are determined to be a text data set corresponding to the LAS data.
3. The method according to claim 1, characterized in that The text data set is partitioned according to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each of the three-dimensional data to obtain a plurality of sub-areas, including: Determine the total number of pixels or points in the text data set, and the quotient of the total number of pixels or points and the processing efficiency of the computing device is the number of partitions; the processing efficiency is the product of the time value of the conversion task, the number of cores of the computing device, and the point-by-point processing speed; According to the division strategy corresponding to the data type of the three-dimensional data and the number of partitions, the text data set is divided to obtain multiple sub-areas; the division strategy corresponding to the DEM data and DSM data is a parallel division strategy, and the division strategy corresponding to the LAS data is a row and column random division strategy.
4. The method according to claim 1, characterized in that: The determining the original coordinates of each unit data in the sub-area includes: In the case where the three-dimensional data is DEM data or DSM data, the number of data rows of the sub-region is determined according to the row and column information of the text data set; the lower left corner coordinates of the sub-region are determined based on the number of data rows and the pixel size of the text data set; the center point coordinates of each pixel in the sub-region are determined according to the lower left corner coordinates and the pixel size, and the center point coordinates are determined as the original coordinates; When the three-dimensional data is LAS data, the coordinate information of the LAS data is restored according to the offset coordinates and scaling factors of the LAS data to obtain the original coordinates of each point data; the offset coordinates and scaling factors of each sub-area are the same.
5. The method according to claim 1, characterized in that The performing plane reference transformation on the plane coordinates in the original coordinates according to the affine transformation model to obtain the plane coordinates after the transformation of each unit data in the sub-area includes: Based on the grid points with the same name between the source coordinate system and the target coordinate system, a polynomial model is determined; the coefficients of the polynomial model include a pixel width, a first rotation parameter, a horizontal coordinate value of the center of the upper left pixel, a second rotation parameter, a negative pixel height, and a vertical coordinate value of the center of the upper left pixel; Solving the coefficients of the polynomial model based on the least squares method until the sum of square errors of all grid points in the polynomial model is less than a preset value, thereby obtaining an affine transformation model; The plane coordinates in the original coordinates are input into the affine transformation model to obtain the transformed plane coordinates.
6. The method according to claim 1, characterized in that The step of determining the elevation abnormal value of each pixel in the sub-region comprises: For each unit data in the sub-area, determining the distance between the to-be-converted data point corresponding to each unit data and the grid data point of the quasi-geoid refined model; Determining a weight function value corresponding to the distance according to the weight function within the fitting radius; The weight function value is input into the interpolation function model to obtain the elevation anomaly value corresponding to the data point to be converted.
7. The method according to claim 6, characterized in that The step of performing elevation conversion on the elevation coordinates of the original coordinates by using the elevation anomaly value to obtain the elevation coordinates of each unit data in the sub-area after conversion includes: The elevation coordinate of the original coordinate is subtracted from the elevation anomaly value to obtain the converted elevation coordinate.
8. A three-dimensional data reference conversion device, characterized in that: The device comprises: A data text module, used for text processing of the three-dimensional data to obtain a text data set corresponding to the three-dimensional data; the text data set is used to represent the position information of each unit data in the three-dimensional data in structured text; the unit data includes pixel or point data; A data partitioning module, for partitioning the text data set to obtain a plurality of sub-areas according to the data volume of the text data set, the processing efficiency of the computing device and the partitioning strategy corresponding to each of the three-dimensional data; the data volume is determined based on the pixel size or point data volume of the three-dimensional data; the processing efficiency is determined based on the timeliness value of the conversion task, the number of cores of the computing device and the point-by-point processing speed; the three-dimensional data includes at least one of digital elevation model DEM data, digital surface model DSM data and laser scanning LAS data; A first conversion module is used to determine, for each sub-region, the original coordinates of each unit data in the sub-region, and perform a plane reference conversion on the plane coordinates in the original coordinates according to an affine transformation model to obtain the converted plane coordinates of each unit data in the sub-region; the affine transformation model is obtained by solving a polynomial model determined by grid points by a least square method; A second conversion module is used to determine the elevation anomaly value of each unit data in the sub-area, and perform elevation conversion on the elevation coordinates of the original coordinates through the elevation anomaly value to obtain the converted elevation coordinates of each unit data in the sub-area; the elevation anomaly value is determined based on a weight function within a fitting radius and an interpolation function model; The coordinate determination module is used to determine the converted plane coordinates and the converted elevation coordinates, which are the coordinates converted from the unit data reference.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Region quasi-geoid refining method based on CQG2000
CN101493324A
Point set affine transformation algorithm in visual positioning
CN110428457A
Find position-based photo control point elevation precision cloud computing conversion method
CN111611540A
City-level mass point cloud coordinate conversion method based on heterogeneous parallel computing
CN113190515A
Image processing device and method
WO2019198399A1