Construction method of gas-oil ratio prediction model and gas-oil ratio prediction method

By combining the gas component ratio and spatial location data with the Bayesian maximum entropy model, a gas-oil ratio prediction model is constructed, which solves the problems of insufficient expert experience and overfitting in the existing gas-oil ratio prediction technology, and achieves more accurate gas-oil ratio prediction and well trajectory optimization.

CN122347237APending Publication Date: 2026-07-07CHINA PETROLEUM & CHEMICAL CORP +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA PETROLEUM & CHEMICAL CORP
Filing Date
2025-01-06
Publication Date
2026-07-07

AI Technical Summary

Technical Problem

Existing technologies struggle to establish a quantitative relationship between gas and oil ratios in oil and gas fields, fail to consider expert experience, and result in overfitting and insufficient generalization capabilities, particularly leading to inaccurate predictions in small sample reservoir areas.

Method used

By employing a Bayesian maximum entropy model combined with gas component ratios and spatial location data, and training a gas-oil ratio prediction model, expert experience is considered to reduce overfitting and insufficient generalization.

Benefits of technology

It improves the accuracy and generalization ability of gas-oil ratio prediction, and can provide a basis for reservoir utilization decisions and well trajectory adjustments under complex geological environments and well conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122347237A_ABST
    Figure CN122347237A_ABST
Patent Text Reader

Abstract

The embodiment of the present application relates to the field of oil exploration and development, and discloses a construction method of a gas-oil ratio prediction model and a gas-oil ratio prediction method.The construction method comprises the following steps: calculating the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of a reference well of each sample to obtain a first ratio of the reference well of each sample; calculating the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well of each sample to obtain a second ratio of the reference well of each sample; and calculating the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of mixed hydrocarbon component of the reference well of each sample to obtain a Bernard ratio of the reference well of each sample; and training a preset Bayesian maximum entropy model by using the first ratio, the second ratio, the Bernard ratio, the sample value of the spatial position and the sample value of the gas-oil ratio of the reference well of each sample to obtain a gas-oil ratio prediction model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of petroleum exploration and development, and in particular to a method for constructing a gas-oil ratio prediction model and a method for predicting the gas-oil ratio. Background Technology

[0002] During drilling in oil and gas fields, well logging data and well logging curves provide crucial information about the reservoir from different dimensions. The gas-oil ratio, as a key parameter for distinguishing between oil and gas reservoirs, provides essential quantitative analytical basis for reservoir development decisions and wellbore trajectory adjustments. Therefore, it is necessary to establish a method for quantitatively calculating the distribution law of the gas-oil ratio using integrated well logging data.

[0003] Traditional gas logging typically only acquires parameters from C1 to C5, making it difficult to establish a quantitative relationship with the gas-oil ratio. In recent years, some scholars have proposed predicting the gas-oil ratio based on advanced mud gas, but this requires expensive equipment and is difficult to utilize existing gas logging data from mature oilfields. This paper proposes to calculate the gas-oil ratio using a data-driven model that integrates logging data.

[0004] Current methods for predicting reservoir gas-oil ratios mainly rely on empirical formulas and machine learning. However, these methods have limitations, such as the inability to consider expert experience in the prediction process and the potential for overfitting and insufficient generalization for small sample reservoir areas. Summary of the Invention

[0005] The purpose of this invention is to provide at least one method for constructing a gas-oil ratio prediction model and a method for predicting the gas-oil ratio, which can at least solve the problem of not being able to consider expert experience in the gas-oil ratio prediction process, and at least reduce the occurrence of overfitting and insufficient generalization ability.

[0006] To address the aforementioned technical problems, at least one embodiment of this application provides a method for constructing a gas-oil ratio prediction model, comprising:

[0007] The mass fraction of gas components, sample values ​​of spatial location, and sample values ​​of gas-oil ratio are obtained from several samples of reference wells; wherein the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components.

[0008] Calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of the reference well for each sample to obtain the first ratio of the reference well for each sample;

[0009] Calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well for each sample to obtain a second ratio for the reference well for each sample;

[0010] The ratio between the mass fraction of the C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component in the reference well for each sample is calculated to obtain the Bernard ratio of the reference well for each sample; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component;

[0011] The preset Bayesian maximum entropy model is trained using the first ratio, second ratio, Bernard ratio, sample value of spatial location, and sample value of gas-oil ratio of the reference wells in each sample to obtain the gas-oil ratio prediction model.

[0012] At least one embodiment of this application also provides a method for predicting the gas-oil ratio, comprising:

[0013] The gas-oil ratio prediction model is constructed by acquiring the gas composition, prior error, spatial location of the reservoir to be predicted, and the gas-oil ratio prediction model constructed by any of the above embodiments; wherein, the gas composition includes C1 hydrocarbon composition, C2 hydrocarbon composition and C3 hydrocarbon composition;

[0014] Calculate the ratio of the mass fractions of C1 hydrocarbon components and C2 hydrocarbon components in the reservoir to be predicted to obtain the first ratio of the reservoir to be predicted;

[0015] Calculate the ratio of the mass fractions of C1 hydrocarbon components and C3 hydrocarbon components in the reservoir to be predicted to obtain the second ratio of the reservoir to be predicted;

[0016] The Bernard ratio of the C1 hydrocarbon component and the mixed hydrocarbon component of the reservoir to be predicted is calculated to obtain the Bernard ratio of the reservoir to be predicted; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component;

[0017] Based on the gas-oil ratio prediction model, the gas-oil ratio of the reservoir to be predicted is calculated according to the spatial location of the reservoir to be predicted, the first ratio, the second ratio, and the Bernard ratio.

[0018] At least one embodiment of this application also provides an apparatus for constructing a gas-oil ratio prediction model, comprising:

[0019] The sample acquisition module is used to acquire the mass fraction of gas components, the sample value of spatial location, and the sample value of gas-oil ratio of several samples from a reference well; wherein the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components.

[0020] The first ratio module is used to calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of the reference well in each sample, so as to obtain the first ratio of the reference well in each sample.

[0021] The second ratio module is used to calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well for each sample, so as to obtain the second ratio of the reference well for each sample.

[0022] The Bernard ratio module is used to calculate the ratio between the mass fraction of the C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component of the reference well for each sample, so as to obtain the Bernard ratio of the reference well for each sample; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component;

[0023] The model training module is used to train a preset Bayesian maximum entropy model using the first ratio, second ratio, Bernard ratio, sample value of spatial location, and sample value of gas-oil ratio of the reference wells in each sample, so as to obtain a gas-oil ratio prediction model.

[0024] At least one embodiment of this application also provides an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the above-described method for constructing a gas-oil ratio prediction model or a method for predicting a gas-oil ratio.

[0025] At least one embodiment of this application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described method for constructing a gas-oil ratio prediction model or a method for predicting the gas-oil ratio.

[0026] The gas-oil ratio prediction model construction method or gas-oil ratio prediction method provided in the embodiments of this application obtains the mass fraction of gas components, sample values ​​of spatial location, and sample values ​​of gas-oil ratio of several samples of reference wells; wherein, the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components; calculates the ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of C2 hydrocarbon components of each sample of reference wells to obtain the first ratio of each sample of reference wells; calculates the ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of C3 hydrocarbon components of each sample of reference wells to obtain the second ratio of each sample of reference wells; calculates the ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of mixed hydrocarbon components of each sample of reference wells to obtain the Bernard ratio of each sample of reference wells; wherein, the mixed hydrocarbon components include C2 hydrocarbon components and C3 hydrocarbon components; and trains a preset Bayesian maximum entropy model using the first ratio, second ratio, Bernard ratio, sample values ​​of spatial location, and sample values ​​of gas-oil ratio of each sample of reference wells to obtain the gas-oil ratio prediction model. Therefore, the gas-oil ratio prediction model trained by the pre-set Bayesian maximum entropy model can take into account the expert experience in the gas-oil ratio prediction process, reducing the probability of overfitting and generalization problems. Attached Figure Description

[0027] One or more embodiments are illustrated by way of example with reference to the accompanying drawings, and these illustrative descriptions do not constitute a limitation on the embodiments.

[0028] Figure 1 This is a flowchart of a method for constructing a gas-oil ratio prediction model according to an embodiment of this application;

[0029] Figure 2 A flowchart for a method to predict the gas-oil ratio in a well drilling area;

[0030] Figure 3 This is a partial sample set;

[0031] Figure 4a This is a graph showing the relationship between the gas-oil ratio and component ratio of a reservoir calculated using this method for a certain well.

[0032] Figure 4b This is a graph showing the relationship between the gas-oil ratio and component ratio of a reservoir calculated using this method for a certain well.

[0033] Figure 5 Flowchart of the reservoir gas-oil ratio calculation model;

[0034] Figure 6 Comparison of gas-oil ratio prediction accuracy (component ratio and component + Bernard coefficient);

[0035] Figure 7 Comparison of eye trajectory correction results for a certain well based on this method. Detailed Implementation

[0036] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the various embodiments of this application will be described in detail below with reference to the accompanying drawings. However, those skilled in the art will understand that many technical details have been provided in the various embodiments of this application to help readers better understand this application. However, the technical solutions claimed in this application can be implemented even without these technical details and various changes and modifications based on the following embodiments. The division of the various embodiments below is for the convenience of description and should not constitute any limitation on the specific implementation of this application. The various embodiments can be combined with and referenced by each other without contradiction.

[0037] To facilitate understanding of the embodiments of this application, the relevant content regarding the prediction of the gas-oil ratio will be introduced first.

[0038] During drilling in oil and gas fields, well logging data and well logging curves provide crucial information about the reservoir from different dimensions. The gas-oil ratio, as a key parameter for distinguishing between oil and gas reservoirs, provides essential quantitative analytical basis for reservoir development decisions and wellbore trajectory adjustments. Therefore, it is necessary to establish a method for quantitatively calculating the distribution law of the gas-oil ratio using integrated well logging data.

[0039] Traditional gas logging typically only acquires parameters from C1 to C5, making it difficult to establish a quantitative relationship with the gas-oil ratio. In recent years, some scholars have proposed predicting the gas-oil ratio based on advanced mud gas, but this requires expensive equipment and is difficult to utilize existing gas logging data from mature oilfields. This paper proposes to calculate the gas-oil ratio using a data-driven model that integrates logging data.

[0040] Due to the influence of numerous geological factors, the gas-oil ratio, as an important basis for determining the oil content of reservoirs, has not yet been widely used to guide the optimization of drilling targets and wellbore trajectories. However, during field drilling, due to cost constraints, it is impossible to obtain total hydrocarbon content data for all adjacent well areas and the well itself, thus making it impossible to accurately determine the gas-oil ratio of the reservoir.

[0041] Common methods for predicting formation gas-oil ratios based on total hydrocarbon data often involve fitting empirical formulas, spatial interpolation, or using machine learning. However, these methods struggle to coordinate different types of parameters to accurately predict the formation gas-oil ratio. For deep and ultra-deep wells with complex lithological formations, the variations in parameters such as temperature and pressure within the same well section are complex, making it even more difficult to predict the formation gas-oil ratio for both the sections to be drilled and those currently being drilled using empirical formulas and spatial interpolation.

[0042] To address the aforementioned technical problem of failing to consider expert experience in the gas-oil ratio prediction process, this invention proposes a method for constructing a gas-oil ratio prediction model and a method for predicting the gas-oil ratio. The implementation details of the method for constructing the gas-oil ratio prediction model and the method for predicting the gas-oil ratio in this embodiment are described below. The following implementation details are provided for ease of understanding and are not essential for implementing this solution.

[0043] Example 1:

[0044] The method for constructing the gas-oil ratio prediction model in this embodiment can be applied to electronic devices with communication, computing, and data storage capabilities. The specific process can be as follows: Figure 1 As shown, it includes:

[0045] Step 110: Obtain the mass fraction of gas components, sample values ​​of spatial location, and sample values ​​of gas-oil ratio of several samples from the reference well; wherein the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components.

[0046] Specifically, the gas components include at least C1, C2, and C3 hydrocarbon components, and C4 and C5 hydrocarbon components can also be used as training indicators. Multiple reference wells are used; for each reference well, sample values ​​of the mass fractions of C1, C2, and C3 hydrocarbon components and the gas-oil ratio are collected at different locations to obtain different samples.

[0047] Step 120: Calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of the reference well for each sample, to obtain the first ratio of the reference well for each sample.

[0048] Specifically, for each sample, the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component in the reference well for that sample is calculated to obtain the first ratio for that sample. The first ratio, in conjunction with the relationship between C1 and C2 hydrocarbon components, comprehensively considers the effect of the synergistic relationship between C1 and C2 hydrocarbon components on the gas-oil ratio.

[0049] Step 130: Calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well for each sample, to obtain a second ratio for the reference well for each sample.

[0050] Specifically, for each sample, the ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of C3 hydrocarbon components in the reference well for that sample is calculated to obtain the second ratio for that sample. The second ratio considers the relationship between C1 and C3 hydrocarbon components, comprehensively taking into account the effect of the synergistic relationship between C1 and C3 hydrocarbon components on the gas-oil ratio.

[0051] Step 140: Calculate the ratio between the mass fraction of the C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component of the reference well for each sample to obtain the Bernard ratio of the reference well for each sample; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component.

[0052] Specifically, C2 and C3 hydrocarbon components are considered together as a mixed hydrocarbon component. The sum of the mass fractions of C2 and C3 hydrocarbon components is calculated to obtain the mass fraction of the mixed hydrocarbon component. For each sample, the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component in the reference well for that sample is calculated to obtain the third ratio for that sample. The third ratio, considering the relationship between C1 hydrocarbon component and the mixed hydrocarbon component, comprehensively accounts for the effect of the synergistic relationship between C1 hydrocarbon component and the mixed hydrocarbon component on the gas-oil ratio.

[0053] Step 150: Use the first ratio, second ratio, Bernard ratio, sample value of spatial location, and sample value of gas-oil ratio of the reference wells of each sample to train the preset Bayesian maximum entropy model to obtain the gas-oil ratio prediction model.

[0054] Specifically, during the training process of the pre-defined Bayesian maximum entropy model, expert experience can be considered to reduce the probability of overfitting and generalization problems.

[0055] The method for constructing the gas-oil ratio prediction model in this embodiment involves obtaining the mass fraction of gas components, sample values ​​of spatial location, and sample values ​​of gas-oil ratio for several samples of reference wells. The gas components include C1, C2, and C3 hydrocarbon components. The ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of C2 hydrocarbon components in each sample of the reference well is calculated to obtain the first ratio for each sample of the reference well. The ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of C3 hydrocarbon components in each sample of the reference well is calculated to obtain the second ratio for each sample of the reference well. The ratio between the mass fraction of C1 hydrocarbon components and the mass fraction of mixed hydrocarbon components in each sample of the reference well is calculated to obtain the Bernard ratio for each sample of the reference well. The mixed hydrocarbon components include C2 and C3 hydrocarbon components. The first ratio, second ratio, Bernard ratio, sample values ​​of spatial location, and sample values ​​of gas-oil ratio for each sample of the reference well are used to train a preset Bayesian maximum entropy model to obtain the gas-oil ratio prediction model. Therefore, the gas-oil ratio prediction model trained by the pre-set Bayesian maximum entropy model can take into account the expert experience in the gas-oil ratio prediction process, reducing the probability of overfitting and generalization problems.

[0056] In some embodiments, the step of training a preset Bayesian maximum entropy model using the first ratio, second ratio, Bernard ratio, sample values ​​of spatial location, and sample values ​​of gas-oil ratio of each of the samples to obtain a gas-oil ratio prediction model includes:

[0057] Using the first ratio, second ratio, Bernard ratio, and gas-oil ratio of the reference wells for each sample, a preset random forest model is trained to obtain a random forest prediction model;

[0058] Calculate the error between the sample value and the predicted value of the gas-oil ratio in the random forest prediction model to obtain the error statistical distribution of each sample;

[0059] The preset Bayesian maximum entropy model is trained using the first ratio, second ratio, Bernard ratio, sample value of spatial location, sample value of gas-oil ratio, and the error statistical distribution of each sample to obtain the gas-oil ratio prediction model.

[0060] In these embodiments, a preset random forest model is first trained using a first ratio, a second ratio, a Bernard ratio, and a gas-oil ratio. The training formula for the preset random forest model is shown below:

[0061] GOR=RF(C1 / C2,C1 / C3,Bernard ratio)

[0062] In the formula, C1 / C2 represents the first ratio; C1 / C3 represents the second ratio; Bernard ratio represents the Bernard ratio; RF represents the random forest prediction model; and GOR represents the gas-oil ratio. After training, for each sample, the error between the sample value and the predicted value of the gas-oil ratio in the random forest prediction model is calculated to obtain the error statistical distribution of each sample. The error statistical distribution is then used as soft data input to a preset Bayesian maximum entropy model for training, thereby improving the prediction accuracy of the gas-oil ratio prediction model.

[0063] In some embodiments, the preset Bayesian maximum entropy model is shown in the following equation:

[0064] GOR=BME(MSE(RF(C1 / C2,C1 / C3,Bernald ratio),GOR),C1 / C2,C1 / C3,Bernardratio,x,y,z)

[0065] In the formula, C1 / C2 represents the first ratio, C1 / C3 represents the second ratio, Bernard ratio represents the Bernard ratio, RF represents the random forest prediction model, MSE(RF(C1 / C2,C1 / C3,Bernald ratio),GOR) represents the error statistical distribution, GOR represents the gas-oil ratio, and x, y, z represent the x, y, z coordinates of the spatial location in the Cartesian coordinate system.

[0066] In these embodiments, the first ratio C1 / C2, the second ratio C1 / C3, the Bernard ratio, the spatial location, and the error distribution are input into a preset Bayesian maximum entropy model for training, and spatial interpolation is performed to determine the parameters in the gas-oil ratio prediction model.

[0067] In some embodiments, the step of obtaining sample values ​​of gas component mass fraction, spatial location, and gas-oil ratio from several samples of a reference well includes:

[0068] The measured component ratio of the gas component in several samples from the water-based drilling is obtained as the mass fraction of the gas component. The sample values ​​of the spatial location and the sample values ​​of the gas-oil ratio of several samples from the water-based drilling are also obtained.

[0069] The measured component ratios of the gas components in several samples from oil-based wells are obtained, and the measured component ratios of the gas components in the oil-based wells are reduced to obtain the mass fraction of the gas components in the oil-based wells; the sample values ​​of the spatial location and the sample values ​​of the gas-oil ratio of several samples from the oil-based wells are obtained; wherein, the reference wells include the water-based wells and the oil-based wells.

[0070] In these embodiments, before training the preset Bayesian maximum entropy model, the mass fraction of gas components from the reference well is differentiated. For samples collected from water-based wells, the measured component ratio of gas components, i.e., the actual mass percentage collected, is directly used as the mass fraction of gas components in the training model. Since water-based wells do not have oil and gas interference samples during drilling, the measured component ratio of the collected gas components is directly used as the mass fraction of gas components in the reference well, improving training speed. For samples collected from oil-based wells, the measured component ratio of gas components, i.e., the actual mass percentage collected, is reduced, for example, by multiplying the measured component ratio of gas components by a preset reduction coefficient, where the preset reduction coefficient is greater than 0 and less than 1. The product is used as the mass fraction of gas components in oil-based wells, making the mass fraction of gas components in oil-based wells more accurately reflect the actual situation and improving the prediction accuracy of the gas-oil ratio prediction model.

[0071] In some embodiments, the sample values ​​of the spatial location include sample values ​​of well coordinates and / or sample values ​​of well trajectory.

[0072] In these embodiments, spatial location can be characterized using well coordinates and well trajectory, exploring the influence of well coordinates and well trajectory on the gas-oil ratio, and improving the prediction accuracy of the gas-oil ratio prediction model.

[0073] In one embodiment, if a more advanced mud gas collection device is used, such as one capable of collecting the mass fractions of C4 and C5 hydrocarbon components, then the ratio between the mass fractions of C1 and C4 hydrocarbon components (C1 / C4), the ratio between the mass fractions of C1 and C5 hydrocarbon components (C1 / C5), and the ratio between the mass fraction of C3 hydrocarbon components and the mass fraction of the combined hydrocarbon components (C3 / (C4+C5)) of each sample of the reference well can also be calculated. In this process, C4 and C5 hydrocarbon components are considered together as a combined hydrocarbon component. The sum of the mass fractions of C4 and C5 hydrocarbon components is calculated to obtain the mass fraction of the combined hydrocarbon component. The ratios between the mass fractions of C1 and C4 hydrocarbon components (C1 / C4), C1 / C5 between the mass fractions of C1 and C5 hydrocarbon components, C3 / (C4+C5) between the mass fraction of C3 hydrocarbon component and the mass fraction of the combined hydrocarbon component, the first ratio (C1 / C2), the second ratio (C1 / C3), the Bernard ratio, and the spatial location are input into a preset Bayesian maximum entropy model for training. Alternatively, the error distribution can be input into a preset Bayesian maximum entropy model for training to determine the parameters in the gas-oil ratio prediction model, thereby improving the accuracy of the gas-oil ratio prediction model.

[0074] Example 2:

[0075] The method for constructing the gas-oil ratio prediction model in this embodiment can be applied to electronic devices with communication, computing, and data storage capabilities. The specific process can be as follows: Figure 2 As shown, it includes:

[0076] (1) Data correction method for standard mud gas.

[0077] For water-based mud systems, no correction factor is required; for oil-based mud systems, a correction factor representing the relationship between crude oil PVT components and mud gas components needs to be added.

[0078] (2) Based on the existing data, establish a correlation analysis matrix.

[0079] Data sets were established for adjacent well locations, well trajectories, crude oil PVT component data, mud gas component data, and reservoir gas-oil ratio. Correlation analysis was performed on the datasets using the Pearson or Spearman method, and a correlation analysis matrix was established. The Random Forest (RF) method was used to estimate the model's gas-oil ratio prediction error, constructing soft data. The soft data included: statistical distribution intervals for each component of the crude oil PVT data, statistical distribution intervals for the mud gas component data, and statistical distribution intervals for the reservoir gas-oil ratio data.

[0080] (3) Create a training dataset.

[0081] Based on steps (1) and (2), a dataset based on reservoir gas-oil ratio prediction is established. All features are divided into a validation set, a test set, and a test set to construct a training dataset. A partial sample set is shown in Table 1.

[0082] Table 1 Partial Sample Set

[0083]

[0084]

[0085] (4) Establish a reservoir gas-oil ratio prediction model using the Bayesian maximum entropy method.

[0086] A Bayesian maximum entropy model is established, which uses well location coordinates, wellbore trajectory, crude oil PVT component data, and mud gas component data as well as the statistical functions and parameter values ​​of crude oil PVT component data and mud gas component data as soft data of specific knowledge, and the experts' understanding of the regional crude oil characteristics as empirical judgment knowledge. These are all input into the Bayesian maximum entropy model for the prediction of reservoir gas-oil ratio.

[0087] (5) Real-time prediction of gas-oil ratio.

[0088] Based on real-time gas logging data, the proportion of crude oil components (C1-C3) in standard mud gas is obtained. The mud gas component ratio is used as hard data for specific knowledge, and a trained Bayesian maximum entropy model is used to predict the gas-oil ratio of the reservoir where the well is located.

[0089] (6) Wellbore trajectory adjustment.

[0090] Based on the predicted gas-oil ratio of the oil-bearing layers, the type of oil and gas reservoir is determined, and the wellbore trajectory is adjusted to control drilling risks. At the same time, the contact area between the wellbore and the oil reservoir is increased to improve the post-drilling development efficiency of the oil well.

[0091] The specific steps are as follows:

[0092] like Figure 2As shown, a method for interpolating the reservoir gas-oil ratio includes the following steps:

[0093] (1) Data collection and processing of oil and gas PVT sample composition and gas-oil ratio

[0094] See Figure 3 We collected PVT sample composition and gas-oil ratio data from drilled wells. The PVT data mainly included the percentage of C1 to C7 components in the crude oil, and the corresponding volume ratio of dissolved gas to degassed crude oil under standard atmospheric conditions.

[0095] (2) Calculate the reservoir gas-oil ratio.

[0096] As shown in Figure 4 and Figure 5As shown, the gas-oil ratio of an oil reservoir is determined based on three sets of parameters: C1 / C2, C1 / C3, and the Bernard ratio. The Bernard ratio refers to the ratio of light components to total hydrocarbon components in the reservoir. C1 to C7 are light components, mud gas contains C1 to C7 hydrocarbon components, and the total hydrocarbons in the reservoir include C1 to C7 as well as C7+ liquid components. Different correction coefficients are added based on the specific reservoir prediction to improve the accuracy of the gas-oil ratio prediction. No correction coefficient is needed for water-based drilling fluids; however, for oil-based drilling fluids, a correction coefficient is required to correct for the light components in the crude oil. While water-based drilling fluids do not inject additional oil components into the reservoir, oil-based drilling fluids are equivalent to injecting additional oil components. When measuring mud gas, it is very likely that the injected oil components are present, and this interference needs to be removed. The correction coefficients can be obtained from coefficients trained on models from other wells. The definition is to multiply the measured C1 to C7 values ​​by a weighting factor. If oil-based drilling fluid is used, the measured gas composition during drilling will be higher, and the predicted gas-oil ratio will also be higher, so the correction factor is less than 1. The purpose of this treatment is to eliminate the interference from additional oil added to the drilling fluid. Furthermore, if a more advanced mud gas collection device is used, such as one that can collect the mass fractions of C4 and C5 hydrocarbon components, the ratios between the mass fractions of C1 and C4 hydrocarbon components (C1 / C4), C1 and C5 hydrocarbon components (C1 / C5), and C3 and (C3 / (C4+C5)) of the reference well can be calculated for each sample. Here, the C4 and C5 hydrocarbon components are considered together as a combined hydrocarbon group. The mass fraction of the combined hydrocarbon component is obtained by calculating the sum of the mass fractions of C4 and C5 hydrocarbon components. The ratios C1 / C4 (C1 to C4), C1 / C5 (C1 to C5), C3 / (C3+C5) (C3 to C3 and combined hydrocarbon components), the first ratio C1 / C2, the second ratio C1 / C3, and the Bernard ratio are input into a preset Bayesian maximum entropy model for training, thereby obtaining a gas-oil ratio prediction model to improve the accuracy of the gas-oil ratio prediction model.

[0097] (3) Construct a sample set.

[0098] Based on the statistical results of PVT crude oil composition from the laboratory and drilling site, training, testing and validation sets were constructed according to the proportions of 70%, 20% and 10%.

[0099] (4) Prediction of reservoir gas-oil ratio based on Bayesian maximum model.

[0100] like Figure 6 As shown, a Bayesian maximum entropy model is established. The parameters input to the model include the statistical intervals of PVT crude oil composition and reservoir gas-oil ratio within the region related to hard and soft data, as well as the estimation error obtained by the random forest (RF) method. The input data are well coordinates, well trajectory, and hard data parameters such as the light crude oil component ratios C1 / C2, C1 / C3, and Bernard ratio. The output parameter is the gas-oil ratio. First, the error of the model trained on different samples is calculated using random forest, and this error is treated as soft data (which can be the error distribution range). Then, it is imported into the Bayesian maximum entropy model to train it. The gas component data refers to the mass fractions of components C1 to C7. These two are used as input parameters. The Bayesian maximum entropy method is a spatial interpolation method, so coordinate data (i.e., well location coordinates and well trajectory) are needed as training parameters to predict the reservoir gas-oil ratio at other well locations and well trajectory positions. The trained random forest model, based on training data (oil composition and gas-oil ratio), determines the error in predicting the actual gas-oil ratio, and obtains the statistical distribution of this error. This statistical distribution of error is then used as soft data input into the Bayesian maximum entropy model. When the model is applied, it needs to be input with the error, which is the prior prediction error obtained by the random forest based on data from other wells.

[0101] In this embodiment, the spatial location is composed of three location variables (x, y, z), the component ratio is composed of three sets of variables (C1 / C2, C1 / C3, Bernard coefficient), and the error distribution (mean variance MSE) is predicted by the random forest as the gas-oil ratio, i.e., whether it is an oil reservoir or a gas reservoir, without considering the spatial distribution.

[0102] GOR=RF(C1 / C2,C1 / C3,Bernard ratio)

[0103] Where C1 / C2 represents C1 component / C2 component; C1 / C3 represents C1 component / C3 component; Bernald ratio represents C1 component / (C2+C3) component; RF represents random forest algorithm; GOR represents gas-oil ratio; x,y,z represent x,y,z coordinates in Cartesian coordinate system.

[0104] The random forest model is fed with component ratios consisting of three sets of variables (C1 / C2, C1 / C3, and the Bernard coefficient), and the predicted value is the gas-oil ratio, which determines whether a reservoir is oil or gas. During the training process of spatial interpolation, the prediction error of the random forest is fed into a Bayesian maximum entropy model, and the spatial location (x, y, z) is assigned as a data label to each component ratio to predict the spatial distribution of the gas-oil ratio.

[0105] In this embodiment, the Bayesian maximum entropy model is:

[0106] GOR=BME(MSE(RF(C1 / C2,C1 / C3,Bernald ratio),GOR),C1 / C2,C1 / C3,Bernardratio,x,y,z)

[0107] Where C1 / C2 represents C1 component / C2 component; C1 / C3 represents C1 component / C3 component; Bernald ratio represents C1 component / (C2+C3) component; RF represents random forest algorithm; GOR represents gas-oil ratio; x,y,z represent x,y,z coordinates in Cartesian coordinate system.

[0108] (5) Well trajectory adjustment based on predicted oil-gas ratio.

[0109] like Figure 7 As shown, based on the Bayesian maximum entropy model, the high-temperature and high-pressure PVT properties of crude oil (crude oil density is 0.87) were calculated according to the mud gas component ratio (C7+), and the mud gas component ratio (C1~C6 ratio is 4:2:2:2:1:2). The gas-oil ratio of the reservoir was predicted. After entering the reservoir, the upper gas logging results showed that the reservoir was 80% oil-bearing and 20% gas-bearing. Therefore, based on the existing oil and gas shows, the drilling trajectory was corrected. Perforation was not performed at the gas layer location. Instead, the wellbore trajectory was extended and the wellbore trajectory angle was adjusted to reach the oil layer location. Based on the real-time gas logging component information, the gas-oil ratio of the reservoir was predicted to be 2:8, and perforation was performed at the oil layer location based on the prediction. During drilling, if both oil and gas reservoirs are encountered, the oil reservoir is generally exploited first to achieve the highest crude oil recovery rate. Therefore, it is necessary to avoid the gas layer and exploit the oil layer first. This method allows for the avoidance of gas-bearing reservoirs when they are predicted, adjusting the drilling trajectory to ensure the wellbore reaches the oil-bearing reservoir first. Real-time mud gas composition data is available and needs to be incorporated into the Bayesian maximum entropy model to correct the model previously trained using data from other wells. The input data is identical to that of other wells. After determining the reservoir's oil-gas ratio, when the gas volume fraction / mass fraction reaches the gas-bearing reservoir criterion (e.g., 50% or even 100% or higher), it is considered a likely gas-bearing reservoir, requiring adjustments to the wellbore trajectory to avoid the gas reservoir. This necessitates adjusting the drilling depth and horizontal position, which in turn requires adjusting the perforation height laterally.

[0110] This embodiment pertains to the algorithm flow for predicting the reservoir gas-oil ratio. The invention relates to the Bayesian maximum entropy spatial interpolation algorithm, data governance methods for crude oil component preprocessing, and methods for predicting the reservoir gas-oil ratio. Bayesian maximum entropy is a modern geostatistical method that can integrate data of varying precision and quality from multiple methods when conducting spatial distribution studies, without requiring the original data to follow a Gaussian distribution. In the data processing, the data is mainly divided into hard data and soft data relevant to the study area, as well as expert knowledge and statistical regularities. Current methods for predicting reservoir gas-oil ratios primarily employ fitted empirical formulas and machine learning methods. Their limitations lie in their inability to consider expert experience in the prediction process, and the potential for overfitting and insufficient generalization for small sample reservoir areas. Bayesian maximum entropy can address these issues. Furthermore, the Bayesian maximum entropy method has not yet been applied to the spatial distribution prediction of reservoir gas-oil ratios.

[0111] This embodiment applies to complex geological environments (deep, ultra-deep, and shale oil and gas) and wellbore conditions (directional and horizontal wells). It describes a method for predicting the reservoir gas-oil ratio, ultimately providing a basis for increasing reservoir recoverable reserves and adjusting wellbore trajectories. During drilling, this method, applicable to complex geological environments (deep, ultra-deep, and shale oil and gas) and wellbore conditions (directional and horizontal wells), predicts the reservoir gas-oil ratio, ultimately providing a basis for increasing reservoir recoverable reserves and adjusting wellbore trajectories. This method of predicting the reservoir gas-oil ratio during drilling falls within the field of petroleum exploration and development. It can provide a basis for predicting the gas-oil ratio of the well to be drilled and can also provide guidance for optimizing and adjusting the drilling trajectory based on the predicted gas-oil ratio.

[0112] In this embodiment, the process involves four steps: data correction of light crude oil components, correlation analysis of crude oil PVT component data, mud gas component data, and reservoir gas-oil ratio data; prediction of the gas-oil ratio distribution in the reservoir using standard mud gas gas component data and a Bayesian maximum entropy model; and adjustment of the drilling trajectory to reach the target oil or gas layer. A response relationship between standard mud gas (light components below C7) and the reservoir gas-oil ratio was established. For the proportion of heavy components above C7, the equation of state (EOS) was used to calculate the crude oil density. By integrating logging data from the drilling process, the accuracy of gas-oil ratio prediction during drilling in deep and ultra-deep reservoirs was improved.

[0113] In this embodiment, the method for predicting the gas-oil ratio of the reservoir during drilling preprocesses standard mud gas data, considers the statistical response relationship between different parameters, and establishes a reservoir gas-oil ratio calculation model based on the Bayesian maximum entropy algorithm. Compared with traditional linear interpolation, inverse distance interpolation, and kriging interpolation methods, the Bayesian maximum entropy model has the advantages of strong computational robustness and high computational accuracy because it considers the statistical functions and parameters of soft data. By employing methods such as random forest (RF) to obtain the error of the prediction results, the existing data is constructed into soft data, further improving the ability of the Bayesian maximum entropy model to predict the gas-oil ratio. Compared with machine learning algorithms, the Bayesian maximum entropy model has the characteristics of strong interpretability while maintaining prediction accuracy. Using a data-based model based on existing standard mud gas data to predict the reservoir gas-oil ratio during drilling can provide a basis for increasing reservoir utilization and adjusting wellbore trajectory based on this, thereby improving drilling economic efficiency, while ensuring prediction interpretability.

[0114] This embodiment belongs to the field of petroleum exploration and development, and is used to guide the design and optimization of drilling engineering parameters and well trajectories. The invention includes: data collection and data processing; using crude oil PVT component data to calculate the gas-oil ratio; and establishing a gas-oil ratio prediction model using the Bayesian maximum entropy algorithm. It establishes the response relationship between standard mud gas data and reservoir gas-oil ratio, solving the problem of being unable to determine the reservoir gas-oil ratio due to inaccurate weights of various components in standard mud gas. For drilling processes using oil-based mud, a correction coefficient is specifically added, expanding the applicability of the method and providing a scientific basis for improving reservoir encounter rates and adjusting drilling trajectories during the drilling process. Bayesian maximum entropy is a modern geostatistical method that can integrate data of different precision and quality from multiple methods when conducting spatial distribution studies, without requiring the original data to follow a Gaussian distribution. In the data processing, the data is mainly divided into hard data and soft data related to the study area, as well as expert knowledge and statistical regularities. Currently, formation parameter interpolation mainly uses Kriging interpolation and its improved methods. This paper proposes to predict the gas-oil ratio of reservoirs using conventional gas logging data and the Bayesian maximum entropy method.

[0115] Example 3:

[0116] The gas-oil ratio prediction method of this embodiment can be applied to electronic devices with communication, computing, and data storage capabilities. Its specific process includes:

[0117] The gas composition, prior error, spatial location of the reservoir to be predicted, and the gas-oil ratio prediction model constructed by the construction method of the gas-oil ratio prediction model described in any of the above embodiments are obtained; wherein, the gas composition includes C1 hydrocarbon composition, C2 hydrocarbon composition and C3 hydrocarbon composition;

[0118] Calculate the ratio of the mass fractions of C1 hydrocarbon components and C2 hydrocarbon components in the reservoir to be predicted to obtain the first ratio of the reservoir to be predicted;

[0119] Calculate the ratio of the mass fractions of C1 hydrocarbon components and C3 hydrocarbon components in the reservoir to be predicted to obtain the second ratio of the reservoir to be predicted;

[0120] The Bernard ratio of the C1 hydrocarbon component and the mixed hydrocarbon component of the reservoir to be predicted is calculated to obtain the Bernard ratio of the reservoir to be predicted; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component;

[0121] Based on the gas-oil ratio prediction model, the gas-oil ratio of the reservoir to be predicted is calculated according to the spatial location of the reservoir to be predicted, the first ratio, the second ratio, and the Bernard ratio.

[0122] In this embodiment, the reservoir to be predicted is the reservoir for which the gas-oil ratio needs to be predicted. The gas composition, prior error, and spatial location of wells in the region of the reservoir to be predicted can be obtained. The gas composition includes C1, C2, and C3 hydrocarbon components. The prior error is the prediction error of the gas-oil ratio in the random forest prediction model, which can be represented by the prediction error of wells in the region of the reservoir to be predicted. The ratio of the mass fraction of C1 hydrocarbon component to the mass fraction of C2 hydrocarbon component in the reservoir to be predicted is calculated to obtain the first ratio of the reservoir to be predicted. The ratio of the mass fraction of C1 hydrocarbon component to the mass fraction of C3 hydrocarbon component in the reservoir to be predicted is calculated to obtain the second ratio of the reservoir to be predicted. The sum of the mass fractions of C2 hydrocarbon component and C3 hydrocarbon component is calculated to obtain the mass fraction of the mixed hydrocarbon component in the reservoir to be predicted. The ratio of the mass fraction of C1 hydrocarbon component to the mass fraction of the mixed hydrocarbon component is calculated to obtain the Bernard ratio of the reservoir to be predicted. The spatial location of the reservoir to be predicted, the first ratio, the second ratio, and the Bernard ratio are input into the gas-oil ratio prediction model to calculate the gas-oil ratio of the reservoir. If the gas-oil ratio prediction model also uses the mass fractions of C4 and C5 hydrocarbon components for training, the mass fractions of C4 and C5 hydrocarbon components of the reservoir to be predicted can also be collected and input into the gas-oil ratio prediction model for training to improve prediction accuracy.

[0123] In this embodiment, the following ratios are also calculated: the ratio between the mass fractions of C1 and C4 hydrocarbon components in the reservoir to be predicted (C1 / C4); the ratio between the mass fractions of C1 and C5 hydrocarbon components in the reservoir to be predicted (C1 / C5); and the ratio between the mass fraction of C3 hydrocarbon components and the mass fraction of the combined hydrocarbon components in the reservoir to be predicted (C3 / (C4+C5)). Specifically, C4 and C5 hydrocarbon components are considered together as a combined hydrocarbon component. The sum of the mass fractions of C4 and C5 hydrocarbon components is calculated to obtain the mass fraction of the combined hydrocarbon component. The ratios C1 / C4, C1 / C5, C3 / (C4+C5), C1 / C2, C1 / C3, and Bernard ratio are also considered. The gas-oil ratio prediction model can be used to predict the gas-oil ratio by inputting the ratio and spatial location, or by inputting the error distribution into the gas-oil ratio prediction model to calculate the gas-oil ratio of the reservoir to be predicted.

[0124] In one embodiment, the prediction method further includes:

[0125] When the gas-oil ratio of the reservoir to be predicted is greater than or equal to a preset adjustment threshold, the wellbore trajectory is extended and / or the wellbore trajectory angle is adjusted.

[0126] In this embodiment, to optimize the drilling path of the reservoir to be predicted, a preset adjustment threshold is used to distinguish between oil and gas layers. When the gas-oil ratio of the reservoir to be predicted is greater than or equal to the preset adjustment threshold, it is indicated that the reservoir is a gas layer; when the gas-oil ratio is less than the preset adjustment threshold, it is indicated that the reservoir is an oil layer. During extraction, the oil layer is extracted first, followed by the gas layer, to achieve the highest oil recovery rate. When the gas-oil ratio of the reservoir to be predicted is greater than or equal to the preset adjustment threshold, the location is considered a gas layer. The wellbore trajectory is adjusted and extended, and / or the wellbore trajectory angle is adjusted, so that drilling avoids the gas layer and approaches the oil layer, ensuring that the wellbore reaches the oil layer first.

[0127] Example 4:

[0128] Another embodiment of this application relates to a device for constructing a gas-oil ratio prediction model. The implementation details of the device for constructing a gas-oil ratio prediction model in this embodiment are described in detail below. The following implementation details are provided for ease of understanding and are not necessary for implementing this solution. The device for constructing a gas-oil ratio prediction model in this embodiment includes a sample acquisition module, a first ratio module, a second ratio module, a Bernard ratio module, and a model training module.

[0129] The sample acquisition module is used to acquire the mass fraction of gas components, the sample value of spatial location, and the sample value of gas-oil ratio of several samples from a reference well; wherein the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components.

[0130] The first ratio module is used to calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of the reference well in each sample, so as to obtain the first ratio of the reference well in each sample.

[0131] The second ratio module is used to calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well for each sample, so as to obtain the second ratio of the reference well for each sample.

[0132] The Bernard ratio module is used to calculate the ratio between the mass fraction of the C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component of the reference well for each sample, so as to obtain the Bernard ratio of the reference well for each sample; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component;

[0133] The model training module is used to train a preset Bayesian maximum entropy model using the first ratio, second ratio, Bernard ratio, sample value of spatial location, and sample value of gas-oil ratio of the reference wells in each sample, so as to obtain a gas-oil ratio prediction model.

[0134] It is worth mentioning that the gas-oil ratio prediction model construction apparatus described in this embodiment can be used to execute any step of the embodiment of the gas-oil ratio prediction model construction method described above. All modules involved in this embodiment are logical modules. In practical applications, a logical unit can be a physical unit, a part of a physical unit, or a combination of multiple physical units. Furthermore, to highlight the innovative aspects of this application, this embodiment does not introduce units that are not closely related to solving the technical problem proposed in this application; however, this does not mean that other units do not exist in this embodiment.

[0135] Example 5:

[0136] Another embodiment of this application relates to an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the method for constructing the gas-oil ratio prediction model or the method for predicting the gas-oil ratio in the above embodiments.

[0137] The memory and processor are connected via a bus, which can include any number of interconnecting buses and bridges, connecting various circuits of one or more processors and memories. The bus can also connect various other circuits, such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and will not be described further herein. The bus interface provides an interface between the bus and the transceiver. The transceiver can be a single element or multiple elements, such as multiple receivers and transmitters, providing a unit for communicating with various other devices over a transmission medium. Data processed by the processor is transmitted over the wireless medium via an antenna, which further receives data and transmits it to the processor.

[0138] The processor manages the bus and general processing, and also provides various functions, including timing, peripheral interfaces, voltage regulation, power management, and other control functions. Memory is used to store data used by the processor during operation.

[0139] Example 6:

[0140] Another embodiment of this application relates to a computer-readable storage medium storing a computer program. When executed by a processor, the computer program implements the method embodiments described above.

[0141] That is, those skilled in the art will understand that all or part of the steps in the methods of the above embodiments can be implemented by a program instructing related hardware. This program is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0142] Those skilled in the art will understand that the above embodiments are specific embodiments for implementing this application, and in practical applications, various changes can be made to them in form and detail without departing from the spirit and scope of this application.

Claims

1. A method for constructing a gas-oil ratio prediction model, characterized in that, include: The mass fraction of gas components, sample values ​​of spatial location, and sample values ​​of gas-oil ratio are obtained from several samples of reference wells; wherein the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components. Calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of the reference well for each sample to obtain the first ratio of the reference well for each sample; Calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well for each sample to obtain a second ratio for the reference well for each sample; The ratio between the mass fraction of the C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component in the reference well for each sample is calculated to obtain the Bernard ratio of the reference well for each sample; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component; The preset Bayesian maximum entropy model is trained using the first ratio, second ratio, Bernard ratio, sample value of spatial location, and sample value of gas-oil ratio of the reference wells in each sample to obtain the gas-oil ratio prediction model.

2. The construction method according to claim 1, characterized in that, The step of training a preset Bayesian maximum entropy model using the first ratio, second ratio, Bernard ratio, spatial location sample value, and gas-oil ratio sample value of each of the aforementioned samples to obtain a gas-oil ratio prediction model includes: Using the first ratio, second ratio, Bernard ratio, and gas-oil ratio of the reference wells for each sample, a preset random forest model is trained to obtain a random forest prediction model; Calculate the error between the sample value and the predicted value of the gas-oil ratio in the random forest prediction model to obtain the error statistical distribution of each sample; The preset Bayesian maximum entropy model is trained using the first ratio, second ratio, Bernard ratio, sample value of spatial location, sample value of gas-oil ratio, and the error statistical distribution of each sample to obtain the gas-oil ratio prediction model.

3. The construction method according to claim 2, characterized in that, The preset Bayesian maximum entropy model is shown in the following equation: GOR=BME(MSE(RF(C1 / C2,C1 / C3,Bernald ratio),GOR),C1 / C2,C1 / C3,Bernardratio,x,y,z) In the formula, C1 / C2 represents the first ratio, C1 / C3 represents the second ratio, Bernard ratio represents the Bernard ratio, RF represents the random forest prediction model, MSE(RF(C1 / C2, C1 / C3, Bernard ratio), GOR) represents the error statistical distribution, GOR represents the gas-oil ratio, and x, y, z represent the x, y, z coordinates of the spatial location in the Cartesian coordinate system.

4. The construction method according to claim 1, characterized in that, The steps of obtaining the mass fraction of gas components, sample values ​​of spatial location, and sample values ​​of gas-oil ratio from several samples of a reference well include: The measured component ratio of the gas component in several samples from the water-based drilling is obtained as the mass fraction of the gas component. The sample values ​​of the spatial location and the sample values ​​of the gas-oil ratio of several samples from the water-based drilling are also obtained. The measured component ratios of the gas components in several samples from oil-based wells are obtained, and the measured component ratios of the gas components in the oil-based wells are reduced to obtain the mass fraction of the gas components in the oil-based wells; the sample values ​​of the spatial location and the sample values ​​of the gas-oil ratio of several samples from the oil-based wells are obtained; wherein, the reference wells include the water-based wells and the oil-based wells.

5. The construction method according to claim 1, characterized in that, The sample values ​​of the spatial location include sample values ​​of well coordinates and / or sample values ​​of well trajectory.

6. A method for predicting the gas-oil ratio, characterized in that, include: The gas composition, prior error, and spatial location of the reservoir to be predicted are obtained, as well as the gas-oil ratio prediction model constructed by the method of any one of claims 1 to 5; wherein the gas composition includes C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components. Calculate the ratio of the mass fractions of C1 hydrocarbon components and C2 hydrocarbon components in the reservoir to be predicted to obtain the first ratio of the reservoir to be predicted; Calculate the ratio of the mass fractions of C1 hydrocarbon components and C3 hydrocarbon components in the reservoir to be predicted to obtain the second ratio of the reservoir to be predicted; The Bernard ratio of the C1 hydrocarbon component and the mixed hydrocarbon component of the reservoir to be predicted is calculated to obtain the Bernard ratio of the reservoir to be predicted; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component; Based on the gas-oil ratio prediction model, the gas-oil ratio of the reservoir to be predicted is calculated according to the spatial location of the reservoir to be predicted, the first ratio, the second ratio, and the Bernard ratio.

7. The prediction method according to claim 6, characterized in that, The prediction method further includes: When the gas-oil ratio of the reservoir to be predicted is greater than or equal to a preset adjustment threshold, the wellbore trajectory is extended and / or the wellbore trajectory angle is adjusted.

8. An apparatus for constructing a gas-oil ratio prediction model, characterized in that, include: The sample acquisition module is used to acquire the mass fraction of gas components, the sample value of spatial location, and the sample value of gas-oil ratio of several samples from a reference well; wherein the gas components include C1 hydrocarbon components, C2 hydrocarbon components, and C3 hydrocarbon components. The first ratio module is used to calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C2 hydrocarbon component of the reference well in each sample, so as to obtain the first ratio of the reference well in each sample. The second ratio module is used to calculate the ratio between the mass fraction of C1 hydrocarbon component and the mass fraction of C3 hydrocarbon component of the reference well for each sample, so as to obtain the second ratio of the reference well for each sample. The Bernard ratio module is used to calculate the ratio between the mass fraction of the C1 hydrocarbon component and the mass fraction of the mixed hydrocarbon component of the reference well for each sample, so as to obtain the Bernard ratio of the reference well for each sample; wherein the mixed hydrocarbon component includes the C2 hydrocarbon component and the C3 hydrocarbon component; The model training module is used to train a preset Bayesian maximum entropy model using the first ratio, second ratio, Bernard ratio, sample value of spatial location, and sample value of gas-oil ratio of the reference wells in each sample, so as to obtain a gas-oil ratio prediction model.

9. An electronic device, characterized in that, include: At least one processor; as well as, A memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, which, when executed by the at least one processor, enables the at least one processor to perform the method for constructing the gas-oil ratio prediction model as described in any one of claims 1 to 5, or the method for predicting the gas-oil ratio as described in any one of claims 6 to 7.

10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the method for constructing the gas-oil ratio prediction model according to any one of claims 1 to 5, or the method for predicting the gas-oil ratio according to any one of claims 6 to 7.