Three-dimensional map model generation method and device, terminal equipment and storage medium
By performing feature extraction and the use of generative adversarial network models on two-dimensional vector diagrams, the problem of large data demand and high complexity in the generation of three-dimensional map models is solved, and efficient and low-cost three-dimensional map model generation is achieved.
Patent Information
- Application Number
- CN202411622207.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-13
- Publication Date
- 2025-04-04
AI Technical Summary
In the prior art, when using a three-dimensional modeling engine to generate a three-dimensional map model, the data demand is large, the modeling is complex and the cost is high.
By obtaining the two-dimensional vector diagram of the target area, extracting its geometric features and attribute features, generating area feature data, and inputting it into a preset generative adversarial network model, generating three-dimensional map model data, and finally generating a three-dimensional map model through rendering.
It reduces the data demand for 3D modeling, reduces the complexity and cost of modeling, and improves the generation accuracy and stability of 3D map models.
Smart Images

Figure CN119762689A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of computer application technology, and in particular, relates to a three-dimensional map model generation method, apparatus, terminal equipment and computer-readable storage medium. Background Art
[0002] Two-dimensional vector maps express geographic information with simple graphics and symbols, but they have obvious deficiencies in terms of terrain representation, environmental perception and visual information, user experience and interactive design. Three-dimensional map models can present geographic environment, buildings and terrain features in a highly realistic way, thereby improving user experience.
[0003] In related technologies, specific sensors or cameras can be selected for initial data collection, and then a 3D modeling engine can be used to display and calculate the 3D model, and finally the calculation can be accelerated on appropriate hardware devices. However, this modeling technology requires a large amount of data, the process is cumbersome, and the modeling cost is high, which leads to the problem of large data demand, complex modeling and high cost in the process of building a 3D map model. Summary of the invention
[0004] The purpose of this application is to provide a three-dimensional map model generation method, device, terminal device and computer-readable storage medium, which can solve the problems in related technologies of using a three-dimensional modeling engine to display and calculate three-dimensional models, resulting in large data requirements, complex modeling and high costs.
[0005] In a first aspect, an embodiment of the present application provides a method for generating a three-dimensional map model, including: obtaining a two-dimensional vector map of a target area; processing the two-dimensional vector map to generate regional feature data corresponding to the target area; inputting the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data; rendering the three-dimensional map model data to generate a three-dimensional map model.
[0006] In a possible implementation of the first aspect, the preset generative adversarial network model includes a local generative adversarial network model and a global generative adversarial network model, and the step of inputting the regional feature data into the preset generative adversarial network model to generate the three-dimensional map model data includes:
[0007] Input the regional feature data into the global generative adversarial network model to generate global macro model data;
[0008] Input the regional feature data into the local generative adversarial network model to generate local detail model data;
[0009] The global macro model data is integrated with the local detail model data to generate three-dimensional map model data.
[0010] Optionally, in another possible implementation manner of the first aspect, the processing of the two-dimensional vector map to generate regional feature data corresponding to the target area includes:
[0011] Extract geometric features from two-dimensional vector graphics to generate geometric shape information;
[0012] Extract attribute features from two-dimensional vector graphs to generate attribute information;
[0013] Encode geometric shape information and attribute information to generate regional feature data.
[0014] Optionally, in another possible implementation manner of the first aspect, before encoding the geometric shape information and the attribute information to generate the regional feature data, the method further includes:
[0015] Obtain condition information corresponding to the target area;
[0016] The above encoding of geometric shape information and attribute information generates regional feature data, including:
[0017] Encode geometric shape information, attribute information and condition information to generate regional feature data.
[0018] Optionally, in another possible implementation manner of the first aspect, before rendering the three-dimensional map model data to generate the three-dimensional map model, the method further includes:
[0019] The 3D map model data is stored in the server and sent to the renderer.
[0020] Optionally, in another possible implementation of the first aspect, the rendering of the three-dimensional map model data to generate the three-dimensional map model includes:
[0021] Obtain basic rendering data corresponding to the 3D map model data;
[0022] Load the visualization resources corresponding to the 3D map model data;
[0023] Obtain business applications corresponding to 3D map model data;
[0024] The 3D map model data is rendered according to the basic rendering data, visualization resources and business applications to generate a 3D map model.
[0025] Optionally, in another possible implementation of the first aspect, before inputting the regional feature data into a preset generative adversarial network model to generate the three-dimensional map model data, the method further includes:
[0026] Obtaining a training data set, wherein the training data set includes model data samples and real model feature graphs;
[0027] The model data samples and random noise vectors are input into the generator of the initial generative adversarial network model to generate the output corresponding to the current generator. The output corresponding to the current generator and the real model feature map are input into the discriminator of the initial generative adversarial network model. The initial generative adversarial network model is iteratively trained to generate a preset generative adversarial network model.
[0028] In the second aspect, the present application also provides a three-dimensional map model generation device, including: a first acquisition module, used to acquire a two-dimensional vector map of the target area; a first generation module, used to process the two-dimensional vector map to generate regional feature data corresponding to the target area; a second generation module, used to input the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data; a third generation module, used to render the three-dimensional map model data to generate a three-dimensional map model.
[0029] In a possible implementation of the second aspect, the preset generative adversarial network model includes a local generative adversarial network model and a global generative adversarial network model; accordingly, the second generation module includes:
[0030] A first generating unit is used to input the regional feature data into the global generative adversarial network model to generate global macro model data;
[0031] A second generating unit is used to input the regional feature data into the local generative adversarial network model to generate local detail model data;
[0032] The third generating unit is used to fuse the global macro model data with the local detail model data to generate three-dimensional map model data.
[0033] Optionally, in another possible implementation manner of the second aspect, the first generating module includes:
[0034] A fourth generating unit is used to extract geometric features from the two-dimensional vector image to generate geometric shape information;
[0035] A fifth generating unit is used to extract attribute features from the two-dimensional vector map and generate attribute information;
[0036] The sixth generating unit is used to encode the geometric shape information and the attribute information to generate the regional feature data.
[0037] Optionally, in another possible implementation manner of the second aspect, the first generating module further includes:
[0038] A first acquisition unit, used to acquire condition information corresponding to the target area;
[0039] The sixth generation unit is specifically used for:
[0040] Encode geometric shape information, attribute information and condition information to generate regional feature data.
[0041] Optionally, in another possible implementation of the second aspect, the three-dimensional map model generating device further includes:
[0042] The storage and sending module is used to store the three-dimensional map model data in the server and send the three-dimensional map model data to the renderer.
[0043] Optionally, in another possible implementation manner of the second aspect, the third generating module includes:
[0044] A second acquisition unit is used to acquire basic rendering data corresponding to the three-dimensional map model data;
[0045] A loading unit, used for loading visualization resources corresponding to the three-dimensional map model data;
[0046] A third acquisition unit is used to acquire the business application corresponding to the three-dimensional map model data;
[0047] The seventh generation unit is used to render the three-dimensional map model data according to the basic rendering data, visualization resources and business applications to generate a three-dimensional map model.
[0048] Optionally, in another possible implementation of the second aspect, the three-dimensional map model generating device further includes:
[0049] A second acquisition module is used to acquire a training data set, wherein the training data set includes a model data sample and a real model feature map;
[0050] The training module is used to input the model data samples and the random noise vector into the generator of the initial generative adversarial network model, generate the output corresponding to the current generator, input the output corresponding to the current generator and the real model feature map into the discriminator of the initial generative adversarial network model, iteratively train the initial generative adversarial network model, and generate a preset generative adversarial network model.
[0051] In a third aspect, the present application further provides a terminal device. The terminal device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, a method for implementing any one of the implementation modes of the first aspect is implemented.
[0052] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method of any one of the implementation modes of the first aspect is implemented.
[0053] In a fifth aspect, the present application further provides a computer program product, which, when executed on an electronic device, enables the electronic device to execute any one of the methods of the first aspect.
[0054] Compared with the prior art, the embodiments of the present application have the following beneficial effects: by processing a two-dimensional vector map to generate feature data, based on the feature data, a preset generative adversarial network model is used to generate three-dimensional map model data, and the three-dimensional map model data is rendered to generate a three-dimensional map model, thereby reducing the data demand for three-dimensional modeling, reducing the complexity of three-dimensional modeling, and reducing the modeling cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be 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 any creative work.
[0056] Figure 1 It is a flowchart of a method for generating a three-dimensional map model provided in an embodiment of the present application;
[0057] Figure 2 It is a flowchart of model training provided by an embodiment of the present application;
[0058] Figure 3 This is a schematic diagram of a three-dimensional model map rendering process provided by an embodiment of the present application;
[0059] Figure 4 is a flowchart of a method for generating a three-dimensional map model provided in another embodiment of the present application;
[0060] Figure 5 is a schematic diagram of the structure of a three-dimensional map model generating device provided in an embodiment of the present application;
[0061] Figure 6 It is a structural diagram of the terminal device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0062] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0063] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0064] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0065] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0066] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0067] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0068] The following describes in detail the three-dimensional map model generation method, apparatus, terminal device, storage medium and computer program provided in the present application with reference to the accompanying drawings.
[0069] Figure 1 A schematic flow chart of a three-dimensional map model generation method provided in an embodiment of the present application is shown.
[0070] Step 101, obtaining a two-dimensional vector map of a target area.
[0071] It should be noted that the 3D map model generation method of the embodiment of the present application can be executed by the 3D map model generation device of the embodiment of the present application. The 3D map model generation device of the embodiment of the present application can be configured in any terminal device to execute the 3D map model generation method of the embodiment of the present application.
[0072] In a possible implementation, the target area may be an area determined according to actual needs and for which a three-dimensional map model needs to be established, and the two-dimensional vector map may be a two-dimensional map formed by a series of lines connected by points, and may have attributes such as color, shape, outline, size, etc. The two-dimensional vector map of the target area may be obtained by user input upload or the like.
[0073] It should be noted that, in actual use, the specific data included in the two-dimensional vector diagram can be determined according to actual usage requirements and application scenarios, and the embodiments of the present application do not limit this.
[0074] Step 102, processing the two-dimensional vector map to generate regional feature data corresponding to the target area.
[0075] As a possible implementation method, the two-dimensional vector map can be processed, for example, feature extraction can be performed, and the extracted feature data can be processed to generate regional feature data corresponding to the two-dimensional vector map of the target area. The format of the regional feature data can be a vector, a matrix or a tensor, etc.
[0076] Furthermore, the geometric features and attribute features of the two-dimensional vector map can be extracted to improve the accuracy of the regional feature data, thereby improving the accuracy and stability of the three-dimensional map model generation. That is, in a possible implementation of the embodiment of the present application, the above step 102 may include:
[0077] Extract geometric features from two-dimensional vector graphics to generate geometric shape information;
[0078] Extract attribute features from two-dimensional vector graphs to generate attribute information;
[0079] Encode geometric shape information and attribute information to generate regional feature data.
[0080] In one possible implementation, the geometric features of each geographic element in the two-dimensional vector map can be extracted to generate the geometric shape information of the two-dimensional vector map, and the attribute features of each geographic element in the two-dimensional vector map can be extracted to generate the attribute information of the two-dimensional vector map. The geometric shape information and the attribute information are processed to generate regional feature data whose data format meets the format requirements of the machine learning algorithm.
[0081] For example, geographic elements may include buildings, roads, water bodies, etc., and geometric shape information may include coordinates of points, lines, and surfaces, etc. When geographic elements include buildings, attribute information may be the height and type of the building, etc. When geographic elements include roads, attribute information may be the width and grade of the road, etc. The geometric shape information and attribute information are encoded, and the generated regional feature data may be in the form of vectors, matrices, tensors, etc.
[0082] Furthermore, conditional information can be introduced to further improve the accuracy of regional feature data through conditional information, thereby further improving the accuracy and stability of the generated three-dimensional map model, making the generated result more controllable and semantically coherent. That is, in a possible implementation of the embodiment of the present application, the above encoding of geometric shape information and attribute information before generating regional feature data also includes:
[0083] Obtain condition information corresponding to the target area;
[0084] Encode geometric shape information and attribute information to generate regional feature data, including:
[0085] Encode geometric shape information, attribute information and condition information to generate regional feature data.
[0086] In a possible implementation, condition information of the target area can be obtained before generating the regional characteristic data, for example, by obtaining user input or extracting the two-dimensional vector map, and the condition information can be a category label of the two-dimensional vector map (for example, city category, natural landscape category, etc.), text description, etc. The condition information can be encoded together with the geometric shape information and attribute information to generate the regional characteristic data.
[0087] It should be noted that the contents of the above-mentioned geographic elements, geometric shape information, attribute information and condition information are only exemplary. In actual use, they can be determined according to actual usage requirements and application scenarios, and the embodiments of the present application do not limit this.
[0088] Step 103: input the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data.
[0089] In one possible implementation, the preset generative adversarial network model may be pre-trained and may include a generator, which may include a three-dimensional convolution kernel. After the regional feature data is input into the preset generative adversarial network model, the three-dimensional map model data may be generated through the generator.
[0090] Furthermore, the preset generative adversarial network model may include a local generative adversarial network model and a global generative adversarial network model. For different geographical elements, the global generative adversarial network model is used to generate global macro information, and the local generative adversarial network model is used to learn local detail information. The final three-dimensional map model data is obtained by fusing the global generation results and the local generation results, thereby improving the comprehensiveness of model generation. That is, in a possible implementation of the embodiment of the present application, the preset generative adversarial network model includes a local generative adversarial network model and a global generative adversarial network model, and the above step 103 may include:
[0091] Input the regional feature data into the global generative adversarial network model to generate global macro model data;
[0092] Input the regional feature data into the local generative adversarial network model to generate local detail model data;
[0093] The global macro model data is integrated with the local detail model data to generate three-dimensional map model data.
[0094] In a possible implementation, the regional feature data can be input into the global generative adversarial network model to generate the overall structure or background, including the overall shape of the entire object, large-scale structural features, etc., which can be composed of a convolutional neural network, and can generate global macro model data represented by a three-dimensional voxel grid or point cloud data, etc. The regional feature data can be input into the local generative adversarial network model, and the local generative adversarial network model can generate local details or local features, including local shapes, textures, subtle structures, etc. The goal is to generate realistic local fragments, so that the overall generated three-dimensional map model is more realistic and detailed. The local generative adversarial network model can be composed of a convolutional neural network or its variants, and can generate local detail model data represented by a three-dimensional voxel grid or point cloud data, etc. The global macro model data can be fused with the local detail model data to generate three-dimensional map model data.
[0095] Furthermore, the preset generative adversarial network model can be trained in advance to improve the accuracy of the model, thereby improving the accuracy of the generated three-dimensional map model. That is, in a possible implementation of the embodiment of the present application, before the above step 103, it can also include:
[0096] Obtaining a training data set, wherein the training data set includes model data samples and real model feature graphs;
[0097] The model data samples and random noise vectors are input into the generator of the initial generative adversarial network model to generate the output corresponding to the current generator. The output corresponding to the current generator and the real model feature map are input into the discriminator of the initial generative adversarial network model. The initial generative adversarial network model is iteratively trained to generate a preset generative adversarial network model.
[0098] In a possible implementation, a training data set may be obtained, and high-precision three-dimensional model data may be used as samples to provide rich geographic information and map features, and present various geographic elements, such as mountains, rivers, buildings, airports, etc. The training data set may include model data samples and real model feature maps. The model data samples are data extracted from the three-dimensional model, and may include category labels, text descriptions, etc. The model may generate corresponding three-dimensional map model data based on the data. The real model feature map is the real three-dimensional map model data converted from the three-dimensional model.
[0099] In a possible implementation, the initial generative adversarial network model includes a generator and a discriminator. The model data sample and the random noise vector can be input into the generator of the initial generative adversarial network model, such as Figure 2 As shown, the generator generates corresponding three-dimensional map model data according to the input data, and inputs it into the discriminator. The discriminator is composed of a convolutional neural network, including a three-dimensional convolution kernel, and can receive the three-dimensional map model data, model data samples and real model feature maps generated by the generator. According to the real model feature map, the authenticity of the three-dimensional map model data can be judged, and whether the three-dimensional map model data satisfies the constraints of the model data samples can be judged, thereby generating parameters for updating the generator, updating the generator, and iteratively updating the initial generative adversarial network model. The objective function of model training can be expressed as:
[0100]
[0101] Among them, P data (x) is the real data distribution, G is the generated image, P Z (z) is the input noise distribution, D(x|y) is the probability of judging that the true model matches the model data sample, and D(G(z|y)) is the probability of judging that the generated model matches the model data sample.
[0102] As a possible implementation method of this application, the model can be trained through the NVIDIA RTX3090ti experimental platform, based on Python programming and Pytorch deep learning framework.
[0103] Step 104: Render the three-dimensional map model data to generate a three-dimensional map model.
[0104] As a possible implementation of the present application, a three-dimensional map model corresponding to the target area may be rendered and generated based on the three-dimensional map model data.
[0105] Furthermore, the efficiency and accuracy of rendering can be improved by obtaining pre-set rendering data, resources and application classifications, thereby further improving the efficiency and accuracy of generating a three-dimensional map model. That is, in a possible implementation of the embodiment of the present application, the above step 104 may include:
[0106] Obtain basic rendering data corresponding to the 3D map model data;
[0107] Load the visualization resources corresponding to the 3D map model data;
[0108] Obtain business applications corresponding to 3D map model data;
[0109] The 3D map model data is rendered according to the basic rendering data, visualization resources and business applications to generate a 3D map model.
[0110] In a possible implementation of the present application, Figure 3 As shown, the basic rendering data corresponding to the 3D map model data can be obtained, such as basic image data, terrain elevation data, vegetation coverage data, vector data, 3D model data, etc.; the visualization resources corresponding to the 3D map model data can be loaded, such as global terrain simulation system, orthophoto loading, next-generation rendering effects, vector data loading, meteorological data 3D visualization resources, etc.; the business applications corresponding to the 3D map model data can be obtained, such as natural geographical environment simulation, real celestial body operation simulation, site building model construction, etc. According to the basic rendering data, visualization resources and business applications obtained or loaded, the 3D map model data can be rendered to generate a 3D map model.
[0111] Furthermore, the three-dimensional map model data may be stored. That is, in a possible implementation of the embodiment of the present application, before the above step 104, the following may also be included:
[0112] The 3D map model data is stored in the server and sent to the renderer.
[0113] In one possible implementation, the 3D map model data may be stored in a server database, such as a NoSQL database, Redis, etc., and data communication may be performed via WebSocket to send the 3D map model data to a renderer for rendering.
[0114] As a possible implementation of this application, it can be Figure 4 The process shown in the figure generates a three-dimensional map model of the target area. It can be divided into three parts: acquisition of training data set, training of preset generative adversarial network model and generation of three-dimensional map model of target area. First, the training data set can be obtained, and the model data samples and the real model feature map can be determined according to the real three-dimensional map model to synthesize the training data set. Then, the model is trained with the training data set, including the training of the global generative adversarial network model and the training of the local generative adversarial network model, and a preset generative adversarial network model is generated, which includes a three-dimensional model generative adversarial network algorithm. Finally, the two-dimensional vector map of the target area is preprocessed to generate regional feature data, and the regional feature data is input into the preset generative adversarial network model to generate three-dimensional map model data, and the three-dimensional map model data is stored in the server, and rendered to generate a three-dimensional map model.
[0115] The three-dimensional map model generation method provided in the embodiment of the present application generates regional feature data by processing a two-dimensional vector map, generates three-dimensional map model data based on the regional feature data by using a preset generative adversarial network model, and renders the three-dimensional map model data, thereby generating a three-dimensional map model, reducing the data demand for three-dimensional modeling, reducing the complexity of three-dimensional modeling, and reducing the modeling cost; by extracting the geometric features and attribute features of the two-dimensional vector map, the accuracy of the regional feature data is improved, thereby improving the accuracy and stability of the three-dimensional map model generation; in addition, for different geographical elements, a global generative adversarial network model is used to generate global macro information, and a local generative adversarial network model is used to learn local detail information, and the final three-dimensional map model data is obtained by fusing the global generation results and the local generation results, thereby improving the comprehensiveness of the model; and by obtaining pre-set rendering data, resources and application classifications, etc., the efficiency and accuracy of rendering are improved, thereby further improving the efficiency and accuracy of the three-dimensional map model generation.
[0116] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0117] Corresponding to the three-dimensional map model generation method of the above embodiment, Figure 5A structural block diagram of a three-dimensional map model generating device provided in an embodiment of the present application is shown. For ease of explanation, only the parts related to the embodiment of the present application are shown.
[0118] Reference Figure 5 , the device 50 comprises:
[0119] A first acquisition module 51 is used to acquire a two-dimensional vector map of a target area;
[0120] A first generating module 52 is used to process the two-dimensional vector graph to generate regional feature data corresponding to the target region;
[0121] The second generation module 53 is used to input the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data;
[0122] The third generating module 54 is used to render the three-dimensional map model data to generate a three-dimensional map model.
[0123] In actual use, the three-dimensional map model generating apparatus provided in the embodiment of the present application can be configured in any terminal device to execute the aforementioned three-dimensional map model generating method.
[0124] The three-dimensional map model generation device provided in the embodiment of the present application generates feature data by processing a two-dimensional vector map, generates three-dimensional map model data based on the feature data using a preset generative adversarial network model, and renders the three-dimensional map model data, thereby generating a three-dimensional map model, reducing the data demand for three-dimensional modeling, reducing the complexity of three-dimensional modeling, and reducing the modeling cost.
[0125] In a possible implementation form of the present application, the preset generative adversarial network model includes a local generative adversarial network model and a global generative adversarial network model; accordingly, the second generation module 53 includes:
[0126] A first generating unit, used for inputting the regional feature data into the global generative adversarial network model to generate global macro model data;
[0127] A second generating unit is used to input the regional feature data into the local generative adversarial network model to generate local detail model data;
[0128] The third generating unit is used to fuse the global macro model data with the local detail model data to generate three-dimensional map model data.
[0129] Furthermore, in another possible implementation form of the present application, the first generating module 52 includes:
[0130] A fourth generating unit is used to extract geometric features from the two-dimensional vector image to generate geometric shape information;
[0131] A fifth generating unit, used for extracting attribute features from the two-dimensional vector map to generate attribute information;
[0132] The sixth generating unit is used to encode the geometric shape information and the attribute information to generate the regional feature data.
[0133] Furthermore, in another possible implementation form of the present application, the first generating module 52 further includes:
[0134] A first acquisition unit, used to acquire condition information corresponding to the target area;
[0135] The sixth generation unit is specifically used for:
[0136] Encode geometric shape information, attribute information and condition information to generate regional feature data.
[0137] Furthermore, in another possible implementation form of the present application, the three-dimensional map model generating device 50 further includes:
[0138] The storage and sending module is used to store the three-dimensional map model data in the server and send the three-dimensional map model data to the renderer.
[0139] Furthermore, in another possible implementation form of the present application, the third generating module 54 includes:
[0140] A second acquisition unit is used to acquire basic rendering data corresponding to the three-dimensional map model data;
[0141] A loading unit, used for loading visualization resources corresponding to the three-dimensional map model data;
[0142] A third acquisition unit is used to acquire the business application corresponding to the three-dimensional map model data;
[0143] The seventh generation unit is used to render the three-dimensional map model data according to the basic rendering data, visualization resources and business applications to generate a three-dimensional map model.
[0144] Furthermore, in another possible implementation form of the present application, the three-dimensional map model generating device 50 further includes:
[0145] A second acquisition module is used to acquire a training data set, wherein the training data set includes a model data sample and a real model feature map;
[0146] The training module is used to input the model data samples and the random noise vector into the generator of the initial generative adversarial network model, generate the output corresponding to the current generator, input the output corresponding to the current generator and the real model feature map into the discriminator of the initial generative adversarial network model, iteratively train the initial generative adversarial network model, and generate a preset generative adversarial network model.
[0147] It should be noted that the information interaction, execution process, etc. between the above-mentioned devices / units are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.
[0148] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0149] In order to implement the above embodiments, the present application also proposes a terminal device.
[0150] Figure 6 A schematic diagram of the structure of a terminal device according to an embodiment of the present application.
[0151] like Figure 6 As shown, the terminal device 200 includes:
[0152] The memory 210 and at least one processor 220, a bus 230 connecting different components (including the memory 210 and the processor 220), the memory 210 stores a computer program, and when the processor 220 executes the program, the three-dimensional map model generation method described in the embodiment of the present application is implemented.
[0153] Bus 230 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, an accelerated graphics port, a processor or a local bus using any of a variety of bus architectures. For example, these architectures include but are not limited to Industry Standard Architecture (ISA) bus, Micro Channel Architecture (MAC) bus, Enhanced ISA bus, Video Electronics Standards Association (VESA) local bus and Peripheral Component Interconnect (PCI) bus.
[0154] The terminal device 200 typically includes a variety of electronic device readable media, which can be any available media that can be accessed by the terminal device 200, including volatile and non-volatile media, removable and non-removable media.
[0155] The memory 210 may also include computer system readable media in the form of volatile memory, such as random access memory (RAM) 240 and / or cache memory 250. The terminal device 200 may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, the storage system 260 may be used to read and write non-removable, non-volatile magnetic media ( Figure 6 not shown, usually called a "hard drive"). Although Figure 6 Not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk"), and an optical disk drive for reading and writing to a removable non-volatile optical disk (e.g., a CD-ROM, DVD-ROM, or other optical medium) may be provided. In these cases, each drive may be connected to bus 230 via one or more data medium interfaces. Memory 210 may include at least one program product having a set (e.g., at least one) of program modules that are configured to perform the functions of the various embodiments of the present application.
[0156] A program / utility 280 having a set (at least one) of program modules 270 may be stored, for example, in the memory 210, such program modules 270 including, but not limited to, an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment. The program modules 270 generally perform the functions and / or methods of the embodiments described herein.
[0157] The terminal device 200 can also communicate with one or more external devices 290 (e.g., keyboard, pointing device, display 291, etc.), and can also communicate with one or more devices that enable users to interact with the terminal device 200, and / or communicate with any device that enables the terminal device 200 to communicate with one or more other computing devices (e.g., network card, modem, etc.). This communication can be carried out through an input / output (I / O) interface 292. In addition, the terminal device 200 can also communicate with one or more networks (e.g., local area network (LAN), wide area network (WAN) and / or public network, such as the Internet) through a network adapter 293. As shown in the figure, the network adapter 293 communicates with other modules of the terminal device 200 through a bus 230. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the terminal device 200, including but not limited to: microcode, device driver, redundant processing unit, external disk drive array, RAID system, tape drive, and data backup storage system, etc.
[0158] The processor 220 executes various functional applications and data processing by running the programs stored in the memory 210 .
[0159] It should be noted that the implementation process and technical principles of the terminal device of this embodiment refer to the aforementioned explanation of the three-dimensional map model generation method of the embodiment of the present application, and will not be repeated here.
[0160] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned method embodiments can be implemented.
[0161] An embodiment of the present application provides a computer program product. When the computer program product runs on a terminal device, the terminal device can implement the steps in the above-mentioned method embodiments when executing the computer program product.
[0162] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the computer program is executed by the processor, the steps of the above-mentioned various method embodiments can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may at least include: any entity or device that can carry the computer program code to the camera / terminal device, recording medium, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.
[0163] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0164] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0165] In the embodiments provided in the present application, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0166] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0167] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A method for generating a three-dimensional map model, characterized in that: include: Get the two-dimensional vector map of the target area; Processing the two-dimensional vector map to generate regional feature data corresponding to the target area; Inputting the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data; The three-dimensional map model data is rendered to generate the three-dimensional map model.
2. The method according to claim 1, characterized in that The preset generative adversarial network model includes a local generative adversarial network model and a global generative adversarial network model, and the inputting of the regional feature data into the preset generative adversarial network model to generate three-dimensional map model data includes: Inputting the regional feature data into the global generative adversarial network model to generate global macro model data; Inputting the regional feature data into the local generative adversarial network model to generate local detail model data; The global macro model data and the local detail model data are merged to generate the three-dimensional map model data.
3. The method according to claim 1, characterized in that The processing of the two-dimensional vector map to generate regional feature data corresponding to the target area includes: Extracting geometric features from the two-dimensional vector image to generate geometric shape information; Extracting attribute features from the two-dimensional vector map to generate attribute information; The geometric shape information and the attribute information are encoded to generate the region feature data.
4. The method according to claim 3, characterized in that Before encoding the geometric shape information and the attribute information to generate the regional feature data, the method further includes: Acquire condition information corresponding to the target area; The step of encoding the geometric shape information and the attribute information to generate the regional feature data includes: The geometric shape information, the attribute information and the condition information are encoded to generate the area feature data.
5. The method according to claim 1, characterized in that Before rendering the three-dimensional map model data to generate the three-dimensional map model, the method further includes: The three-dimensional map model data is stored in a server, and the three-dimensional map model data is sent to a renderer.
6. The method according to claim 1, characterized in that The rendering of the three-dimensional map model data to generate the three-dimensional map model includes: Obtaining basic rendering data corresponding to the three-dimensional map model data; Loading visualization resources corresponding to the three-dimensional map model data; Obtaining the business application corresponding to the three-dimensional map model data; The three-dimensional map model data is rendered according to the basic rendering data, the visualization resources and the business application to generate the three-dimensional map model.
7. The method according to claim 1, characterized in that Before inputting the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data, the method further includes: Acquire a training data set, wherein the training data set includes model data samples and real model feature graphs; The model data sample and the random noise vector are input into the generator of the initial generative adversarial network model to generate the output corresponding to the current generator, the output corresponding to the current generator and the real model feature map are input into the discriminator of the initial generative adversarial network model, the initial generative adversarial network model is iteratively trained, and the preset generative adversarial network model is generated.
8. A three-dimensional map model generating device, characterized in that: include: The first acquisition module is used to acquire a two-dimensional vector map of the target area; A first generating module, used for processing the two-dimensional vector graph to generate regional feature data corresponding to the target area; A second generation module is used to input the regional feature data into a preset generative adversarial network model to generate three-dimensional map model data; The third generating module is used to render the three-dimensional map model data to generate the three-dimensional map model.
9. A terminal device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the terminal device implements the method according to any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by an electronic device, the method according to any one of claims 1 to 7 is implemented.