Intelligent connectivity fracture network structure generation algorithm based on deep convolution-adversarial neural network

Through the deep convolution-adversarial neural network generation algorithm, the problems of low computational efficiency and high cost of crack networks in the existing technology are solved, and a fracture model of diversity and connectivity is generated, which improves the simulation efficiency in petroleum engineering and hydrogeology fields. and research efficiency.

CN118917255AInactive Publication Date: 2024-11-08ZHEJIANG OCEAN UNIV

Patent Information

Application Number
CN202411407720.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-10
Publication Date
2024-11-08
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Prior Art In the fields of hydrogeology and petroleum engineering, the computational efficiency of the fracture network is low and costly, and it is difficult to capture nonlinear features. It is difficult to generate diverse and accurate fracture networks, especially in complex petroleum reservoirs. Flow simulation is difficult.

Method used

Using the intelligent generation algorithm of connectivity crack network structure based on deep convolution-adversarial neural network, a crack network that conforms to complex geometric structures is generated through the DC-GAN model, including data preprocessing, construction and training of Generator and Discriminator models, and the variety is generated. Fracture model of sex and connectivity.

Benefits of technology

It improves the simulation efficiency of the crack network, reduces the calculation cost, provides more automated and intelligent crack network characterization and prediction solutions, and improves the efficiency of oil and gas extraction and groundwater flow research.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118917255A_ABST
    Figure CN118917255A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of fracture prediction, and discloses a connectivity fracture network structure intelligent generation algorithm based on a deep convolution-adversarial neural network, and the algorithm comprises the following steps: S1, collecting fracture data, and carrying out the preprocessing of the collected data, so as to form a data set; and step S2, a DC-GAN model is constructed, wherein the DC-GAN model comprises a Generator model and a Disscriminator model. According to the method, the fracture network conforming to the complex geometric structure, the large-scale fracture network and the fracture model with diversity, connectivity and complex geometric characteristics can be generated in the fields of hydrogeology and petroleum engineering, the simulation efficiency is effectively improved, the calculation cost is reduced, and the method is suitable for popularization and application. A more automatic and intelligent solution is provided for characterization and prediction of the fracture network, modeling and prediction of the fracture network are efficiently carried out, and the research and application efficiency of oil and gas exploitation, underground water flowing and geothermal energy utilization is greatly improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of crack prediction technology, and in particular to an intelligent generation algorithm for a connected crack network structure based on a deep convolutional-adversarial neural network. Background Art

[0002] In the fields of hydrogeology and petroleum, the study of fracture network structure is crucial for the prediction and control of fluid flow, contaminant migration, and oil and gas production. The connectivity, geometry, and distribution characteristics of the fracture network significantly affect the permeability of fluids in rocks, and thus the flow behavior in groundwater, geothermal systems, and oil and gas reservoirs. In the process of oil production, fractures are often the main channels for fluids, while the matrix usually has low permeability. Accurate characterization of these fracture networks can not only optimize production strategies, but also prevent environmental disasters (such as pollution or leakage) caused by reservoir rupture. Most existing technologies rely on numerical simulation and finite element analysis to characterize and predict fracture networks, but have the following defects and shortcomings.

[0003] Defects and shortcomings of the existing technology: 1. Inefficient calculation: Whether in the field of hydrogeology or petroleum engineering, the complex geometric structure of the fracture network makes traditional numerical simulation methods extremely computationally intensive. Especially when dealing with systems with large connectivity changes and dense fractures, the calculation speed drops significantly and cannot meet the requirements of rapid prediction.

[0004] 2. High computational cost: High-precision numerical simulation of fracture networks relies on powerful computing resources, especially in petroleum reservoir simulation, which involves large-scale fracture networks and complex fluid mechanics problems. High-performance computing platforms are usually required to support multiple iterations and optimization processes, resulting in high costs.

[0005] 3. The nonlinear characteristics of fracture networks are difficult to capture: Fracture networks usually exhibit complex nonlinear characteristics, and traditional simulation methods are difficult to fully explore and characterize the entire parameter space. This makes the fracture networks generated by the model often lack diversity and cannot effectively reflect the real geological characteristics, especially in the prediction of fracture distribution in complex oil reservoirs.

[0006] 4. Fluid flow in oil reservoirs is difficult to simulate: Fractures in oil reservoirs not only affect the migration of oil and gas, but also have an important impact on production efficiency and safety. Traditional models have difficulty simulating the behavior of fluids in fractures, especially in reservoirs involving high pressure and high temperature conditions, where the fluid dynamics of fractures are difficult to accurately capture; To address the above problems, an intelligent generation algorithm for connected fractured network structures based on deep convolutional-adversarial neural networks was proposed. Summary of the invention

[0007] In order to solve the technical problems existing in the prior art, the present invention provides an intelligent generation algorithm for a connected crack network structure based on a deep convolutional-adversarial neural network.

[0008] The present invention is implemented by the following technical solution: an intelligent generation algorithm of a connected crack network structure based on a deep convolution-adversarial neural network, comprising the following steps: Step S1, collecting fracture data and preprocessing the collected data to form a data set; Step S2: Build DC-GAN model: The DC-GAN model includes the Generator model and the Discriminator model; The Generator model includes an input layer A, a fully connected layer A1, a fully connected layer A2, a fully connected layer A3, an Unflatten layer, a transposed convolutional layer A1, a transposed convolutional layer A2, a convolutional layer A1, a convolutional layer A2, and an output layer A, which are connected in sequence; The Discriminator model includes an input layer B, a convolutional layer B1, a convolutional layer B2, a convolutional layer B3, a convolutional layer B4, a convolutional layer B5, a fully connected layer B, and an output layer B, which are connected in sequence, and the input layer B is connected to the output layer A; Step S3: Divide the data set into a training set and a test set in proportion, and input the DC-GAN model for training and optimization.

[0009] As a further improvement of the above solution, the crack data preprocessing in step S1 includes the following steps: Step S11, collecting crack data at the current position, the crack data including the number of cracks, crack angles and crack three-dimensional coordinates; Step S12, generating crack length: Set the length of the crack, control the distribution of the crack length, calculate the probability distribution of the crack length, and use the cumulative distribution function to generate the length of each crack; Step S13, crack angle generation: Setting the angle of the crack, generating the actual angle of each crack, and normalizing the generated actual angle to ensure that the calculated angle remains within the predetermined range; Step S14, crack position generation: The center point of each crack is randomly generated, and the center point of a specific crack in a specific area is determined by setting a specific direction distribution; Step S15: Shadow area detection and removal: Generate shadow areas for cracks and detect whether newly generated cracks overlap with existing crack shadow areas; Step S16, crack intersection requirements: Make sure that the newly generated fracture intersects with at least one existing fracture; Step S17: Determine the continuity of the fracture network: Conducting connectivity test on the generated fracture network; Step S18: Save the fracture network binary image.

[0010] As a further improvement of the above solution, the input layer A in step S2 is used for inputting the potential vector; Fully connected layers A1, A2, and A3 are used to convert the length of the data input by the input layer A; Unflatten layer, converting one-dimensional data into four-dimensional data; The transposed convolution layer A1 and the transposed convolution layer A2 perform a transposed convolution operation on the four-dimensional data converted by the Unflatten layer; Convolutional layers A1 and A2 are used to perform convolution operations on the transposed convolutional data; The output layer A outputs the crack network image content.

[0011] As a further improvement of the above solution, the input layer B in step S2 is used to input the trained crack network image content; Convolutional layer B1, convolutional layer B2, convolutional layer B3, convolutional layer B4 and convolutional layer B5 are used to perform convolution calculations on the input crack network image content; The fully connected layer B is used to flatten the convolutional data; The output layer B outputs the discrimination result of the Discriminator model.

[0012] As a further improvement of the above solution, the training of the DC-GAN model in step S3 includes the following steps: Step S21, model initialization: Initialize the model using the Adam optimizer: Step S22: Generator model training: First, the noise vector is input, and the Generator model training trains the noise vector to generate a fake image. The generated fake image is input to the Discriminator model for discrimination. After that, the gradient of the Generator model is calculated through back propagation, and the network parameters of the Generator model are updated using the optimizer (Adam). Step S23: Discriminator model training: The real images collected from the training set are input into the Discriminator model for discriminant training. After that, the updated Generator model is used to generate fake images, which are input into the Discriminator model for discriminant training. The total loss of the fake images and the fake and real images is calculated. The gradient of the Discriminator model is calculated through back propagation, and the network parameters of the Discriminator model are updated using the optimizer. Step S24, alternating training: When performing iterative training, first fix the Discriminator model and train the Generator model so that the output of the Generator model gradually approaches the truth; then fix the Generator model and train the Discriminator model so that it can better distinguish between real images and forged images; Step S25, regularly save the model and generate images: When training the model, a batch of images are generated and saved at a certain number of iterations to record the output results of the Generator model in this training phase; Train at fixed intervals and save the weights of the current Generator model and Discriminator model to facilitate restoring the previous model state during training; Step S26, setting the termination condition: Set termination conditions during the training process, including a fixed number of iterations and stopping training after the generated images reach a certain quality standard.

[0013] As a further improvement of the above solution, the input layer A in step S2 is used to input a potential vector with a length of 200; Fully connected layer A1: input 200 → output 1000, activation function LeakyReLU (0.1); Fully connected layer A2: input 1000 → output 4000, activation function LeakyReLU (0.1); Fully connected layer A3: input 4000 → output 10000, activation function LeakyReLU (0.1); Unflatten layer: converts a one-dimensional tensor into a four-dimensional one: shape 4x50x50; Transposed convolution layer A1: input 4x50x50 → output 32x100x100, convolution kernel 6x6, stride 2, padding 2; Transposed convolution layer A2: input 32x100x100 → output 128x200x200, convolution kernel 6x6, stride 2, padding 2; Convolutional layer A1: input 128x200x200 → output 16x200x200, convolution kernel 3x3, stride 1, padding 1; Convolutional layer A2: input 16x200x200 → output 1x200x200, convolution kernel 3x3, stride 1, padding 1; Output layer A: Sigmoid activation function, output shape 1x200x200.

[0014] As a further improvement of the above solution, in step S2, the input layer B has the following input shape: 1x200x200; Convolutional layer B1: Input: 1x200x200 → Output: feature_d x 100x100, kernel: 4x4, stride: 2, padding: 1; Convolutional layer B2: Input: feature_d x 100x100 → Output: feature_d * 2 x 50x50, convolution kernel: 4x4, stride: 2, padding: 1; Convolution layer B3: Input: feature_d * 2 x 50x50 → Output: feature_d * 4 x 25x25, convolution kernel: 4x4, stride: 2, padding: 1; Convolution layer B4: Input: feature_d * 4 x 25x25 → Output: feature_d * 8 x 12x12, convolution kernel: 4x4, stride: 2, padding: 1; Convolutional layer B5: Input: feature_d * 8 x 12x12 → Output: 1x5x5, convolution kernel: 4x4, stride: 2, padding: 0; Fully connected layer B: Input: flattened to

[25] feature vector Output: 1 value, through Sigmoid activation function; Output layer B: Output shape: 1.

[0015] As a further improvement of the above solution, the calculation formula of the probability distribution of the crack length is: ; where L is the length of the crack, a is the power that controls the crack length distribution, and c is the normalization constant Compared with the prior art, the present invention has the following beneficial effects: The present invention introduces a fracture network generation method based on a deep convolutional generative adversarial network (DC-GAN), which can generate fracture networks with complex geometric structures in the fields of hydrogeology and petroleum engineering; this method can not only generate large-scale fracture networks without relying on high computing resources, but also generate fracture models with diversity, connectivity and complex geometric characteristics; the introduction of this technology effectively improves simulation efficiency, reduces computing costs, and provides a more automated and intelligent solution for the characterization and prediction of fracture networks.

[0016] The present invention enables hydrogeologists and petroleum engineers to model and predict fracture networks more efficiently, greatly improving the research and application efficiency of oil and gas extraction, groundwater flow and geothermal energy utilization. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 A schematic diagram of the structure of the DC-GAN model provided by the present invention; Figure 2 A sample file diagram of the crack network in Example 2 provided by the present invention; Figure 3 These are sample images generated by 16 DCGANs in Example 2 provided by the present invention. DETAILED DESCRIPTION

[0018] The present invention is further described below in conjunction with the accompanying drawings and specific implementation methods. It should be noted that, under the premise of no conflict, the various embodiments or technical features described below can be arbitrarily combined to form a new embodiment.

[0019] Example 1 Please combine Figure 1 , an intelligent generation algorithm of a connectivity crack network structure based on a deep convolution-adversarial neural network in this embodiment includes the following steps: Step S1, collecting fracture data and preprocessing the collected data to form a data set; Fracture data preprocessing includes the following steps: Step S11, collecting crack data at the current position, the crack data including the number of cracks, crack angles and crack three-dimensional coordinates; Step S12, generating crack length: Set the length of the crack, control the distribution of the crack length, calculate the probability distribution of the crack length, and use the cumulative distribution function to generate the length of each crack; The calculation formula for the probability distribution of crack length is: ; Where L is the length of the crack, a is the power that controls the crack length distribution, and c is a normalization constant; Step S13, crack angle generation: Setting the angle of the crack, generating the actual angle of each crack, and normalizing the generated actual angle to ensure that the calculated angle remains within the predetermined range; Step S14, crack position generation: The center point of each crack is randomly generated, and the center point of a specific crack in a specific area is determined by setting a specific direction distribution; Step S15: Shadow area detection and removal: Generate shadow areas for cracks and detect whether newly generated cracks overlap with existing crack shadow areas; Step S16, crack intersection requirements: Make sure that the newly generated fracture intersects with at least one existing fracture; Step S17: Determine the continuity of the fracture network: Conducting connectivity test on the generated fracture network; Step S18: Fracture network binary image preservation Step S2: Build DC-GAN model: The DC-GAN model includes the Generator model and the Discriminator model; The Generator model includes an input layer A, a fully connected layer A1, a fully connected layer A2, a fully connected layer A3, an Unflatten layer, a transposed convolutional layer A1, a transposed convolutional layer A2, a convolutional layer A1, a convolutional layer A2, and an output layer A, which are connected in sequence; The input layer A is used for inputting latent vectors of length 200; Fully connected layers A1, A2, and A3 are used to convert the length of the data input by the input layer A; Fully connected layer A1: input 200 → output 1000, activation function LeakyReLU (0.1); Fully connected layer A2: input 1000 → output 4000, activation function LeakyReLU (0.1); Fully connected layer A3: input 4000 → output 10000, activation function LeakyReLU (0.1); Unflatten layer, converts one-dimensional data into four-dimensional data with a shape of 4x50x50; The transposed convolution layer A1 and the transposed convolution layer A2 perform a transposed convolution operation on the four-dimensional data converted by the Unflatten layer; Transposed convolution layer A1: input 4x50x50 → output 32x100x100, convolution kernel 6x6, stride 2, padding 2; Transposed convolution layer A2: input 32x100x100 → output 128x200x200, convolution kernel 6x6, stride 2, padding 2; Convolutional layers A1 and A2 are used to perform convolution operations on the transposed convolutional data; Convolutional layer A1: input 128x200x200 → output 16x200x200, convolution kernel 3x3, stride 1, padding 1; Convolutional layer A2: input 16x200x200 → output 1x200x200, convolution kernel 3x3, stride 1, padding 1; The output layer A outputs the crack network image content, uses the Sigmoid activation function, and the output shape is 1x200x200; The Discriminator model includes an input layer B, a convolutional layer B1, a convolutional layer B2, a convolutional layer B3, a convolutional layer B4, a convolutional layer B5, a fully connected layer B, and an output layer B, which are connected in sequence, and the input layer B is connected to the output layer A; The input layer B is used to input the trained crack network image content, and the input shape is: 1x200x200; Convolutional layer B1, convolutional layer B2, convolutional layer B3, convolutional layer B4 and convolutional layer B5 are used to perform convolution calculations on the input crack network image content; Convolutional layer B1: Input: 1x200x200 → Output: feature_d x 100x100, kernel: 4x4, stride: 2, padding: 1; Convolutional layer B2: Input: feature_d x 100x100 → Output: feature_d * 2 x 50x50, convolution kernel: 4x4, stride: 2, padding: 1; Convolution layer B3: Input: feature_d * 2 x 50x50 → Output: feature_d * 4 x 25x25, convolution kernel: 4x4, stride: 2, padding: 1; Convolution layer B4: Input: feature_d * 4 x 25x25 → Output: feature_d * 8 x 12x12, convolution kernel: 4x4, stride: 2, padding: 1; Convolutional layer B5: Input: feature_d * 8 x 12x12 → Output: 1x5x5, convolution kernel: 4x4, stride: 2, padding: 0; The fully connected layer B is used to flatten the convolutional data. Input: flattened feature vector

[25] Output: 1 value, through the Sigmoid activation function; The output layer B outputs the discrimination result of the Discriminator model, and the output shape is: 1; Step S3: Divide the data set into a training set and a test set according to the ratio, and input the DC-GAN model for training and optimization; The training of the DC-GAN model consists of the following steps: Step S21, model initialization: Initialize the model using the Adam optimizer: Step S22: Generator model training: First, the noise vector is input, and the Generator model training trains the noise vector to generate a fake image. The generated fake image is input to the Discriminator model for discrimination. After that, the gradient of the Generator model is calculated through back propagation, and the network parameters of the Generator model are updated using the optimizer (Adam). Step S23: Discriminator model training: The real images collected from the training set are input into the Discriminator model for discriminant training. After that, the updated Generator model is used to generate fake images, which are input into the Discriminator model for discriminant training. The total loss of the fake images and the fake and real images is calculated. The gradient of the Discriminator model is calculated through back propagation, and the network parameters of the Discriminator model are updated using the optimizer. Step S24, alternating training: When performing iterative training, first fix the Discriminator model and train the Generator model so that the output of the Generator model gradually approaches the truth; then fix the Generator model and train the Discriminator model so that it can better distinguish between real images and forged images; Step S25, regularly saving the model and generating images: When training the model, a batch of images are generated and saved at a certain number of iterations to record the output results of the Generator model in this training phase; Train at fixed intervals and save the weights of the current Generator model and Discriminator model to facilitate restoring the previous model state during training; Step S26, setting the termination condition: Termination conditions are set during the training process, including a fixed number of iterations and stopping training after the generated images reach a certain quality standard.

[0020] Example 2 An intelligent generation algorithm for a connected crack network structure based on a deep convolutional-adversarial neural network includes the following steps: 1. Establish a fracture network database: 1. Parameter setting and initialization Number of fractures: The number of fractures in each fracture network is randomly generated. The range of the number of fractures can be set according to the requirements, for example, between [14, 20].

[0021] Crack angle: Set the crack direction parameters angle1=-10 and angle2=65, representing the two main crack directions, and std=2 is the standard deviation of the crack angle.

[0022] Spatial size: Define the spatial size of the fracture network, xL=200, yL=200, and set the minimum value of the fracture length lmin=50 and the maximum value lbig=140.

[0023] 2. Generate fracture network: 2.1 Crack length generation The crack length is generated based on the statistical model of fractal geometry, and the specific steps are as follows: Parameter setting: Set the range between the minimum value lminl and the maximum value lbig of the crack length. The length of each crack is randomly generated within this range.

[0024] Distribution generation: The fractional dimension D and power a are used to control the distribution of crack lengths. The probability distribution of crack lengths is calculated using the following formula: ; Where L is the length of the crack, a is the power that controls the distribution of crack length, and c is a normalization constant. The length generated in this way obeys a power-law distribution and can simulate the distribution of cracks of different lengths in nature.

[0025] Random length generation: The length of each crack is generated by the cumulative distribution function (CDF). The crack length is obtained by random number sampling to ensure the diversity of the crack network.

[0026] 2.2 Crack Angle Generation The angles of the cracks are generated based on a normal distribution, with random deviations from two main directions: Main angles: Set two main directions, θ1=−10∘ and θ2=65∘.

[0027] Random deviation: The actual angle of each fracture is generated using a normal distribution with standard deviation σ=2∘. Some fractures will randomly deviate from the main direction to simulate the direction variation in the fracture network.

[0028] Angle normalization: Ensure that the generated angle is between 0∘ and 180∘ to avoid angles that are too large or too small.

[0029] 2.3 Random generation of crack positions Random center point generation: The center point of each crack is randomly generated in the set domain [0,xL]×[0,yL], and the position follows a uniform distribution.

[0030] Specific region generation: For the first few cracks, a specific y-direction distribution can be set so that their centers are located in a specific region (such as near the center of the domain) to simulate a more orderly crack distribution.

[0031] 2.4 Shadow area detection and removal After generating the cracks, it is necessary to detect whether the newly generated cracks invade the shadow area of ​​the existing cracks: Shadow Zone Generation: A shadow zone is generated for each rift, usually a certain width (w, 2 units in length) around the rift, representing the area of ​​influence of the rift.

[0032] Shadow area detection: Through the geometric intersection algorithm, detect whether the newly generated cracks overlap with the existing crack shadow areas. If overlap occurs, it means that the generation position of the new crack is inappropriate and the center position or angle needs to be regenerated.

[0033] 2.5 Requirements for intersection of cracks Connectivity of the fracture network is achieved by enforcing that new fractures intersect with existing fractures: Forced intersection: For each newly generated crack, it is required to intersect with at least one existing crack; this process is achieved by detecting the geometric intersection point of two cracks.

[0034] Geometric intersection detection: Use the geometric intersection algorithm to detect whether two cracks intersect; if the intersection requirement is not met, the algorithm will regenerate the center or angle of the crack until the intersection condition is met.

[0035] 2.6 Determination of the connectivity of the fracture network The resulting fracture network must be connected from the left side of the domain to the right side: Left-right connectivity detection: After the fracture network is generated, the algorithm will check whether there is a connected path from the left side of the domain x=0x =0x=0 to the right side x=xLx = xLx=xL; only when the fracture network meets this connectivity will it be considered a qualified fracture network.

[0036] Connectivity determination: If the fracture network does not meet the connectivity requirements, the generation process will restart until a connected fracture network is generated.

[0037] 2. The fracture network data generated by 7 will eventually be saved in a matrix format with a size of Nfrac * 4. Nfrac: represents the number of fractures generated, each row represents a fracture; 4: represents the four key attributes of each fracture, specifically: x1: the starting point x coordinate of the fracture; y1: the starting point y coordinate of the fracture; x2: the end point x coordinate of the fracture; y2: the end point y coordinate of the fracture; A total of 9000 such fracture network samples were generated as training data; the sample is shown in Table 1: Table 1 shows a sample of the crack network: Serial number x1 (m) y1 (m) x2 (m) y2 (m) 1 0 115.566 137.955 100.765 2 200 60 64.9387 75.3237 3 200 90 65.5197 102.011 4 200 140 142.92 25.5914 5 61.2281 119.928 187.086 98.396 6 128.495 143.853 80.5412 35.3569 7 27.4081 145.076 138.649 121.674 8 129.376 123.624 90.9972 38.7214 9 100.523 120.417 185.176 110.287 10 152.784 114.163 120.744 43.0135 11 51.3431 98.4081 127.876 83.523 12 54.9707 160.907 28.0761 102.151 13 26.96 134.47 89.9071 122.771 14 128.489 101.781 102.411 45.099 15 62.4142 88.2273 117.851 78.6575 16 175.038 119.1 150.5 65.6162 A sample file of a crack network is as follows: Figure 2 As shown; 2.8 Fracture network binary image saving Fracture image preservation: Divide the space into 200*200 grids; for each generated fracture network, assign 1 to the grid through which the fracture passes and 0 to the other grids to generate a binary image of the fracture and store it as a .txt file for subsequent model training.

[0038] 2. Reading fracture network data: After the above binary image files are iteratively loaded, the data are stored in the three-dimensional matrix DataDFN_CNN; the binary image data of 9,000 discrete fracture networks are loaded and integrated and saved as DataDFN_CNN.mat.

[0039] 1. Establish DC-GAN model: 1.1 Information import and parameter setting: The program first imports necessary libraries, such as torch, numpy, matplotlib, scipy.io, etc.; sets the hyperparameters of the GAN model, such as learning rate, batch size, potential dimension, etc., to ensure that the program can run efficiently in model training.

[0040] lrr = 0.0001 latent_dim = 200 bs = 64 The generator is the part of the model responsible for generating images from random noise; it consists of fully connected layers and transposed convolutional layers, through which the input random noise is gradually expanded into a 200x200 slit network image.

[0041] 2.2 Generator structure: Generator structure introduction: (1) Input layer (latent vector, latent_dim): Input: latent vector of length 200.

[0042] (2) Fully connected layer (Linear + LeakyReLU + BatchNorm1d): Layer 1: Input 200 → Output 1000, activation function LeakyReLU(0.1); Layer 2: Input 1000 → Output 4000, activation function LeakyReLU(0.1); Layer 3: Input 4000 → Output 10000, activation function LeakyReLU(0.1); Output shape:

[10000] .

[0043] (3) Unflatten: Convert a 1D tensor to 4D: shape 4x50x50.

[0044] (4) Transposed convolution layer (ConvTranspose2d + LeakyReLU + BatchNorm2d): Layer 1: Input 4x50x50 → Output 32x100x100, convolution kernel 6x6, stride 2, padding 2; Layer 2: Input 32x100x100 → Output 128x200x200, convolution kernel 6x6, stride 2, padding 2; (5) Ordinary convolution layer (Conv2d + LeakyReLU + BatchNorm2d): Layer 1: Input 128x200x200 → Output 16x200x200, convolution kernel 3x3, stride 1, padding 1; Layer 2: Input 16x200x200 → Output 1x200x200, convolution kernel 3x3, stride 1, padding 1; (6) Output layer (Sigmoid activation function): Output shape 1x200x200.

[0045] 2.3 Establishing the Discriminator The role of the discriminator is to judge the authenticity of the generated pictures and the real pictures; it extracts features through multiple convolutional layers, and finally outputs a probability through the fully connected layer and the Sigmoid function to indicate the authenticity of the input image.

[0046] Discriminator structure introduction: (1) Input layer (1x200x200 image): Input shape: 1x200x200.

[0047] (2) Convolutional layer 1 (Conv2d + LeakyReLU): Input: 1x200x200 → Output: feature_d x 100x100; Convolution kernel: 4x4, stride: 2, padding: 1; Activation function: LeakyReLU (negative slope is 0.2); (3) Convolutional layer 2 (Conv2d + BatchNorm2d + LeakyReLU): Input: feature_d x 100x100 → Output: feature_d * 2 x 50x50; Convolution kernel: 4x4, stride: 2, padding: 1; Batch Normalization: feature_d * 2 channels; Activation function: LeakyReLU (negative slope of 0.2).

[0048] (4) Convolutional layer 3 (Conv2d + BatchNorm2d + LeakyReLU): Input: feature_d * 2 x 50x50 → Output: feature_d * 4 x 25x25; Convolution kernel: 4x4, stride: 2, padding: 1; Batch Normalization: feature_d * 4 channels; Activation function: LeakyReLU (negative slope of 0.2).

[0049] (5) Convolutional layer 4 (Conv2d + BatchNorm2d + LeakyReLU): Input: feature_d * 4 x 25x25 → Output: feature_d * 8 x 12x12; Convolution kernel: 4x4, stride: 2, padding: 1; Batch normalization: feature_d * 8 channels; Activation function: LeakyReLU (negative slope of 0.2).

[0050] (6) Convolutional layer 5 (Conv2d): Input: feature_d * 8 x 12x12 → Output: 1x5x5; Convolution kernel: 4x4, stride: 2, padding: 0.

[0051] (7) Fully connected layer (Linear + Sigmoid): Input: flattened feature vector of

[25] ; Output: 1 value, passed through the Sigmoid activation function.

[0052] (8) Output layer: Output shape: 1.

[0053] 3.4. Use the Adam optimizer to update the weights of the generator and discriminator respectively; the Adam optimizer is a commonly used gradient descent optimization algorithm that can dynamically adjust the learning rate according to the historical gradient of each parameter.

[0054] optimizer_G = torch.optim.Adam(generator.parameters(), lrr * 2, betas=(0.5, 0.999)) optimizer_D = torch.optim.Adam(discriminator.parameters(), lrr, betas=(0.5, 0.999)) 3. Iterative Training Process In the training process of Generative Adversarial Network (GAN), the generator and the discriminator compete with each other through an alternating optimization process, aiming to improve the authenticity and discrimination ability of the generated images. Through this alternating optimization mechanism, the generator gradually learns to generate more and more realistic images, while the discriminator gradually improves its ability to distinguish between real and fake images. The core of this process is adversarial training, and the ultimate goal is that the images generated by the generator are realistic enough that the discriminator cannot effectively distinguish them from real images. The specific steps of the entire training process are as follows: (1) Initialization preparation Load and preprocess the dataset to convert it into a format suitable for neural network input; Load the network structure of the generator and discriminator to the device (such as GPU or CPU), and define the loss function (such as cross entropy loss) and optimizer (such as Adam) to update the model parameters.

[0055] (2) Generator training steps Input noise: A noise vector z of length latent_dim is randomly generated from a standard normal distribution (mean 0, variance 1); the noise is used as the input of the generator, which converts the noise into an image of shape 1x200x200 through a series of fully connected layers and convolutional layers; Generate fake images: The generator generates a fake image G(z) based on the input noise vector, with a shape of 1x200x200; Calculate the generator loss: Input the generated image into the discriminator and obtain the output of the discriminator on the generated image (a value close to 0 or 1), which indicates the discriminator's judgment on whether the image is real or fake; The loss of the generator G_loss is calculated by the cross entropy loss function, the goal is to maximize the "real" probability of the discriminator output, that is, the generator hopes that the discriminator "believes" that the image it generates is real; Update the generator parameters: The gradient of the generator is calculated through back propagation, and the optimizer (Adam) is used to update the network parameters of the generator to minimize the loss function G_loss; (3) Training steps of the discriminator Training with real images: Randomly sample a batch of real images real_images from the training dataset, with a shape of 1x200x200; Input these real images into the discriminator and obtain the discriminator's predicted output for these images (values ​​close to 1, indicating "real"); Calculate the loss of the real image D_real_loss. The goal is to maximize the loss, that is, the discriminator should identify the real image as accurately as possible; Generate image training: Using the generator in step 2, generate another batch of fake images fake_images; Feed these generated fake images into the discriminator and obtain the discriminator's output (values ​​close to 0 indicate "fake"); Calculate the loss of fake images D_fake_loss. The goal is to minimize this loss, that is, the discriminator should accurately identify these images as "fake"; Total loss: The total loss of the discriminator D_loss is the average of the real image loss and the fake image loss; Update the discriminator parameters: Calculate the gradient of the discriminator through back propagation, and use the optimizer to update the discriminator's network parameters to minimize D_loss; (4) Alternating training Alternating update: In each iteration, the discriminator is first fixed and the generator is trained so that the output of the generator gradually approaches the real one; then the generator is fixed and the discriminator is trained so that it can better distinguish between real images and forged images; By constantly updating the generator and the discriminator alternately, the performance of both is continuously improved during the training process: the images generated by the generator become more and more realistic, while the discriminator can better distinguish between real images and forged images. (5) Save the model and generate images regularly Generate intermediate results: Generate a batch of images every certain number of iterations (e.g. every 10 times) and save them locally to record the output results of the generator in this training phase. These intermediate generated images can be used to evaluate the progress of the generator; Model checkpoint: Every few rounds of training (such as every 2 epochs), save the weights of the current generator and discriminator models so that the previous model state can be restored during training.

[0056] (6) Termination conditions Termination conditions can be set during training, such as a fixed number of iterations, or stopping training when the generated images reach a certain quality standard. The competitive game between the generator and the discriminator will continue until the discriminator cannot distinguish between the generated images and the real images; Through this alternating optimization mechanism, the generator gradually learns to generate more and more realistic images, while the discriminator gradually improves its ability to distinguish between real and fake images. The core of this process is adversarial training, and the ultimate goal is that the images generated by the generator are realistic enough that the discriminator cannot effectively distinguish them from real images; Results show: 16 samples generated by DCGAN are as follows Figure 3 shown.

[0057] The present invention introduces a fracture network generation method based on a deep convolutional generative adversarial network (DC-GAN), which can generate fracture networks with complex geometric structures in the fields of hydrogeology and petroleum engineering; this method can not only generate large-scale fracture networks without relying on high computing resources, but also generate fracture models with diversity, connectivity and complex geometric characteristics; the introduction of this technology effectively improves simulation efficiency, reduces computing costs, and provides a more automated and intelligent solution for the characterization and prediction of fracture networks.

[0058] The present invention enables hydrogeologists and petroleum engineers to model and predict fracture networks more efficiently, greatly improving the research and application efficiency of oil and gas extraction, groundwater flow and geothermal energy utilization.

[0059] The above-mentioned embodiments are only preferred embodiments of the present invention and cannot be used to limit the scope of protection of the present invention. Any non-substantial changes and substitutions made by technicians in this field on the basis of the present invention shall fall within the scope of protection required by the present invention.

Claims

1. An intelligent generation algorithm for connected fracture network structure based on deep convolutional-adversarial neural network, It is characterized in that The following steps are involved: Step S1, collecting fracture data and preprocessing the collected data to form a data set; Step S2: Build DC-GAN model: The DC-GAN model includes the Generator model and the Discriminator model; The Generator model includes an input layer A, a fully connected layer A1, a fully connected layer A2, a fully connected layer A3, an Unflatten layer, a transposed convolutional layer A1, a transposed convolutional layer A2, a convolutional layer A1, a convolutional layer A2, and an output layer A, which are connected in sequence; The Discriminator model includes an input layer B, a convolutional layer B1, a convolutional layer B2, a convolutional layer B3, a convolutional layer B4, a convolutional layer B5, a fully connected layer B, and an output layer B, which are connected in sequence, and the input layer B is connected to the output layer A; Step S3: Divide the data set into a training set and a test set in proportion, and input the DC-GAN model for training and optimization.

2. The intelligent generation algorithm of the connected crack network structure based on the deep convolution-adversarial neural network as claimed in claim 1, It is characterized in that The crack data preprocessing in step S1 includes the following steps: Step S11, collecting crack data at the current position, the crack data including the number of cracks, crack angles and crack three-dimensional coordinates; Step S12, generating crack length: Set the length of the crack, control the distribution of the crack length, calculate the probability distribution of the crack length, and use the cumulative distribution function to generate the length of each crack; Step S13, crack angle generation: Setting the angle of the crack, generating the actual angle of each crack, and normalizing the generated actual angle to ensure that the calculated angle remains within the predetermined range; Step S14, crack position generation: The center point of each crack is randomly generated, and the center point of a specific crack in a specific area is determined by setting a specific direction distribution; Step S15: Shadow area detection and removal: Generate shadow areas for cracks and detect whether newly generated cracks overlap with existing crack shadow areas; Step S16, crack intersection requirements: Make sure that the newly generated fracture intersects with at least one existing fracture; Step S17: Determine the continuity of the fracture network: Conducting connectivity test on the generated fracture network; Step S18: Save the binary image of the fracture network.

3. The intelligent generation algorithm of the connected crack network structure based on the deep convolution-adversarial neural network as claimed in claim 1, It is characterized in that The input layer A in step S2 is used for inputting the potential vector; Fully connected layers A1, A2, and A3 are used to convert the length of the data input by the input layer A; Unflatten layer, converting one-dimensional data into four-dimensional data; The transposed convolution layer A1 and the transposed convolution layer A2 perform a transposed convolution operation on the four-dimensional data converted by the Unflatten layer; Convolutional layers A1 and A2 are used to perform convolution operations on the transposed convolutional data; The output layer A outputs the crack network image content.

4. The intelligent generation algorithm of the connected crack network structure based on the deep convolution-adversarial neural network as claimed in claim 1, It is characterized in that The input layer B in step S2 is used to input the trained crack network image content; Convolutional layer B1, convolutional layer B2, convolutional layer B3, convolutional layer B4 and convolutional layer B5 are used to perform convolution calculations on the input crack network image content; The fully connected layer B is used to flatten the convolutional data; The output layer B outputs the discrimination result of the Discriminator model.

5. The intelligent generation algorithm of connected fracture network structure based on deep convolution-adversarial neural network as claimed in claim 1, It is characterized in that The training of the DC-GAN model in step S3 includes the following steps: Step S21, model initialization: Initialize the model using the Adam optimizer: Step S22: Generator model training: First, the noise vector is input, and the Generator model training trains the noise vector to generate a fake image. The generated fake image is input to the Discriminator model for discrimination. After that, the gradient of the Generator model is calculated through back propagation, and the network parameters of the Generator model are updated using the optimizer (Adam). Step S23: Discriminator model training: The real images collected from the training set are input into the Discriminator model for discriminant training. After that, the updated Generator model is used to generate fake images, which are input into the Discriminator model for discriminant training. The total loss of the fake images and the fake and real images is calculated. The gradient of the Discriminator model is calculated through back propagation, and the network parameters of the Discriminator model are updated using the optimizer. Step S24, alternating training: When performing iterative training, first fix the Discriminator model and train the Generator model so that the output of the Generator model gradually approaches the real one; then fix the Generator model and train the Discriminator model so that it can better distinguish between real images and forged images; Step S25, regularly save the model and generate images: When training the model, a batch of images are generated and saved at a certain number of iterations to record the output results of the Generator model in this training phase; Train at fixed intervals and save the weights of the current Generator model and Discriminator model to facilitate restoring the previous model state during training; Step S26, setting the termination condition: Set termination conditions during the training process, including a fixed number of iterations and stopping training after the generated images reach a certain quality standard.

6. The intelligent generation algorithm of the connected fracture network structure based on the deep convolution-adversarial neural network as claimed in claim 1, It is characterized in that In step S2, the input layer A is used to input a potential vector with a length of 200; Fully connected layer A1: input 200 → output 1000, activation function LeakyReLU (0.1); Fully connected layer A2: input 1000 → output 4000, activation function LeakyReLU (0.1); Fully connected layer A3: input 4000 → output 10000, activation function LeakyReLU (0.1); Unflatten layer: converts a one-dimensional tensor into a four-dimensional one: shape 4x50x50; Transposed convolution layer A1: input 4x50x50 → output 32x100x100, convolution kernel 6x6, stride 2, padding 2; Transposed convolution layer A2: input 32x100x100 → output 128x200x200, convolution kernel 6x6, stride 2, padding 2; Convolutional layer A1: input 128x200x200 → output 16x200x200, convolution kernel 3x3, stride 1, padding 1; Convolutional layer A2: input 16x200x200 → output 1x200x200, convolution kernel 3x3, stride 1, padding 1; Output layer A: Sampled Sigmoid activation function, output shape 1x200x200.

7. The intelligent generation algorithm of the connected fracture network structure based on the deep convolution-adversarial neural network as claimed in claim 1, It is characterized in that Input layer B in step S2: input shape: 1x200x200; Convolutional layer B1: Input: 1x200x200 → Output: feature_d x 100x100, kernel: 4x4, stride: 2, padding: 1; Convolutional layer B2: Input: feature_d x 100x100 → Output: feature_d * 2 x 50x50, convolution kernel: 4x4, stride: 2, padding: 1; Convolution layer B3: Input: feature_d * 2 x 50x50 → Output: feature_d * 4 x 25x25, convolution kernel: 4x4, stride: 2, padding: 1; Convolution layer B4: Input: feature_d * 4 x 25x25 → Output: feature_d * 8 x 12x12, convolution kernel: 4x4, stride: 2, padding: 1; Convolutional layer B5: Input: feature_d * 8 x 12x12 → Output: 1x5x5, convolution kernel: 4x4, stride: 2, padding: 0; Fully connected layer B: Input: flattened to [25] feature vector Output: 1 value, through Sigmoid activation function; Output layer B: Output shape:

1.

8. The intelligent generation algorithm of the connected fracture network structure based on the deep convolution-adversarial neural network as claimed in claim 2, It is characterized in that The calculation formula of the probability distribution of the crack length is: ; Where L is the length of the crack, a is the power that controls the distribution of crack length, and c is the normalization constant.

Citation Information

Patent Citations

  • Fracture network connectivity and seepage computation method based on graph theory

    CN106991244A

  • A dam image crack detection method based on transfer learning

    CN109345507A

  • Construction method of fracture network model for rock core fractures

    CN113963130A

  • Adversarial sample generation method and system based on generative adversarial network

    CN115641471A

  • Limestone tunnel rock mass structural surface identification method and equipment

    CN115731390A

Cited By

  • Enhanced hot dry rock geothermal system fluid heat transfer process prediction method based on ANN network and agent model

    CN119761175A

  • Enhanced geothermal system fluid heat transfer process prediction method and proxy model based on ann network

    CN119761175B

  • Aquifer linear high-permeability channel identification method and system based on penalty term optimization

    CN120579400A

  • Method and system for identifying linear high-permeability channels in an aquifer based on optimization of a penalty term

    CN120579400B