A method and system for detecting homogenization temperature of gas-liquid inclusions in oil and gas reservoirs
Patent Information
- Application Number
- CN202211256117.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-13
- Publication Date
- 2026-11-03
- Estimated Expiration
- 2042-10-13
AI Technical Summary
Existing technologies are greatly affected by human subjectivity in the detection of gas-liquid inclusions in oil and gas reservoirs, making it difficult to accurately identify the homogenization temperature of gas-liquid two-phase brine inclusions. This is especially true when the individual inclusions are small, making it difficult to distinguish between the bubble and liquid boundaries, resulting in large errors in the test results and long testing time.
A deep transfer learning-based approach was adopted to construct a fluid inclusion image sample set and train it using the YOLOv5 model. By combining adaptive spatial feature fusion and hybrid domain convolutional attention mechanism, automatic identification of gas-liquid inclusions and real-time detection of uniform temperature were achieved.
It eliminates the influence of human factors, improves detection efficiency, reduces errors, and can accurately identify the shape, size and distribution characteristics of fluid inclusions, providing detailed data on hydrocarbon accumulation stages and solving the problem of chaotic fluid inclusions in different stages.
Smart Images

Figure CN117929456B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of oil and gas exploration and development technology, and in particular to a method and system for detecting the uniform temperature of gas-liquid inclusions in oil and gas reservoirs. Background Technology
[0002] Fluid inclusion analysis can reflect the composition, temperature, and pressure conditions of various fluids during geological periods. However, limitations imposed by the complex petrographic characteristics of fluid inclusions, experimental experience, and the size of fluid inclusions restrict their application in interpreting hydrocarbon accumulation and evolution. Identifying fluid inclusions and their phases associated with hydrocarbon accumulation remains a crucial research area. Currently, the main approach relies on researchers' experience to observe the characteristics of hydrocarbon inclusions and classify them into phases based on petrographic features. Homogenization temperatures of gas-liquid two-phase brine inclusions associated with hydrocarbons are then measured. The homogenization temperature is determined primarily through manual observation of the sample's heating process. Therefore, the process is susceptible to subjective bias and is time-consuming, especially when the gas-liquid inclusions are small, making it difficult to distinguish the boundary between bubbles and the surrounding liquid. Furthermore, the phase transition process is difficult to observe during heating, leading to significant errors in the test results. Therefore, the key challenge lies in using high-resolution cameras to capture high-resolution images of fluid inclusions, employing artificial intelligence to identify inclusions and determine their phases, and then using machine algorithms to identify the phase transition points of fluid inclusions in real time, thereby accurately determining the homogenization temperature. This approach can overcome the influence of human factors, reduce errors in measurement results, and significantly improve work efficiency. It is one of the urgently needed technologies for artificial intelligence research in the field of oil and gas reservoir formation. Summary of the Invention
[0003] The purpose of this invention is to provide a method and system for identifying gas-liquid inclusion types, classifying their phases, and detecting homogenization temperatures in oil and gas reservoirs based on deep transfer learning. Addressing the problems of time-consuming and labor-intensive phase classification and homogenization temperature testing of fluid inclusions in oil and gas reservoirs, and the significant influence of experimental experience on data results, this invention proposes a deep transfer learning method based on artificial intelligence to intelligently detect gas-liquid fluid inclusions related to hydrocarbon accumulation in oil and gas reservoirs and determine their homogenization temperatures. To achieve the above objectives, this invention provides the following technical solution:
[0004] A method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir, the method comprising:
[0005] Experiments were conducted on the homogenization temperature of fluid inclusions to construct an image sample set of fluid inclusions, wherein the image sample set was divided into a training set, a validation set, and a test set;
[0006] Extract image features from the image sample set and construct a network model for the fluid inclusion image sample set;
[0007] Image samples from the training and validation sets are imported into the network model for deep transfer learning training to obtain the trained network model.
[0008] The image samples from the test set are imported into the trained network model for detection and analysis to obtain the corresponding homogeneous temperature data of the gas-liquid inclusions.
[0009] Preferably, the image sample set for constructing fluid inclusions includes,
[0010] A raw image sample set of fluid inclusions was constructed using an image acquisition system with hot and cold stages;
[0011] The original image sample set of the acquired fluid inclusions is subjected to data augmentation processing to construct an image sample set of fluid inclusions; wherein, the data augmentation processing includes one or more of the following methods: Mosaic data augmentation, CutMix data augmentation, Mixup data augmentation, or Cutout data augmentation.
[0012] Preferably, the image sample set is divided into a training set, a validation set, and a test set, including:
[0013] The image sample set is divided into a training set, a validation set, and a test set according to a predetermined ratio;
[0014] Specifically, the fluid inclusions in the training and validation sets are labeled with both the outer shape of the inclusion and the shape of the gas inside the inclusion.
[0015] Preferably, the step of extracting image features from the image sample set and constructing a network model for the fluid inclusion image sample set includes:
[0016] The original network model is used to extract the overall features of the image sample set to obtain the channel attention fluid inclusion image feature map;
[0017] Based on the channel attention fluid inclusion image feature map, a hybrid domain fluid inclusion image feature map is formed;
[0018] The feature maps of fluid inclusion images in the hybrid domain are combined with adaptive spatial feature fusion to obtain the spatial weights of the fusion and to construct a primary network model for the fluid inclusion image sample set.
[0019] The primary model was pre-trained using an open-source dataset to build a network model for a fluid inclusion image sample set;
[0020] The open-source dataset includes either the COCO dataset or the VOC dataset.
[0021] Preferably, the original network model includes adding a hybrid domain convolutional attention mechanism to the end of the SPP layer of the backbone network of the YOLOv5 model and adding an adaptive spatial feature fusion method on the basis of YOLOv5;
[0022] The YOLOv5 models include one or more of YOLOv5s, YOLOv5m, YOLOv5l, or YOLOv5x.
[0023] Preferably, the image samples from the training and validation sets are imported into the network model for deep transfer learning training to obtain the trained network model, including:
[0024] The network model extracts features and trains on all image samples in the training set to obtain a primary training network model.
[0025] The initial trained network model is validated and optimized using a validation set to obtain a pre-trained network model.
[0026] Preferably, the network model performs feature extraction and training on all image samples in the training set to obtain a primary trained network model, including:
[0027] The training set is divided into N equal sub-training sets. The network model calculates the prior bounding box size data by processing the N sub-training sets. The prior bounding boxes and ground truth bounding boxes are fused using a visual attention mechanism in the network model to extract common features and obtain feature maps of fluid inclusions at different scales. The visual attention mechanism includes one of spatial domain attention, channel domain attention, hybrid domain convolutional attention, or parallel hybrid domain convolutional attention. The ground truth bounding boxes are obtained through manual annotation. The network model uses an adaptive spatial feature fusion method to extract common features from the feature maps of fluid inclusions at different scales and obtains a multi-layer adaptive spatial feature fusion layer for fluid inclusions. The multi-layer adaptive spatial feature fusion layer is used to predict the bounding box positions at the output end, and the positional loss of the predicted box and the ground truth bounding box is calculated to obtain the initial training network model.
[0028] Preferably, the step of using a validation set to validate and optimize the initially trained network model includes optimizing the position loss of the predicted bounding boxes and the ground truth bounding boxes, and stopping network training when the loss function value of the validation dataset converges to the minimum.
[0029] Preferably, the image samples from the test set are imported into the trained network model for detection and analysis to obtain the corresponding homogenization temperature data of gas-liquid inclusions. This includes: importing the test set images into the trained model; the trained network model identifies, locates, and labels the features of the test set images and automatically reads the experimental information of gas-liquid inclusions, wherein the experimental information of gas-liquid inclusions includes the experimental time and temperature of the gas-liquid inclusions; calculating the area size, bubble diameter, and gas-liquid ratio of the gas-liquid inclusions based on the experimental information; and identifying the area size, bubble diameter, and gas-liquid ratio of the gas-liquid inclusions to obtain the phenotypic data of the homogenization temperature of the liquid inclusions.
[0030] Preferably, the identification of the gas-liquid inclusion area, bubble diameter, and gas-liquid ratio includes,
[0031] The located gas-liquid inclusions are automatically extracted, and the gas-liquid inclusion image files are saved separately;
[0032] Each gas-liquid inclusion image is processed to obtain the gas-liquid inclusion outline image;
[0033] The gas-liquid inclusion contour images were analyzed to obtain phenotypic data of the homogenization temperature of the liquid inclusions.
[0034] Among them, the gas-liquid inclusion wheel image includes the experimental time, temperature and bubble diameter of the image capture.
[0035] Preferably, each gas-liquid inclusion image is processed, including:
[0036] Binarize each image of gas-liquid inclusions;
[0037] Contour approximation is performed on the binarized gas-liquid inclusion images, and the contour features of the gas-liquid inclusions are sorted.
[0038] Contour enhancement and effective ellipse approximation are applied to one or more gas-liquid inclusion contours with large areas from the sorted gas-liquid inclusion contour features.
[0039] Preferably, the analysis of the gas-liquid inclusion contour image includes,
[0040] Determine the phase changes of the gas-liquid inclusions based on the experimental time and temperature recorded in the gas-liquid inclusion wheel images;
[0041] When the bubbles in the gas-liquid inclusion wheel image disappear during the heating process, it is determined to be a uniform temperature, wherein the bubble diameter is 0 when the bubbles disappear.
[0042] Preferably, the phenotypic data of the homogenization temperature of the liquid inclusions include,
[0043] During the Nth heating process, when the bubble diameter is 0 N times in the gas-liquid inclusion wheel image, it is marked as the Nth homogenization temperature;
[0044] After marking the Nth homogenization temperature, the temperature recorded in the gas-liquid inclusion wheel image no longer increases. The final homogenization temperature is calculated as the average temperature of N times, generating phenotypic data of the homogenization temperature of the gas-liquid inclusions.
[0045] The phenotypic data of the homogenization temperature of the gas-liquid inclusions include the experimental time and temperature corresponding to N homogenization temperatures, as well as the average homogenization temperature.
[0046] The method also includes modifying the parameters of the fluid inclusions according to research needs after obtaining phenotypic data of the homogenization temperature of the fluid inclusions.
[0047] A system for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir, the system comprising,
[0048] The first construction unit is used to conduct a fluid inclusion homogenization temperature experiment and construct an image sample set of fluid inclusions, wherein the image sample set is divided into a training set, a validation set, and a test set.
[0049] The second construction unit is used to extract image features from the image sample set and construct a network model of the fluid inclusion image sample set.
[0050] The first acquisition unit is used to import the image samples of the training set and the validation set into the network model for deep transfer learning training, and to acquire the trained network model.
[0051] The second acquisition unit is used to import the image samples of the test set into the trained network model for detection and analysis, and to obtain the corresponding gas-liquid inclusion homogeneous temperature data.
[0052] The system also includes a modification unit, which, after acquiring phenotypic data of the homogenization temperature of the fluid inclusions, modifies the parameters of the fluid inclusions as needed.
[0053] The technical effects and advantages of this invention are as follows:
[0054] This invention eliminates the influence of human factors on test results. Utilizing extensive experimental analysis and advanced artificial intelligence learning methods, it trains a machine to identify and track gas-liquid two-phase fluid inclusions in real time. The process of bubble disappearance is precisely and continuously exported, allowing for one-to-one mapping and labeling of fluid inclusion shape, size, distribution characteristics, and other test data to determine the fluid inclusion's stage. This provides detailed experimental data for interpreting hydrocarbon accumulation stages, resolving the confusion caused by mixing fluid inclusions from different stages and distinguishing data based on temperature, which was common in previous methods.
[0055] Other features and advantages of the invention will be set forth in the description which follows, and will be apparent in part from the description, or may be learned by practicing the invention. The objects and other advantages of the invention may be realized and obtained by means of the structures pointed out in the description, claims and drawings. Attached Figure Description
[0056] Figure 1 This is a flowchart of the gas-liquid inclusion homogeneity temperature detection method of the present invention;
[0057] Figure 2 This is a schematic diagram of the dual-target deep transfer learning algorithm in an embodiment of the present invention;
[0058] Figure 3 This is a schematic diagram of the gas-liquid inclusion uniformity temperature detection system of the present invention;
[0059] Figure 4A This is the intelligent detection data result of the gas-liquid inclusion at 139°C in the embodiment of the present invention;
[0060] Figure 4B The data obtained from the intelligent detection of gas-liquid inclusions at 150.4°C in this embodiment of the invention are as follows;
[0061] Figure 4C This is the intelligent detection data result of the gas-liquid inclusion at 160°C in the embodiment of the present invention;
[0062] Figure 4D This is the intelligent detection data result of the gas-liquid inclusion at 170°C in the embodiment of the present invention;
[0063] Figure 4E The data obtained from the intelligent detection of gas-liquid inclusions at 179.5°C in this embodiment of the invention are as follows;
[0064] Figure 4F The data obtained from the intelligent detection of gas-liquid inclusions at 197.3°C in this embodiment of the invention are as follows;
[0065] Figure 4G The data obtained from the intelligent detection of gas-liquid inclusions at 198.1°C in this embodiment of the invention are as follows;
[0066] Figure 4H The data obtained from the intelligent detection of gas-liquid inclusions at 198.9°C in this embodiment of the invention are as follows;
[0067] Figure 4I The data obtained from the intelligent detection of gas-liquid inclusions at 199.9°C in this embodiment of the invention are as follows. Detailed Implementation
[0068] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0069] To address the shortcomings of existing technologies, this invention discloses a method for detecting the homogenization temperature of gas-liquid inclusions in oil and gas reservoirs, such as... Figure 1 As shown, the method includes: conducting homogenization temperature experiments on fluid inclusions to construct a feature image sample set of fluid inclusions; extracting image features from the feature image sample set to construct a network model of the fluid inclusion image sample set; pre-training the network model using deep transfer learning to obtain the pre-trained network model; importing the images from the image sample set into the pre-trained network model for detection and analysis to obtain corresponding homogenization temperature phenotypic data of gas-liquid inclusions; and visualizing the detection, localization, and recognition results of fluid inclusions, allowing users to modify parameters as needed until satisfactory results are achieved. This invention can automatically, accurately, and efficiently perform intelligent detection, recognition, and analysis of the homogenization temperature of fluid inclusions and gas-liquid inclusions, and automatically generate corresponding phenotypic data, providing great convenience for subsequent research.
[0070] Further, the construction of the image sample set of fluid inclusions includes: constructing an original image sample set of fluid inclusions using an image acquisition system with a hot and cold stage; performing data augmentation processing on the acquired original image sample set of fluid inclusions to construct the image sample set of fluid inclusions; wherein the data augmentation processing includes one or more of the following methods: Mosaic data augmentation, CutMix data augmentation, Mixup data augmentation, or Cutout data augmentation.
[0071] Further, the image sample set is divided into a training set, a validation set, and a test set, including dividing the image sample set into a training set, a validation set, and a test set according to a predetermined ratio; wherein, the fluid inclusions in the training set and the validation set are labeled with dual targets: the shape of the inclusion and the shape of the gas inside the inclusion.
[0072] Further, the step of extracting image features from the image sample set and constructing a network model for the fluid inclusion image sample set includes: using the original network model to extract the overall features of the image sample set and obtaining a channel attention fluid inclusion image feature map; forming a hybrid domain fluid inclusion image feature map based on the channel attention fluid inclusion image feature map; combining the hybrid domain fluid inclusion image feature map with adaptive spatial feature fusion to obtain the fused spatial weights and constructing a primary network model for the fluid inclusion image sample set; and pre-training the primary model using an open-source dataset to construct a network model for the fluid inclusion image sample set; wherein the open-source dataset includes either the COCO dataset or the VOC dataset.
[0073] Furthermore, the original network model includes adding a hybrid domain convolutional attention mechanism to the end of the SPP layer of the backbone network of the YOLOv5 model and adding an adaptive spatial feature fusion method on the basis of YOLOv5; wherein, the YOLOv5 model includes one or more of YOLOv5s, YOLOv5m, YOLOv5l or YOLOv5x.
[0074] Furthermore, the image samples from the training and validation sets are imported into the network model for deep transfer learning training to obtain the trained network model, including...
[0075] The network model performs feature extraction and training on all image samples in the training set to obtain a primary training network model. This includes: dividing the training set into N equal sub-training sets; calculating the prior bounding box size data from the N sub-training sets; mixing the feature data of the prior bounding boxes and ground truth bounding boxes using a visual attention mechanism within the network model and extracting common features to obtain feature maps of fluid inclusion images at different scales; extracting common features from the feature maps of fluid inclusion images at different scales using an adaptive spatial feature fusion method within the network model to obtain a multi-layer adaptive spatial feature fusion layer for fluid inclusion images; and predicting the bounding box positions of each multi-layer adaptive spatial feature fusion layer through its output, calculating the positional losses of the predicted and ground truth bounding boxes to obtain the primary training network model.
[0076] The ground truth bounding boxes are obtained through manual annotation. Visual attention mechanisms include one of the following: spatial domain attention, channel domain attention, hybrid domain convolutional attention, or parallel hybrid domain convolutional attention. Based on the different "domains of interest," visual attention mechanisms can be divided into three main categories: spatial domain attention, channel domain attention, and hybrid domain attention. Spatial domain attention mechanisms transform the spatial information in the image to extract key information. This involves generating a mask for the space and scoring it. However, a drawback is that this spatial domain method is limited to the original image feature extraction stage, ignoring the different features represented by different channels.
[0077] Channel-domain attention mechanism: This is similar to assigning a weight to each channel to represent the relevance of that channel to key information. Masks are generated for each channel, and scores are applied. A drawback is that it often performs global average pooling on the information within a single channel, ignoring local information within each channel.
[0078] Hybrid domain convolutional attention (CBAM) is composed of channel and spatial attention mechanisms, and its performance is better than that of spatial and channel attention mechanisms alone. This combination is a serial structure of spatial and channel attention mechanisms. There is also a parallel structure of spatial and channel attention mechanisms, called parallel hybrid domain convolutional attention (P-CBAM). In this case, CBAM is composed of both channel and spatial attention mechanisms; the other is a parallel structure of spatial and channel attention mechanisms, called parallel hybrid domain convolutional attention (P-CBAM).
[0079] Furthermore, the initially trained network model is validated and optimized using a validation set, including optimizing the position loss of the predicted and ground truth boxes. Network training stops when the loss function value of the validation dataset converges to its minimum. In one embodiment of the invention, combined with... Figure 1 As shown, the method of the present invention is carried out according to the following scheme:
[0080] Step 1: Conduct experiments to determine the homogenization temperature of fluid inclusions using hot and cold stages, obtaining a sample set of images showing the microscopic distribution of different inclusions. Then, import all inclusion image samples into the dual-target fluid inclusion image import module. These inclusion image samples are divided into training, validation, and test sets according to user requirements and in a ratio (e.g., 8:1:1). For the training and validation sets, dual-target annotation (i.e., bounding boxes, Bboxes) is performed on the inclusion shape and the internal gas or solid shape of the inclusions. The test set images are not annotated. The implementation is as follows:
[0081] The cut inclusion slices are placed in the sample chamber of the hot and cold stage. The microscope is adjusted to position and focus the inclusions to be tested. Different types of inclusions are identified based on their morphology, size, and grayscale, including single-phase inclusions (pure gas inclusions, pure liquid inclusions, and pure solid inclusions), two-phase inclusions (gas-liquid inclusions and solid-liquid inclusions), or three-phase inclusions (gas-liquid-solid inclusions). Gas-liquid inclusions are then selected, and images of these inclusions are captured by the image acquisition system of the hot and cold stage.
[0082] Temperature measurement experiments were conducted on the selected gas-liquid inclusions. Based on the burial depth of the target layer and the characteristics of the geothermal gradient in the geological study area, initial temperatures and initial heating rates were set. Generally, the initial heating rate was set to 10-20℃ / min. Heating was paused every 5-10℃ increase to observe phase changes within the inclusions. When the bubbles in the inclusions significantly decreased in size, the heating rate was set to 0.5-1℃ / min. The temperature at which the bubbles disappeared was observed and recorded, and the temperature was held constant for 1-2 minutes to verify whether the inclusions were completely homogeneous. This is because sometimes very small bubbles may adhere to the cavity wall of the inclusion and not truly disappear. In this case, a cyclic temperature measurement method was used for confirmation, thus accurately defining the homogeneity temperature of the inclusion. The measured temperature of the inclusion was recorded, and then the calibration value of the inclusion was calculated using a graph. Throughout the experiment, the image acquisition system of the hot and cold stage was used to capture images of the homogeneity temperature measurement process of these gas-liquid inclusions, thereby obtaining an image sample set of fluid inclusions.
[0083] In one embodiment of the present invention, in order to enrich the dataset, enhance the robustness of the network and reduce GPU usage, the obtained image sample set of fluid inclusions is subjected to Mosaic data augmentation. Mosaic data augmentation mainly involves cropping a selected image and three random images each time and stitching them together into one image. Then, the integrated image is randomly rotated, translated, scaled, cropped and color gamut changed to generate a new data sample set for model training.
[0084] In one embodiment of the present invention, the labeling software LabelImg is used to manually label the two targets, namely the outer shape of the inclusion and the shape of the gas or solid inside the inclusion, on the training set and validation set image samples. After successful labeling, the corresponding XML tag file is generated and saved. The file records the bounding box coordinates and label names (the label names are named according to the inclusion type) of all the outer shape of the inclusion and the shape of the gas or solid inside the inclusion for each training set and validation set image sample.
[0085] Step 2: Feature Extraction Model Construction Stage. A learning model for the fluid inclusion image sample set is built using RFIUT_YOLOv5x_AI (Real-time fluid inclusion uniform temperature detection system), an improvement upon YOLOv5x. The implementation is as follows:
[0086] The pre-trained RFIUT_YOLOv5x_AI is used as the base feature extraction model. This model is based on YOLOv5x, which consists of four parts: input, backbone network, neck network, and prediction. The structure diagram is shown below. Figure 2 As shown;
[0087] The RFIUT_YOLOv5x_AI model adds a hybrid domain convolutional attention mechanism (CBAM) to the ends of the Spatial Pyramid Pooling (SPP) layers in the YOLOv5x backbone network. The structure diagram is shown below. Figure 2As shown, the backbone network employs a focus module for slicing to achieve downsampling without information loss. It then enters the CONV module (vector convolution operation) for feature extraction. The extracted feature maps are then processed through three sets of Cross-Stage Partial Network (CSP) structures and CONV module convolution operations. A Spatial Pyramid Pooling (SPP) module is then used to extract features from the previous step's feature maps from multiple perspectives, thereby improving model accuracy. A Convolutional Block Attention Module (CBAM) is then used to generate a hybrid domain feature map. Finally, the CONV module restores the output to be consistent with the SPP module's output, resulting in feature maps of three different scales. The neck network consists of a Feature Pyramid Network (FPN), a Path Aggregation Network (PAN), a Cross-Stage Partial Network (CSP), and an Adaptively Spatial Feature Fusion (ASFF). The three feature maps at different scales obtained from the backbone network are input into the neck network. In the neck network, a Feature Pyramid Network (FPN) is used to enhance and fuse features from different layers, resulting in three fused feature maps at different scales. Then, a Path Aggregation Network (PAN) and a Cross-Stage Local Network (CSP) are used for further feature fusion to enhance localization capabilities at multiple scales, thus obtaining three new fused feature maps at different scales. Finally, these three new fused feature maps at different scales are used in an Adaptive Spatial Feature Fusion (ASFF) module to adaptively learn weight parameters to fuse features from different spatial feature layers, resulting in three feature maps at different scales. The head network (prediction) takes the three final feature maps at different scales output from the neck network and performs convolution operations through a Conv2d module to obtain three prediction maps at different scales. The Feature Pyramid Network (FPN) mainly consists of two sets of concat modules, an upsampling module, a convolutional module (CONV), and a Cross Stage Partial Network (CSP). The Path Aggregation Network (PAN) consists of one CONV module and one concat module. The Cross Stage Partial Network (CSP) mainly consists of a CONV module and a concat module.The Spatial Pyramid Pooling (SPP) module performs max pooling, with formula (5), and the upsampling module has formula (6). The CONV module includes convolution, batch normalization (BN), and SiLU activation function (swish) operations; the convolution formula is (1), the batch normalization (BN) formula is (2), and the SiLU activation function (swish) formula is (3).
[0088] φ i =τ*φ i-1 +b (1)
[0089] φ i For the i-th convolutional value, φ i-1 Let be the (i-1)th convolution value, τ be the convolution weight, and b be the convolution bias.
[0090]
[0091] ω i Let γ be the i-th batch normalized value, β be the batch normalized weight, and θ be the batch normalized bias. 2 Let μ be the moving variance, μ be the moving mean, and ∈ be the batch normalization constant.
[0092]
[0093] Swich(υ) is the value of the swish activation function, and υ is the activation function variable. The formula for concatting the modules is (4).
[0094]
[0095] ψ concat Z represents the computational cost per channel. η E is the ηth computational quantity for the Z-path channel. η For the ηth computational quantity of channel E, O η For the ηth characteristic number, O η + z The η+πth feature number. The Spatial Pyramid Pooling (SPP) module is a max pooling operation, and the formula is (5).
[0096]
[0097] θ represents the coordinates of a point on the feature map, and ξ represents the coordinates of a point in the original input image. This is the product of all strides in the convolution. The formula for the upsampling module is (6).
[0098] Λ(t)=Ω1*Λ(ρ1)+Ω2*Λ(ρ2)+Ω3*Λ(ρ3)+Ω4*Λ(ρ4) (6)
[0099] Λ(t) represents the pixel value at point t, Ω1, Ω2, Ω3, and Ω4 are weight ratios of the four points to the pixels at point t, and Λ(ρ1), Λ(ρ2), Λ(ρ3), and Λ(ρ4) are the pixel values of the four points ρ1, ρ2, ρ3, and ρ4, respectively. The hybrid domain convolutional attention mechanism first extracts the overall features of the fluid inclusion image feature map channel by channel through the channel attention module, obtaining the channel attention fluid inclusion image feature map. This feature map is then used as the input to the spatial attention module, ultimately forming a hybrid domain fluid inclusion image feature map. This effectively improves the detection accuracy and convergence speed of the model in recognizing fluid inclusion images. The expression output by the channel attention module is shown in (7).
[0100] M c (F)=σ(MLP(AvgPool(F)+MLP(MaxPool(F)))) (7)
[0101] The expression output by the spatial attention module is shown in (8).
[0102] M s (F)=σ(f 7×7 (Concat(AvgPool(F),MaxPool(F)))) (8)
[0103] in, For the input feature map, For the output of the channel attention module, For the spatial attention module output, σ is the sigmoid function, MLP represents a multilayer perceptron containing two fully connected layers and a ReLU activation function, f 7×7 This is a convolution operation with a 7x7 kernel. Maxpool is the maximum pooling method, and Avgpool is the average pooling method.
[0104] In one embodiment of the present invention, the feature fusion process of the RFIUT_YOLOv5x_AI model mainly adopts the Adaptively Spatial Feature Fusion (ASFF) method based on YOLOv5x. By adaptively learning the spatial weights for fusing feature maps of fluid inclusion images at different scales, the scale invariance of fluid inclusion image features is improved without increasing other overhead, thereby improving the recognition accuracy of fluid inclusion images at different small scales. This method mainly involves multiplying each of the three pyramid feature layers generated by the YOLOv5x prediction end by the features of the other two layers by weight parameters and then adding them together to obtain a new adaptive spatial feature fusion layer. The structure diagram is shown below. Figure 2 As shown, the expression is,
[0105]
[0106]
[0107] in, For the corresponding Level I features, The feature vector at position (i, j) in the first layer of the pyramid feature layer is mapped from n to level I; The feature vector at position (i, j) in the second layer of the pyramid feature layer is mapped from n to level I; The feature vector at position (i, j) in the third layer of the pyramid feature layer is mapped from n to level I; This represents the weight parameter at the level I feature corresponding to the first layer position (i, j) of the pyramid feature layer; This represents the weight parameters at the level I feature corresponding to the second layer position (i, j) of the pyramid feature layer; This represents the weight parameter at the level I feature corresponding to the third layer position (i, j) of the pyramid feature layer; express The convolution values corresponding to the weight parameters; express The convolution values corresponding to the weight parameters. express The convolution values corresponding to the weight parameters.
[0108] Step 3: In the pre-training phase, the RFIUT_YOLOv5x_AI network model is used to pre-train the COCO dataset to obtain the initial parameters of the network model; finally, the pre-trained real-time fluid inclusion homogeneous temperature detection system model RFIUT_YOLOv5x_AI is obtained, as follows:
[0109] 3a) Convert the COCO dataset label format to YOL0 text format;
[0110] 3b) The RFIUT_YOLOv5x_AI model was pre-trained on the COCO dataset. The number of classes (nc) was set to 80, and the class names (name) were set according to the user's needs. The number of classes was searched starting from 0. The maximum threshold for the aspect ratio (img-size) of the default anchor box was 4, the best recall rate (recall) of the default anchor box was 0.98, the default number of iterations (epochs) of the k-means clustering algorithm was 1000, the default network depth was 1.33, the default network width was 1.25, the number of cluster centers (k) was 9, and the weight update parameter (batch-size) was 20. This yielded the pre-trained real-time fluid inclusion uniform temperature detection system model RFIUT_YOLOv5x_AI network model.
[0111] Step 4: Employ deep transfer learning, combining the RFIUT_YOLOv5v_AI pre-trained model to extract features and train the model on all image samples in the training dataset. Optimize the trained model using the validation set. Stop network training when the loss function value on the validation dataset converges to its minimum, and save the current model. The implementation is as follows:
[0112] 4a) Modify the number of classes (nc) of the pre-trained model of RFIUT_YOLOv5x_AI to 6, and class names (name) are classified into 6 class names according to fluid inclusions, namely pure gas inclusions, pure liquid inclusions, pure solid gas-liquid inclusions, solid-liquid inclusions and gas-liquid-solid inclusions;
[0113] 4b) Image data Mosaic augmentation: To increase the fluid inclusion image dataset and address the lack of samples, all fluid inclusion images were resized uniformly (640*640 pixels). The Mosaic data augmentation method was used to crop a selected image and three random images and stitch them together into one image. Then, the integrated image was randomly rotated, translated, scaled, cropped, and its color gamut was changed to generate a new data sample set for model training.
[0114] 4c) Image data Sobel operator processing: In order to identify different types of fluid inclusions, the Sobel operator method is used to perform first-order gradient processing on the inclusions and bubbles in the same fluid inclusion image based on the different features of the size and shape of the fluid inclusions. This makes the features of the inclusions and bubbles more obvious after processing, so that they can be segmented from the image environment background.
[0115] 4d) Divide the dataset into different sets: According to user needs, divide all fluid inclusion image samples obtained in step 4b) into training set, validation set and test set according to ratio (e.g. 8:1:1);
[0116] 4e) Divide the training set into mini-batch datasets: Based on user requirements, divide all training set data into N mini-batch datasets on an average basis;
[0117] 4f) Image data import: The original image of the labeled fluid inclusions of the same size and the feature map of the fluid inclusions processed in step 4b) are used as input to the RFIUT_YOLOv5x_AI pre-trained model to form a multi-channel input image;
[0118] 4g) RFIUT_YOLOv5x_AI pre-trained model input: The RFIUT_YOLOv5x_AI pre-trained model divides a 640*640 image into N*N (usually 80*80, 40*40, 20*20) grid regions, which means it obtains three feature maps of different sizes, and uses the adaptive anchor box calculation function (K-means clustering algorithm) of the input to obtain the prior box size;
[0119] The steps to achieve this are as follows:
[0120] (4g-1) Adaptive anchor box calculation function (K-means clustering algorithm): randomly select 9 initial cluster centers from the fluid inclusion training set, i.e. 9 anchor boxes;
[0121] (4g-2) In order to solve the problem of large clustering error caused by large differences in the height and width of different sample boxes, the width and height of each sample box in the image are first divided by the width and height of the image respectively, and normalization is performed so that the value range of the width and height of the sample box is [0,1].
[0122] (4g-3) Calculate the intersection-union ratio (IOU) distance between each sample box and the 9 anchor boxes. (IOU is a measure of the similarity between the sample box and the anchor boxes, i.e., the similarity in width, height, and position; it is the ratio of the area of the intersection region of the sample box and the area of the merged region.) Assume there are m sample boxes (i takes values [1, m]), and sample box (B i ) and anchor frame (B a The width and height of the bounding box (B) are (w1, h1) and (w2, h2) respectively. i ) and anchor frame (B a The data length is 2, the width and height of the intersecting region are (w, h), and the area of the intersecting region is S. j and the combined area S bThe calculation formulas are formula (11) and formula (12) respectively, and the calculation formula for the intersection-union ratio (IOU) distance is formula (13).
[0123] S j =w*h (11)
[0124] S b =w1*h1+w2*h2-w*h (12)
[0125]
[0126] The value of iou ranges from [0, 1]. A larger iou value indicates a larger sample box (Bi) and an anchor box (B). a The higher the similarity between the position and shape of the boxes, the more likely they are to be detected. When the IoU value is 0, it means that the two boxes do not intersect. When the IoU value is 1, it means that the two boxes completely overlap. Generally speaking, when the IoU value is greater than or equal to 0.5, it can be determined that the detection is satisfied.
[0127] (4g-4) Construct a metric d to determine similarity, and assign the sample box (B) corresponding to the minimum value d to the sample box. i The new centroid is assigned to the new cluster centroid and replaces the original anchor box (Ba) as the new anchor box (new cluster centroid). The metric d is calculated using formula (14).
[0128] d(B i ,new centroid)=1-iou(B i B a (14)
[0129] (4g-5) Combining formula (8), calculate the total number of sample boxes for each cluster and take the average value. Then update the centroid of the cluster (to obtain new anchor boxes) and calculate the optimal recall. When the optimal recall is less than the threshold of 0.98, continue to repeat steps (4c-3)-(4c-4) until the optimal recall is equal to or greater than the threshold of 0.98 (i.e. the centroid no longer changes). At this point, the clustering ends.
[0130] (4g-6) Obtain a new anchor box (width and height values range from 0 to 1) through step (4c-5). Multiply the new anchor box result by 640 to convert it into the corresponding anchor box width and height in the 640*640 image. Save the converted anchor box size (i.e., the prior box).
[0131] 4h) RFIUT_YOLOv5x_Al pre-trained model backbone network: The hybrid domain convolutional attention mechanism (CBAM) in the pre-trained model backbone network is used to mix the feature data of the prior boxes and the ground truth boxes (manually labeled boxes) and extract the common features in the two domains, finally obtaining three feature maps of fluid inclusion images at different scales (sizes are 80*80, 40*40, and 20*20 respectively);
[0132] 4i) RFIUT_YOLOv5x_AI pre-trained model neck network: The adaptive spatial feature fusion (ASFF) method in the pre-trained model neck network is used to further extract the common features of the prior box and the ground box, improve the recognition accuracy of fluid inclusion images at different scales, and thus obtain a new three-layer adaptive spatial feature fusion layer for fluid inclusion images.
[0133] 4j) RFIUT_YOLOv5x_AI pre-trained model output: In the output, the adaptive spatial feature fusion layer of three fluid inclusion images of different sizes is used to predict the position of the bounding box (i.e., the predicted box) through the output. The predicted bounding box replaces the prior box obtained in step (4g-6) and is called the predicted box. The position loss between the predicted box and the ground box is calculated using the loss function (GIOU Loss).
[0134] 4i) Network parameter optimization: The RFIUT_YOLOv5x_AI pre-trained model uses hyperparameters such as learning rate (lr), weight decay (weight_decay), and momentum to optimize the network. The learning rate decays by 10% every 20 training rounds to gradually reduce the number of network parameter updates and accelerate the network learning speed. The momentum is set to 0.9 to reduce oscillation problems during the optimization process, thereby improving optimization efficiency.
[0135] 4j) Determine the number of iterations (epochs): When the number of iterations is less than or equal to 20, repeat step (4f-4i). When the number of iterations is greater than 20, import the validation set images to test the model's generalization ability and recognition effect, and avoid overfitting the network before stopping network training.
[0136] 4k) Calculate the validation set loss and accuracy: When the IoU value is greater than or equal to 0.5, the probability that the predicted box position is the position of the true box is obtained. Then, the highest probability is selected from the 9 anchor boxes, which is the position coordinate of the predicted box. The confidence loss and fluid inclusion image classification loss are calculated using the binary cross-entropy loss function, and the confidence threshold is set to 0.8. When the confidence value is greater than 0.8, the category is the true fluid inclusion type of the predicted box. The validation set is used to validate the model after training on the training set. The dataset is divided into training set, validation set and test set.
[0137] 4l) Save the network model and output the results: Stop network training when the loss function value of the validation set no longer shows a decreasing trend, save the current RFIUT_YOLOv5x_AI model, and output the fluid inclusion prediction box information at three different scales, including the number of grids, bounding box coordinates, confidence score and category name;
[0138] Step 5: Import the test set images into the trained model, perform intelligent recognition, localization, and annotation on the test set images, automatically read the experimental information of gas-liquid inclusions (including time and temperature), and automatically calculate the area, bubble diameter, and gas-liquid ratio of the gas-liquid inclusions. Users can judge the actual situation of the bounding box annotation based on the detected and recognized inclusion images, as follows:
[0139] 5a) Load the RFIUT_YOLOv5x_AI training model finally obtained in step (4k-4l), detect, identify, locate and label fluid inclusions in the test set images, and automatically read the gas-liquid inclusion experimental information (including time and temperature);
[0140] 5b) The experimental time, temperature, area of the gas-liquid inclusions, bubble diameter, and gas-liquid ratio are automatically calculated;
[0141] 5c) Check whether all fluid inclusions in the image are of the correct type, whether the shape and bubbles in the gas-liquid inclusions are all enclosed by bounding boxes, and whether the shape or bubble of a gas-liquid fluid inclusion is enclosed by multiple bounding boxes and whether it is completely and accurately enclosed.
[0142] Step 6: The gas-liquid inclusion homogenization temperature intelligent detection and phenotypic data analysis module automatically extracts the intelligently located gas-liquid inclusions. Then, based on the experimental time, temperature, and bubble diameter recorded in the image, homogenization temperature is identified, and the corresponding gas-liquid inclusion homogenization temperature phenotypic data file is generated, as follows:
[0143] 6a) Automatically extract the gas-liquid inclusions located in step (5) and save the gas-liquid inclusion image files separately;
[0144] 6b) Binarize each gas-liquid inclusion image, then perform contour approximation search, sort the found gas-liquid inclusion contour features, find at least one gas-liquid inclusion contour with a large area, enhance the contour, and then perform effective ellipse approximation on it.
[0145] 6c) Record the experimental time, temperature, and bubble diameter of the gas-liquid inclusions after processing in step (6b). Based on the experimental time and temperature recorded in the images, determine the phase change of the inclusions. When the bubble diameter in the image is 0 during the heating process (i.e., when the bubbles disappear in the experiment), it is determined to be a homogenization temperature. Since sometimes very small bubbles may be attached to the cavity wall of the inclusions and have not truly disappeared, it is necessary to mark the first homogenization temperature when the bubble diameter is 0 for the first time during the heating process. Then, continue to analyze the subsequent images when the bubble diameter is 0. When the bubble diameter is 0 during the second heating process, mark it as the second homogenization temperature. When the bubble diameter is 0 during the third heating process, mark it as the third homogenization temperature. Repeat this process to mark the Nth homogenization temperature until the temperature recorded in the image no longer increases, then stop the analysis. Calculate the final homogenization temperature Ta as the average temperature of N times. Finally, automatically generate the phenotypic data of the homogenization temperature of the gas-liquid inclusions (mainly the experimental time and temperature corresponding to the N homogenization temperatures, and the final average homogenization temperature Ta).
[0146] Step 7: Through the human-computer interaction module, the system visualizes the detection, localization, and recognition results of fluid inclusions. Users can modify the parameters appropriately based on their needs and the visualization results, including adjusting the minimum probability of bubble existence and the magnitude of non-maximum suppression. The system then returns to step 5 for iterative execution until the user is satisfied, achieving the following:
[0147] 7a) Based on steps (6b-6c), visualize the detection, localization, and identification results of fluid inclusions;
[0148] 7b) Users can modify the parameters as needed and based on the visualization results, appropriately modify the minimum probability of bubble target existence and the magnitude of non-maximum suppression, and return to step (5) to run iteratively until the user is satisfied.
[0149] Compared to existing technologies, this invention can automatically, accurately, and efficiently detect, identify, and analyze the homogenization temperature of fluid inclusions and gas-liquid inclusions, and automatically generate corresponding phenotypic data, greatly facilitating subsequent research. Based on deep transfer learning, this invention can accurately and quickly detect and identify the homogenization temperature of gas-liquid inclusions, eliminating the influence of human factors in traditional homogenization temperature measurement methods, reducing measurement errors, and improving work efficiency, truly achieving intelligent automatic detection and identification of the homogenization temperature of gas-liquid inclusions.
[0150] This invention also discloses a system for detecting the homogenization temperature of gas-liquid inclusions in oil and gas reservoirs, such as... Figure 3 As shown, the system includes,
[0151] The first building unit is used to conduct experiments on the homogenization temperature of fluid inclusions and to build a feature image sample set of fluid inclusions.
[0152] The second construction unit is used to extract image features from the feature image sample set and construct a network model of the fluid inclusion image sample set.
[0153] The first acquisition unit is used to pre-train the network model by combining deep transfer learning and acquire the pre-trained network model.
[0154] The second acquisition unit is used to import the images of the image sample set into the pre-trained network model for detection and analysis, and to obtain the corresponding homogeneous temperature data of the gas-liquid inclusions.
[0155] The modification unit is used to modify the parameters of the fluid inclusions according to requirements after obtaining the phenotypic data of the homogenization temperature of the fluid inclusions.
[0156] The timely solution of the present invention will be further described below with reference to specific embodiments, such as... Figure 4A-4I As shown:
[0157] 1) The detection system of this invention is used to acquire images of fluid inclusion target mutations;
[0158] 2) Identify the fluid inclusion targets to be tested, and mark and assign them numbers;
[0159] 3) Determine the outer boundary and bubble boundary targets of the fluid inclusions;
[0160] 4) Based on the target, record the uniformity issue in real time when the bubbles have completely disappeared;
[0161] 5) Record fluid inclusion property data, including gas-liquid ratio, size, etc.
[0162] As shown in Table 1, the gas-liquid inclusions numbered 1-14, with temperatures ranging from 179 to 199.9℃ and gas-liquid ratios of 5% to 10%, indicate that these inclusions formed in the same phase. Figure 4A It can be seen that when the temperature is 139℃, the target gas-liquid two-phase inclusions are numbered 1-14, which exhibit gas-liquid two-phase behavior. As the temperature increases, the bubbles gradually become smaller. Figure 4B , 4C 4D imaging shows that the bubbles in the 14 target inclusions have become significantly smaller. Figure 4E It can be seen that when the temperature reaches 179.5℃, the bubbles in inclusions 1, 3, 9, 10, 13, and 14 completely disappeared, indicating that these inclusions had reached their formation temperature at 179.5℃ and were homogeneous. According to... Figure 4F It is evident that when the temperature increases from 179.5℃ to 197.3℃, the gas-liquid ratio of the inclusions further decreases. Figure 4G It can be seen that when the temperature rises to 198.1℃, the bubbles in inclusions 7, 11, and 12 disappear and become homogeneous; Figure 4H It can be seen that when the temperature rises to 198.9, the bubbles in inclusions 2, 8, and 13 disappear, achieving homogeneity; Figure 4I It can be seen that inclusions 4, 5, and 6 are homogeneous at 199.9 degrees.
[0163] Table 1. Analysis of Homogenization Temperature Detection Data Results for Gas-Liquid Inclusions
[0164] Package number Inclusion type Gas-liquid ratio (%) Size (μm) Homogenization temperature (°C) 1 gas-liquid two-phase inclusions 5 15*15 179.5 2 gas-liquid two-phase inclusions 6 12*18 198.9 3 gas-liquid two-phase inclusions 5 7*10 179.5 4 gas-liquid two-phase inclusions 5 10*16 199.9 5 gas-liquid two-phase inclusions 7 10*10 199.9 6 gas-liquid two-phase inclusions 6 17*20 199.9 7 gas-liquid two-phase inclusions 6 8*10 198.9 8 gas-liquid two-phase inclusions 8 9*10 198.9 9 gas-liquid two-phase inclusions 5 10*10 179.5 10 gas-liquid two-phase inclusions 6 8*9 179.5 11 gas-liquid two-phase inclusions 5 11*12 198.1 12 gas-liquid two-phase inclusions 5 12*14 198.9 13 gas-liquid two-phase inclusions 5 11*13 179.5 14 gas-liquid two-phase inclusions 5 12*12 179.5
[0165] Note: The gas-liquid ratio is the volume ratio of the bubble to the liquid portion; size is the long diameter to short diameter of the inclusion; homogenization temperature is the temperature at which the gas phase disappears as the temperature increases.
[0166] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir, characterized in that, The method includes, Experiments were conducted on the homogenization temperature of fluid inclusions to construct an image sample set of fluid inclusions, wherein the image sample set was divided into a training set, a validation set, and a test set; Extracting image features from the image sample set and constructing a network model for the fluid inclusion image sample set includes: extracting overall features of the image sample set using the original network model to obtain channel attention fluid inclusion image feature maps; forming a hybrid domain fluid inclusion image feature map based on the channel attention fluid inclusion image feature map; combining the hybrid domain fluid inclusion image feature map with adaptive spatial feature fusion to obtain fusion spatial weights and constructing a primary network model for the fluid inclusion image sample set; pre-training the primary model using an open-source dataset to construct a network model for the fluid inclusion image sample set; wherein the open-source dataset includes either the COCO dataset or the VOC dataset; the original network model includes adding a hybrid domain convolutional attention mechanism to the end of the SPP layer of the backbone network of the YOLOv5 model and adding an adaptive spatial feature fusion method based on YOLOv5; wherein the YOLOv5 model includes one or more of YOLOv5s, YOLOv5m, YOLOv5l, or YOLOv5x; Image samples from the training and validation sets are imported into the network model for deep transfer learning training to obtain the trained network model. The image samples from the test set are imported into the trained network model for detection and analysis to obtain the corresponding homogenization temperature data of gas-liquid inclusions, including: The test set images are imported into the trained model; the trained network model identifies, locates, and labels the features of the test set images and automatically reads the experimental information of gas-liquid inclusions, wherein the experimental information of gas-liquid inclusions includes the experimental time and temperature of gas-liquid inclusions; the experimental information of gas-liquid inclusions is used to calculate the area size, bubble diameter and gas-liquid ratio of gas-liquid inclusions; the area size, bubble diameter and gas-liquid ratio of gas-liquid inclusions are identified to obtain the phenotypic data of the homogenization temperature of gas-liquid inclusions.
2. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 1, characterized in that, The image sample set for constructing fluid inclusions includes, A raw image sample set of fluid inclusions was constructed using an image acquisition system with hot and cold stages; The original image sample set of the acquired fluid inclusions is subjected to data augmentation processing to construct an image sample set of fluid inclusions; wherein, the data augmentation processing includes one or more of the following methods: Mosaic data augmentation, CutMix data augmentation, Mixup data augmentation, or Cutout data augmentation.
3. A method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 1 or 2, characterized in that, The image sample set is divided into a training set, a validation set, and a test set, including: The image sample set is divided into a training set, a validation set, and a test set according to a predetermined ratio; Specifically, the fluid inclusions in the training and validation sets are labeled with both the outer shape of the inclusion and the shape of the gas inside the inclusion.
4. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 1, characterized in that, Image samples from the training and validation sets are imported into the network model for deep transfer learning training to obtain the trained network model. include, The network model extracts features and trains on all image samples in the training set to obtain a primary training network model. The initial trained network model is validated and optimized using a validation set to obtain a pre-trained network model.
5. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 4, characterized in that, The network model performs feature extraction and training on all image samples in the training set to obtain a primary trained network model, including: The training set is divided into N equal parts; The network model obtains prior box size data by calculating the N subsets of the training set; The network model uses a visual attention mechanism to mix feature data from prior bounding boxes and ground truth bounding boxes and extract common features to obtain feature maps of fluid inclusions at different scales. The visual attention mechanism includes one of spatial domain attention, channel domain attention, hybrid domain convolutional attention, or parallel hybrid domain convolutional attention. The ground truth bounding boxes are obtained through manual annotation. By using an adaptive spatial feature fusion method in the network model, common features of fluid inclusion images at different scales are extracted to obtain a multi-layer adaptive spatial feature fusion layer for fluid inclusion images. The adaptive spatial feature fusion layer of the multi-layer fluid inclusion image is used to predict the position of the bounding box through the output end, and the position loss of the predicted box and the ground truth box is calculated to obtain the primary training network model.
6. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 5, characterized in that, The process of using a validation set to validate and optimize the initially trained network model includes, The position loss of the predicted bounding box and the ground truth bounding box is optimized, and network training is stopped when the loss function value of the validation dataset converges to the minimum.
7. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 1, characterized in that, The identification of the area, bubble diameter, and gas-liquid ratio of the gas-liquid inclusion includes, The located gas-liquid inclusions are automatically extracted, and the gas-liquid inclusion image files are saved separately; Each gas-liquid inclusion image is processed to obtain the gas-liquid inclusion outline image; The gas-liquid inclusion contour image was analyzed to obtain phenotypic data of the gas-liquid inclusion homogenization temperature. Among them, the gas-liquid inclusion contour image includes the experimental time, temperature, and bubble diameter at which the image was captured.
8. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 7, characterized in that, Each gas-liquid inclusion image was processed, including, Binarize each image of gas-liquid inclusions; Contour approximation is performed on the binarized gas-liquid inclusion images, and the contour features of the gas-liquid inclusions are sorted. Contour enhancement and effective ellipse approximation are applied to one or more gas-liquid inclusion contours with large areas from the sorted gas-liquid inclusion contour features.
9. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 7, characterized in that, The analysis of the gas-liquid inclusion contour image includes, Based on the experimental time and temperature recorded in the gas-liquid inclusion profile image, determine the phase change of the inclusions; When the bubbles in the gas-liquid inclusion contour image disappear during the heating process, it is determined to be a uniform temperature, wherein the bubble diameter is 0 when the bubbles disappear.
10. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 7, characterized in that, The phenotypic data of the homogenization temperature of the gas-liquid inclusions include... During the Nth heating process, when the bubble diameter is 0 N times in the gas-liquid inclusion contour image, it is marked as the Nth homogenization temperature. After marking the Nth homogenization temperature, the temperature recorded in the gas-liquid inclusion profile image no longer increases. The final homogenization temperature is calculated as the average temperature of N times, generating phenotypic data of the homogenization temperature of the gas-liquid inclusions.
11. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 10, characterized in that, The phenotypic data of the homogenization temperature of the gas-liquid inclusions include the experimental time and temperature corresponding to N homogenization temperatures, as well as the average homogenization temperature.
12. The method for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 1, characterized in that, The method also includes, After obtaining the phenotypic data of the homogenization temperature of the gas-liquid inclusions, the parameters of the fluid inclusions are modified according to the research requirements.
13. A system for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir, characterized in that, The system includes, The first construction unit is used to conduct a fluid inclusion homogenization temperature experiment and construct an image sample set of fluid inclusions, wherein the image sample set is divided into a training set, a validation set, and a test set. The second construction unit is used to extract image features from the image sample set and construct a network model for the fluid inclusion image sample set. This includes: extracting overall features of the image sample set using the original network model to obtain channel attention fluid inclusion image feature maps; forming a hybrid domain fluid inclusion image feature map based on the channel attention fluid inclusion image feature map; combining the hybrid domain fluid inclusion image feature map with adaptive spatial feature fusion to obtain fusion spatial weights and constructing a primary network model for the fluid inclusion image sample set; and pre-training the primary model using an open-source dataset to construct a network model for the fluid inclusion image sample set. The open-source dataset includes either the COCO dataset or the VOC dataset. The original network model includes adding a hybrid domain convolutional attention mechanism to the end of the SPP layer of the YOLOv5 backbone network and adding an adaptive spatial feature fusion method to YOLOv5. The YOLOv5 model includes one or more of YOLOv5s, YOLOv5m, YOLOv5l, or YOLOv5x. The first acquisition unit is used to import the image samples of the training set and the validation set into the network model for deep transfer learning training, and to acquire the trained network model. The second acquisition unit is used to import the image samples of the test set into the trained network model for detection and analysis, and to acquire the corresponding homogenization temperature data of the gas-liquid inclusions, including: The test set images are imported into the trained model; the trained network model identifies, locates, and labels the features of the test set images and automatically reads the experimental information of gas-liquid inclusions, wherein the experimental information of gas-liquid inclusions includes the experimental time and temperature of gas-liquid inclusions; the experimental information of gas-liquid inclusions is used to calculate the area size, bubble diameter and gas-liquid ratio of gas-liquid inclusions; the area size, bubble diameter and gas-liquid ratio of gas-liquid inclusions are identified to obtain the phenotypic data of the homogenization temperature of gas-liquid inclusions.
14. The system for detecting the homogenization temperature of gas-liquid inclusions in an oil and gas reservoir according to claim 13, characterized in that, The system also includes, The modification unit is used to obtain phenotypic data of the homogenization temperature of the gas-liquid inclusions and then modify the parameters of the fluid inclusions as needed.
Citation Information
Patent Citations
YOLOV5-based inclusion detection method
CN116229458A
Aero-engine blade coding dot matrix character recognition method based on deep transfer learning
CN118366170A
Weld defect detection method based on deep learning, medium, equipment and product
CN121169803A
