Adversarial generative road network automatic layout method and system based on multi-model features
Through the adversarial generation road network automatic layout method based on multi-model features, using the multi-backbone network fusion model and Pix2Pix generation adversarial neural network, the problems of slow speed and unstable generation quality of the existing technology middle-line network automatic generation algorithm are solved, and the problem of slow speed and unstable generation quality is realized. The fast and efficient road network layout can simulate the layout characteristics of advanced cities.
Patent Information
- Application Number
- CN202411027354.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-30
- Publication Date
- 2024-11-12
AI Technical Summary
The existing road network automatic generation algorithm is based on vector data, and the processing speed is slow, making it difficult to achieve rapid layout and modification. The reinforcement learning algorithm has high requirements for the initial state, the generation quality is unstable, and lacks the ability to learn from advanced urban layouts.
Adopting an adversarial generational road network automatic layout method based on multi-model features, by building a road network layout image sample library, training a multi-backbone network fusion model, using Pix2Pix to generate an adversarial neural network, fusing multiple backbone network features, and generating efficient and quality Good road network layout.
It realizes the rapid generation of high-quality road network layout, avoids the problem of slow vector data processing, improves the effect and robustness of road layout, and can learn and simulate the road network layout characteristics of advanced cities.
Smart Images

Figure CN118940632A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of automatic road network generation, and in particular to an adversarial generative road network automatic layout method and system based on multi-model features. Background Art
[0002] Road network layout is a relatively tedious task in the planning field. It is necessary to ensure both the density of road network distribution and the rationality of road network layout. In the past, road network layout work was mostly done manually by staff with strong professional knowledge, which was time-consuming and costly. Then the road network layout gradually turned to automatic generation. The current road network automatic generation algorithms are all vector-based road network layout algorithms. However, vector data contains a lot of information, so the processing speed of vector data is slow. Especially for large areas, it is difficult to achieve the purpose of fast layout and fast modification when using vector data for road layout.
[0003] In the research work of using computer vision's image processing capabilities to solve the tedious road network layout, looking at the current status of automatic road network layout algorithms at home and abroad, we have gradually shifted from vector-based road network layout algorithms to artificial intelligence algorithms based on path planning or image generation. Algorithms based on image generation are relatively good solutions, which can not only realize rapid road network layout, but also learn the road network layout characteristics of advanced cities at home and abroad.
[0004] Although there are some studies that use raster images and reinforcement learning algorithms to continuously try and error to achieve a better road network layout, reinforcement learning has high requirements for the initial state setting. Different initial states will lead to different results, and it is difficult to ensure that the road network generated each time has a relatively good quality. At the same time, the automatic road network layout based on reinforcement learning cannot learn from the road network layout cases of advanced cities at home and abroad, and lacks the ability to learn from excellent cases. Therefore, there is an urgent need for a method that can quickly generate road network layouts with good generation quality. Summary of the invention
[0005] In view of the shortcomings of the prior art, the present invention proposes an adversarial generative road network automatic layout method and system based on multi-model features, which can quickly generate road network layout with good generation quality.
[0006] In a first aspect, the present invention provides an adversarial generative road network automatic layout method based on multi-model features.
[0007] In a first possible implementation, a multi-model feature-based adversarial generative road network automatic layout method includes:
[0008] Constructing a road network layout image sample library; the road network layout image sample library stores road network image pairs of multiple areas;
[0009] The multi-trunk network fusion model is trained based on the road network layout image sample library to obtain the road network automatic layout generation model;
[0010] The environmental image data is input into the road network automatic layout generation model to obtain the road network layout result.
[0011] In combination with the first implementable method, in the second implementable method, a road network layout image sample library is constructed, including:
[0012] Collect vector data of road networks in multiple urban planning areas;
[0013] Obtaining a road network image pair of each area from the urban planning road network vector data; the road network image pair includes a first image and a second image, the first image includes all trunk roads and branch roads in the area, and the second image includes the trunk roads in the area;
[0014] The road network image pairs of each area are stored in the database to form a road network layout image sample library.
[0015] In combination with the first implementable method, in the third implementable method, before training the multi-trunk network fusion model according to the road network layout image sample library, the following steps are also included:
[0016] Build a Pix2Pix-like generative adversarial neural network with multiple backbone networks;
[0017] The Pix2Pix-like generative adversarial neural networks of each backbone network are fused with features at each level to obtain a multi-backbone network fusion model.
[0018] In combination with the first implementable method, in the fourth implementable method, the multiple backbone networks include: the backbone network used by the first Pix2Pix-like generative adversarial neural network is ResNet-50, the backbone network used by the second Pix2Pix-like generative adversarial neural network is ResNet-101, and the backbone network used by the third Pix2Pix-like generative adversarial neural network is ResNeXt-101.
[0019] In combination with the third implementable manner, in a fifth implementable manner, the Pix2Pix-like generative adversarial neural network includes a generative network and an adversarial network, and both the generative network and the adversarial network are composed of multiple convolutional layers and multiple pooling layers.
[0020] Combined with the third implementable method, in the sixth implementable method, the Pix2Pix-like generative adversarial neural network of each backbone network is used to fuse features at each level, including:
[0021] The feature maps of the same scale resolution output by each backbone network are fused by adding the feature elements.
[0022] Combined with the third implementable method, in the seventh implementable method, the fusion of features at each level includes:
[0023]
[0024] In the above formula, Backbone network B k The features after the l-th level fusion, Backbone network B k Features before the l-th level fusion, Backbone network B k-1 The l-layer features of g(·) are unified operations of feature dimensions before fusion. It is a non-linear operation.
[0025] In combination with the first implementable method, in the eighth implementable method, the multi-trunk network fusion model is trained according to the road network layout image sample library, including: based on the road network layout image sample library, using the back propagation algorithm to update the parameters of each layer of the multi-trunk network fusion model.
[0026] Combined with the fifth implementable method, in the ninth implementable method, the training strategy of the model is to minimize the loss of the generative network and maximize the loss of the adversarial network.
[0027] In a second aspect, the present invention provides an adversarial generative road network automatic layout system based on multi-model features.
[0028] In a tenth possible implementation, a multi-model feature-based adversarial generative road network automatic layout system includes:
[0029] A construction module is configured to construct a road network layout image sample library; the road network layout image sample library stores road network image pairs of multiple regions;
[0030] A road network automatic layout generation model acquisition module is configured to train a multi-trunk network fusion model according to a road network layout image sample library to obtain a road network automatic layout generation model;
[0031] The road network layout result acquisition module is configured to input the environmental image data into the road network automatic layout generation model to obtain the road network layout result.
[0032] It can be seen from the above technical solution that the beneficial technical effects of the present invention are as follows:
[0033] 1. This solution uses a road network layout image sample library to train a multi-trunk network fusion model, and then obtains the road network layout result based on the trained road network automatic layout generation model. Compared with vector data, this solution uses images to generate road network layout results, which is faster. In addition, the multi-trunk network fusion model uses a method of fusing multiple trunk networks to avoid the loss of image details, improve the effect of road automatic layout, and generate a good quality road network layout.
[0034] 2. The deep learning network specifically uses the Pix2Pix adversarial generative network to perform road layout on environmental images that only contain main roads. This method is very efficient and can learn the road network layout characteristics of advanced cities. It can also achieve good layout effects for road layouts in complex terrains and is highly robust. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following is a brief introduction to the drawings required for the specific embodiments or the prior art description. In all the drawings, similar elements or parts are generally identified by similar reference numerals. In the drawings, the elements or parts are not necessarily drawn according to the actual scale.
[0036] Figure 1 A schematic diagram of an adversarial generative road network automatic layout method based on multi-model features provided in this embodiment;
[0037] Figure 2 A schematic diagram of another adversarial generative road network automatic layout method based on multi-model features provided in this embodiment;
[0038] Figure 3 A schematic diagram of the fusion of various layers of a multi-trunk network fusion model provided in this embodiment;
[0039] Figure 4 This embodiment provides a structural schematic diagram of an adversarial generative road network automatic layout system based on multi-model features. DETAILED DESCRIPTION
[0040] The following embodiments of the technical solution of the present invention are described in detail in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and are therefore only used as examples, and cannot be used to limit the protection scope of the present invention.
[0041] It should be noted that, unless otherwise specified, the technical terms or scientific terms used in this application should be the common meanings understood by technicians in the field to which the present invention belongs. The terms "first", "second", etc. in the specification and claims of the embodiments of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so as to implement the embodiments of the present disclosure described here. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions. Unless otherwise specified, the term "multiple" means two or more. In the embodiments of the present disclosure, the character " / " indicates that the objects before and after are in an "or" relationship. For example, A / B means: A or B. The term "and / or" is a description of the association relationship of objects, indicating that there can be three relationships. For example, A and / or B means: A or B, or, A and B. The term "corresponding" can refer to an association relationship or a binding relationship, and A and B correspondingly refer to an association relationship or a binding relationship between A and B.
[0042] Combination Figure 1 As shown, this embodiment provides an adversarial generative road network automatic layout method based on multi-model features, including:
[0043] Step S01, constructing a road network layout image sample library; the road network layout image sample library stores road network image pairs of multiple regions;
[0044] Step S02: training the multi-trunk network fusion model according to the road network layout image sample library to obtain a road network automatic layout generation model;
[0045] Step S03: input the environmental image data into the road network automatic layout generation model to obtain the road network layout result.
[0046] Optionally, constructing a road network layout image sample library includes: collecting a plurality of urban planning road network vector data; obtaining a road network image pair of each area from the urban planning road network vector data; the road network image pair includes a first image and a second image, the first image includes all main roads and branches in the area, and the second image includes the main roads in the area; storing the road network image pairs of each area in a database to form a road network layout image sample library.
[0047] Optionally, the road network image pair of each area is an RGB image pair. From the urban planning road network vector data, main roads and branch roads are extracted according to color channels to construct the first RGB image and the second RGB image.
[0048] In some embodiments, advanced urban road layout cases are obtained from home and abroad, and the main roads, mountains, and water bodies are separated by image processing means, and then a first image A including the main roads, mountains, water bodies, and branch roads and a second image B including only the main roads, mountains, and water bodies are constructed. The first image and the second image of the same area form a road network image pair AB.
[0049] Optionally, before training the multi-trunk network fusion model according to the road network layout image sample library, it also includes: constructing Pix2Pix-like generative adversarial neural networks of multiple trunk networks; fusing the features of each level of the Pix2Pix-like generative adversarial neural networks of each trunk network to obtain the multi-trunk network fusion model.
[0050] Optionally, the multiple backbone networks include: the backbone network adopted by the first Pix2Pix-like generative adversarial neural network is ResNet-50, the backbone network adopted by the second Pix2Pix-like generative adversarial neural network is ResNet-101, and the backbone network adopted by the third Pix2Pix-like generative adversarial neural network is ResNeXt-101.
[0051] Combination Figure 2 As shown, this scheme first constructs a paired road network layout image sample library; then, the Pix2Pix-like generative adversarial neural network of the backbone network ResNet-50, the Pix2Pix-like generative adversarial neural network of the backbone network ResNet-101, and the Pix2Pix-like generative adversarial neural network of the backbone network ResNeXt-101 are subjected to multi-model feature fusion to obtain a multi-backbone network fusion model; the multi-backbone network fusion model is trained to obtain a road network automatic layout generation model; the environmental image data is input into the road network automatic layout generation model to obtain the road network layout result.
[0052] In the field of image generation, Pix2Pix can generate images with complete semantic information by inputting a small number of features. The input image c with only a few features is combined with random noise X and output through the generative network, while the input image d with complete features is combined with random noise X and output through the discriminative network. The purpose of the overall algorithm is to use the output of the generative network as the input of the discriminative network, so that the probability that the discriminative network judges to be true is large enough. In this way, only a small number of features are needed to obtain a complete image through the Pix2Pix algorithm. The Pix2Pix algorithm can quickly generate a road network layout by inputting necessary topographical elements and trunk roads. At the same time, this solution can integrate the features of multiple trunk networks of different scales to improve the network's ability to learn road layout details, obtain clearer and more accurate road layout results, and avoid problems such as discontinuous and unclear output road networks.
[0053] Optionally, the various types of Pix2Pix generative adversarial neural networks are consistent with the Pix2Pix network architecture of the prior art except for the backbone network.
[0054] Optionally, the Pix2Pix-like generative adversarial neural network includes a generative network and an adversarial network, and both the generative network and the adversarial network are composed of multiple convolutional layers and multiple pooling layers.
[0055] Optionally, in a convolutional layer, the output layer of the previous layer is used as the input layer of the next layer. The data of the input layer is convolved by a learnable convolution kernel and then passed through an activation function to obtain the output layer. The convolutional layer formula is expressed as:
[0056] Among them, M j represents the set of selected input layers, i is the index value of the input layer unit, j is the index value of the output layer unit, l represents the number of layers in the network, represents the weight between the input layer and the output layer, represents the activation bias between layers, f(·) represents the activation function of the output layer, represents the j-th output layer of the l-th layer, represents the i-th input layer of the l-1th layer, and * represents convolution.
[0057] In some embodiments, the Initialize and then train the network. Initialized with a Gaussian distribution with mean 0 and variance 0.01.
[0058] Optionally, the pooling layer is used to aggregate statistics of features at different locations in a large image. The pooling layer greatly reduces feature redundancy and reduces the dimension of statistical features. The maximum pooling layer has N input layers and N output layers, and each output layer is smaller than the input layer. The maximum pooling layer formula is expressed as:
[0059] Among them, down(·) represents a downsampling function, f(·) represents the activation function of the output layer, represents the multiplicative bias of the j-th output layer of the l-th layer, represents the additive bias of the jth output layer of the lth layer. Each output layer corresponds to its own multiplicative bias and additive bias. represents the j-th output layer of the l-th layer, represents the j-th output layer of the l-1-th layer.
[0060] Optionally, the activation function of the output layer is to sum all pixels in different n×n regions of the input image, so that the output image is reduced by a factor of n in both dimensions, where n is a preset value.
[0061] Optionally, the Pix2Pix-like generative adversarial neural networks of each backbone network are subjected to feature fusion at each level, including: fusing feature maps of the same scale resolution outputted by each backbone network in a manner of adding feature elements.
[0062] Optionally, combined Figure 3 As shown, the feature fusion process of each level uses the previous backbone network B k-1 The features of each level are used as the backbone network B k One of the inputs of each level feature to enhance the front backbone network B k Backbone network B k Level 1 Features Converged backbone network B k-1 The l-layer features The fusion process includes:
[0063]
[0064] In the above formula, Backbone network B k The features after the l-th level fusion, Backbone network B k Features before the l-th level fusion, Backbone network B k-1 The l-layer features of g(·) are unified operations of feature dimensions before fusion. It is a non-linear operation. To use RELU function.
[0065] Optionally, g(·) is a feature dimension unification operation before fusion, which consists of a 1×1 convolution layer and a batch standard layer. In this way, the amount of calculation can be reduced as much as possible while unifying the feature dimensions of each backbone network.
[0066] Optionally, when fusing the feature maps of the same scale resolution output by the backbone networks, the feature maps downsampled by 4, 8, 16 and 32 times of different backbone networks are element-wise added and fused.
[0067] In some embodiments, Table 1 is an example table of the network structure of each backbone network. As shown in Table 1, stage represents the stage, conv represents the convolution layer, maxpool represents the maximum pooling layer, stride represents the step size, and output represents the output result. The backbone networks include ResNet-50, ResNet-101, and ResNeXt-101. Each backbone network inputs an image of size 256×256. After passing through the maximum pooling layer, it passes through four convolutional layers. Each convolutional layer downsamples the feature map by 4, 8, 16, and 32 times to obtain feature maps of sizes 64×64, 32×32, 16×16, and 8×8, respectively. Then the feature maps of sizes 64×64, 32×32, 16×16, and 8×8 of the three backbone networks are fused separately to output the results. In this way, only the feature maps of different backbone networks downsampled by 4, 8, 16, and 32 times are fused, reducing the consumption of computing power.
[0068] Table 1
[0069]
[0070] Optionally, the multi-trunk network fusion model is trained according to the road network layout image sample library, including: based on the road network layout image sample library, using a back propagation algorithm to update the parameters of each layer of the multi-trunk network fusion model.
[0071] In some embodiments, the road network images in the road network layout image sample library are scaled to 268×268 size, and on this basis, the input images are randomly cropped to 256×256 size, so as to increase the number of samples without losing the main information, thereby improving the robustness and generalization performance of the model. The processed images are input into the multi-trunk network fusion model, and the back propagation algorithm is used for iterative training to obtain the road network automatic layout generation model.
[0072] Optionally, it also includes: a multi-trunk network fusion model outputs a false image, which is discriminated by a discriminant network.
[0073] Optionally, the multi-trunk network fusion model includes multiple Pix2Pix-like generative adversarial neural networks, each type of Pix2Pix generative adversarial neural network includes a generative network and an adversarial network, and the model is trained by minimizing the loss of the generative network while maximizing the loss of the discriminative network. The training strategy of the multi-trunk network fusion model is as follows:
[0074]
[0075] In the above formula, G * is the road network layout result, G is the output of the generative network, and D is the output of the adversarial network. represents the L1 loss of the generated image and the original image, represents the loss of the generative network and the adversarial network, It means minimizing the loss of the generator network while maximizing the loss of the discriminator network.
[0076] Optionally, the environmental image data is an image containing main roads, water bodies and mountains.
[0077] Combination Figure 4 As shown, an adversarial generative road network automatic layout system based on multi-model features includes: a construction module 101, configured to construct a road network layout image sample library; the road network layout image sample library stores road network image pairs of multiple areas; a road network automatic layout generation model acquisition module 102, configured to train a multi-trunk network fusion model according to the road network layout image sample library to obtain a road network automatic layout generation model; a road network layout result acquisition module 103, configured to input environmental image data into the road network automatic layout generation model to obtain a road network layout result.
[0078] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. These modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present invention, and they should all be included in the scope of the claims and specification of the present invention.
Claims
1. A method for automatic layout of road networks based on adversarial generative methods based on multi-model features, characterized in that: include: Build a road network layout image sample library; The road network layout image sample library stores road network image pairs of multiple areas; The multi-trunk network fusion model is trained based on the road network layout image sample library to obtain the road network automatic layout generation model; The environmental image data is input into the road network automatic layout generation model to obtain the road network layout result.
2. The method according to claim 1, characterized in that: Build a road network layout image sample library, including: Collect vector data of road networks in multiple urban planning areas; Obtaining a road network image pair of each area from the urban planning road network vector data; the road network image pair includes a first image and a second image, the first image includes all trunk roads and branch roads in the area, and the second image includes the trunk roads in the area; The road network image pairs of each area are stored in the database to form a road network layout image sample library.
3. The method according to claim 1, characterized in that Before training the multi-backbone network fusion model based on the road network layout image sample library, the following steps are also included: Build a Pix2Pix-like generative adversarial neural network with multiple backbone networks; The Pix2Pix-like generative adversarial neural networks of each backbone network are fused with features at each level to obtain a multi-backbone network fusion model.
4. The method according to claim 1, characterized in that: Multiple backbone networks include: the backbone network used by the first Pix2Pix-like generative adversarial neural network is ResNet-50, the backbone network used by the second Pix2Pix-like generative adversarial neural network is ResNet-101, and the backbone network used by the third Pix2Pix-like generative adversarial neural network is ResNeXt-101.
5. The method according to claim 3, characterized in that: The Pix2Pix-like generative adversarial neural network includes a generative network and an adversarial network, both of which are composed of multiple convolutional layers and multiple pooling layers.
6. The method according to claim 3, characterized in that The Pix2Pix-like generative adversarial neural networks of each backbone network are integrated with features at each level, including: The feature maps of the same scale resolution output by each backbone network are fused by adding the feature elements.
7. The method according to claim 3, characterized in that Feature fusion at each level includes: In the above formula, Backbone network B k The features after the fusion of the first level, Backbone network B k Features before the l-th level fusion, Backbone network B k-1 The l-layer features of g(·) are unified operations of feature dimensions before fusion. It is a non-linear operation.
8. The method according to claim 1, characterized in that The multi-trunk network fusion model is trained according to the road network layout image sample library, including: based on the road network layout image sample library, a back propagation algorithm is used to update the parameters of each layer of the multi-trunk network fusion model.
9. The method according to claim 5, characterized in that The training strategy of the model is to minimize the loss of the generative network and maximize the loss of the adversarial network.
10. An adversarial generative road network automatic layout system based on multi-model features, characterized in that: include: A building module, configured to build a road network layout image sample library; The road network layout image sample library stores road network image pairs of multiple areas; A road network automatic layout generation model acquisition module is configured to train a multi-trunk network fusion model according to a road network layout image sample library to obtain a road network automatic layout generation model; The road network layout result acquisition module is configured to input the environmental image data into the road network automatic layout generation model to obtain the road network layout result.
