A method for predicting an organic phase type based on machine learning
By constructing a machine learning prediction model and a K-nearest neighbor classification algorithm, and utilizing the intrinsic response relationship between well logging curves and core samples, the problems of insufficient core sampling density and low efficiency of manual identification were solved, realizing continuous and automated identification of organic phase types and improving identification accuracy and consistency.
Patent Information
- Application Number
- CN202611626618.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-10-20
- Publication Date
- 2026-11-24
AI Technical Summary
Existing technologies suffer from insufficient core sampling density, low vertical resolution of organic phases, low efficiency of manual identification, and strong subjectivity, resulting in large errors in the identification of organic phase types and making it difficult to meet the needs of fine evaluation in oil and gas exploration.
By constructing a machine learning prediction model and utilizing the intrinsic response relationship between well logging curves and geochemical parameters of core samples, combined with the K-nearest neighbor classification algorithm, continuous, quantitative, and automated identification of organic phase types can be achieved.
It improves the longitudinal resolution and efficiency of organic phase identification, reduces discrimination errors, realizes continuous and automated identification of organic phase types, and improves the accuracy and consistency of discrimination results.
Smart Images

Figure CN123161718A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of oil and gas exploration and evaluation technology, and in particular to a method for predicting organic phase types based on machine learning. Background Technology
[0002] Organic facies is a comprehensive geological concept that characterizes the type, abundance, maturity, and spatial distribution of organic matter in source rocks, as well as their hydrocarbon generation potential. It is also a key parameter for screening "sweet spots" in oil and gas exploration. Current methods for classifying organic facies mainly rely on geochemical experiments (pyrolysis, TOC, elemental analysis, etc.) on relevant samples (cores, wall cores, etc.) from the study area, followed by manual identification of organic facies types based on commonly used criteria.
[0003] In actual production processes, the acquisition of underground core samples is constrained by both drilling technology conditions and economic costs. Conventional drilling typically only performs segmented coring operations on the target strata in the study area, resulting in a severe deficiency in the vertical sampling density of core geochemical analysis samples, making it difficult to achieve continuous coverage of the entire target strata in the study area. Due to the aforementioned limitations in sampling density, the vertical resolution of organic phases in existing technologies is generally low, failing to accurately characterize the heterogeneous variations in organic matter abundance and type in the vertical direction. At the same time, due to the randomness of sampling location selection and insufficient sample representativeness, the organic phase discrimination results established based on sparse sample points have significant uncertainties, easily leading to misjudgments of organic phase types in local well sections, which in turn adversely affects the accurate evaluation of the hydrocarbon generation potential of the target strata source rocks.
[0004] Given the limitations of traditional core drilling, well logging curves, with their inherent advantages, can effectively compensate for these shortcomings. Well logging curves have a vertical sampling interval of 0.125 meters (i.e., 8 data points per meter), offering significantly better vertical resolution than conventional core drilling. Furthermore, the sample points are continuously and uniformly distributed, covering all layers of the target well, eliminating the problem of sampling location bias. Based on well logging curves, machine learning prediction models can be built to continuously predict key organic phase discrimination parameters (such as total organic carbon content, hydrogen index, kerogen type index, etc.). This effectively avoids the problems of insufficient sampling density and poor representativeness associated with traditional core drilling methods without increasing the workload of core drilling, providing a reliable data foundation for the continuous and quantitative identification of organic phases.
[0005] Furthermore, current techniques for identifying organic phases primarily rely on manual interpretation by geologists based on experimental geochemical parameters. While manual identification is feasible when the number of samples in the study area is limited, it becomes increasingly difficult to classify large batches of samples for organic phases within a reasonable timeframe, resulting in long interpretation cycles and low efficiency. Simultaneously, subjective differences in the understanding and application of organic phase classification standards among different geologists lead to varying results, lacking uniformity and reproducibility, and failing to meet the objectivity and consistency requirements for organic phase evaluation in exploration and development practices. Summary of the Invention
[0006] The purpose of this invention is to provide a method for predicting organic phase types based on machine learning, thereby addressing the technical problems of insufficient core sampling density, low vertical resolution of organic phases, low efficiency of manual identification, and strong subjectivity in existing technologies. This invention fully utilizes the inherent response relationship between well logging curves and geochemical parameters of core samples. By constructing a machine learning prediction model, it continuously predicts key organic phase discrimination parameters such as total organic carbon content (TOC), hydrogen index (HI), hydrogen-to-carbon atomic ratio (H / C), and kerogen type index (TI). Furthermore, it introduces the K-nearest neighbor (KNN) classification algorithm to automatically classify the above multi-dimensional prediction parameter combinations according to preset organic phase classification criteria, thus achieving continuous, quantitative, and automated identification of organic phase types.
[0007] To achieve the above objectives, the present invention provides the following method:
[0008] This invention provides a method for predicting organic phase types based on machine learning:
[0009] S1: Data Acquisition and Preprocessing: Collect logging curve data of the target well and geochemical experimental analysis data of the corresponding core samples, perform quality control on the logging curve data and the geochemical experimental analysis data, and perform depth matching between the geochemical experimental analysis data and the logging curve data to construct a logging-geochemical experimental analysis data correlation.
[0010] S2: Feature Engineering and Prediction Model Construction: Based on the well logging curve data and its derived features, a feature matrix is constructed. Machine learning regression prediction models are constructed for the four geochemical parameters: total organic carbon content, hydrogen index, hydrogen-carbon atomic ratio, and kerogen type index. Through model training and validation, and combined with comprehensive performance evaluation indicators, the optimal prediction models for the four geochemical parameters are determined respectively.
[0011] S3: Continuous prediction of parameters: Apply the optimal prediction model to the logging curve data of the target well and output the continuous prediction profile of the four geochemical parameters according to the depth point;
[0012] S4: Automatic classification of organic phases: Establish an organic phase discrimination standard system covering the thresholds of the four geochemical parameters, input the predicted values of the four geochemical parameters at each depth point of the target well into a weighted K-nearest neighbor classifier for automatic classification point by point, and output the organic phase type identification result.
[0013] Preferably, the logging data includes logging curves for spontaneous potential, spontaneous gamma, deep lateral resistivity, shallow lateral resistivity, sonic transit time, density logging, and neutron porosity; the geochemical experimental analysis data includes total organic carbon content, hydrogen index, hydrogen-to-carbon atomic ratio, and kerogen type index.
[0014] Preferably, the steps Data acquisition is achieved through the following methods: batch file scanning, file classification, and intelligent field recognition automatically read the well logging curve data and the geochemical experimental analysis data; a well logging curve alias mapping relationship is pre-established, and for multiple curve names corresponding to the same well logging parameter in different sources, field name matching is used to uniformly identify curves with the same parameter in different sources as the same standard well logging parameter, thus completing the unified standardization identification of the well logging curve data; the depth and well name information of the geochemical experimental analysis data are standardized, specifically including:
[0015] Multi-format depth analysis: For single-point depths, the numerical value is directly extracted; for depth intervals represented by connectors, wavy lines, "to", or slash separators, the starting depth and ending depth are extracted, and the midpoint of the interval is used as the representative depth of each sample in the geochemical experimental analysis data; if the starting depth, the separator, and the ending depth are distributed in different cells, the depth interval is automatically reconstructed first, and then the representative depth is calculated.
[0016] Automatic well name matching: The well names of the logging curve data and the geochemical experimental analysis data are standardized and preprocessed. According to the matching rules of complete well name consistency, inclusion relationship, and name consistency or inclusion relationship after removing non-alphanumeric characters, the correspondence between the logging curve data and the geochemical experimental analysis data of the same well is established.
[0017] Well logging-geochemical data correlation: Taking the representative depth obtained from the analysis of each sample in the geochemical experimental analysis data as the target, the well logging record with the smallest depth difference is found in the well logging curve data of the corresponding well, and the point-by-point correlation between the well logging curve data and the geochemical experimental analysis data is completed within the preset depth tolerance range.
[0018] Preferably, the steps Quality control in the process includes:
[0019] Well logging curve correction: The well logging curve data is corrected for wellbore enlargement, mud invasion, and surrounding rock.
[0020] Dual-source data quality processing: The well logging data and the geochemical experimental analysis data are sequentially subjected to valid value screening, missing value processing, outlier filtering, and sample weight optimization. Specifically, this includes: Valid value screening: Data that cannot be converted into valid values and data with preset invalid identifiers are marked as missing values; samples with values of the four geochemical parameters (TOC, HI, H / C, TI) exceeding a preset reasonable range are removed; Missing value processing: When the sample depth or the four geochemical parameters to be predicted in the geochemical experimental analysis data is missing, the sample does not participate in the model training for the corresponding parameter; only samples with missing well logging features that meet the preset minimum number of valid well logging features are retained and filled using the median of the corresponding well logging features; Outlier filtering: The upper and lower limits of outliers are determined according to the data distribution of each well logging feature, and extreme values exceeding the upper and lower limits of outliers are truncated; Weight optimization: Samples with values of the four geochemical parameters at the distribution boundary or extreme range are given lower training weights to reduce the excessive influence of extreme samples on model fitting.
[0021] Systematic review of geochemical experimental analysis data: removal of contaminated and abnormal samples;
[0022] Training sample set construction: Taking the effective depth of the sample in the processed geochemical experimental analysis data as the target, search for the data point with the smallest depth difference in the logging curve data of the corresponding well, and pair them within the preset depth tolerance range to form a logging-geochemical training sample set.
[0023] Preferably, the steps The depth matching process includes: calibrating the archived depth of the geochemical experimental analysis data and the depth of the well logging curve one by one within a set depth search window to eliminate depth system bias; and completing the nearest neighbor depth matching between the well logging curve and the geochemical experimental analysis data according to a set depth tolerance. Specifically, the geochemical experimental analysis data is used as the standard, and then the points of the well logging curve are compared to calculate the difference between the two. It is then determined whether this difference is within a certain range, such as 0.1m. If it is within this range, the two are matched.
[0024] Preferably, the steps The feature matrix is constructed by using natural potential, natural gamma, density logging, neutron porosity and deep lateral resistivity as basic features, and constructing the ratio of density logging to neutron porosity, the ratio of natural gamma to sonic transit time, and the ratio of deep lateral resistivity to shallow lateral resistivity as derived features. The feature matrix is composed of the basic features and the derived features.
[0025] Preferably, the steps This also includes: using models such as random forest, extreme random forest, ridge regression, elastic network regression, and gradient boosting regression as candidate prediction models; determining the optimal prediction model for each of the four geochemical parameters through model training and validation combined with comprehensive performance evaluation indicators; calculating the importance of each well logging curve and its derived characteristic curve to the original characteristics of the four geochemical parameters based on the optimal prediction model; and presetting sensitivity correction coefficients for each well logging curve according to its sensitivity to the organic matter in the source rock, wherein well logging curves sensitive to the organic matter in the source rock are configured with... A larger correction coefficient is used, while a smaller correction coefficient is used for well logging curves with weak organic matter response in the source rock. The original feature importance is multiplied by the corresponding sensitivity correction coefficient and then normalized to obtain the corrected feature contribution, which takes into account both the model statistical contribution and the well logging geological response characteristics. The input features are ranked according to the corrected feature contribution to characterize the relative contribution of each input feature to the prediction of the target geochemical parameters and to provide a basis for feature optimization. This is used to evaluate and rank the relative contributions of different input features to the prediction results of the corresponding geochemical parameters.
[0026] Based on the optimal prediction models corresponding to the four geochemical parameters, the original feature importance of each input feature to the corresponding geochemical parameter is obtained. According to the sensitivity of different logging features to the source rock organic matter geochemical parameters, corresponding sensitivity correction coefficients are preset, with larger correction coefficients assigned to logging features with higher sensitivity and smaller correction coefficients assigned to logging features with relatively weaker responses. The original feature importance of each input feature is multiplied by the corresponding sensitivity correction coefficient, and the correction result is normalized to obtain the corrected feature contribution, which is used to evaluate and rank the relative contributions of different input features to the prediction results of the corresponding geochemical parameters.
[0027] Preferably, the steps The organic phase discrimination standard system is established based on the geological characteristics of the study area, covering the four-dimensional parameter spatial numerical range thresholds of the four geochemical parameters. The organic phase discrimination standard system is managed using an independent configuration file, and the organic phase type and the thresholds of the four geochemical parameters can be adjusted by modifying the independent configuration file.
[0028] Preferably, the steps The weighted K-nearest neighbor classifier in the model performs classification as follows: It calculates the parameter distance between the predicted values of the four geochemical parameters at the depth point to be classified and the discrimination range of each organic phase. When the predicted value is within the corresponding parameter threshold range, the parameter distance is recorded as zero. When the predicted value exceeds the threshold range, the distance between the predicted value and the nearest boundary is used as the parameter deviation. Differential weights are assigned based on the contribution of the four geochemical parameters to the organic phase discrimination. A comprehensive distance index is constructed by combining the parameter distance and the differential weights. Candidate organic phases are sorted from smallest to largest comprehensive distance. When the minimum comprehensive distance is zero, the type is directly determined. For those with a comprehensive distance greater than zero, the top K candidate types are selected and weighted by the reciprocal of their distances, with the highest-voted type being the classification result.
[0029] The candidate organic phase types are sorted from smallest to largest according to the comprehensive distance. When the minimum comprehensive distance is zero, the candidate organic phase type is determined as the organic phase type of the depth point to be classified. When the minimum comprehensive distance is greater than zero, a preset number of K candidate organic phase types are selected, and a weighted vote is performed according to the reciprocal of the distance. The organic phase type with the most votes is the organic phase type of the depth point to be classified.
[0030] Preferably, the steps The organic phase type identification results output in the output are synchronized with the corresponding depth and the predicted values of the four geochemical parameters to form the continuous organic phase identification results of the target well.
[0031] The beneficial effects of this invention are as follows: Compared with the prior art, this invention constructs a technical system that integrates data processing, continuous prediction of geochemical parameters and intelligent identification and classification of organic phases, realizing continuous and automatic identification and classification of organic phases in target wells, significantly improving the vertical resolution and working efficiency of organic phase identification, and reducing the organic phase identification error caused by manual subjective classification and a small number of sample points. By establishing independent prediction models for four parameters—TOC, HI, H / C, and TI—and combining feature engineering, model optimization, and comprehensive evaluation methods, the accuracy of geochemical parameter predictions was improved. A prioritized back-checking mechanism for measured data ensures that measured values are retained for depths corresponding to existing geochemical data, preventing model predictions from replacing existing measured information. A weighted K-nearest neighbor classification model based on parameter-differentiated weights improved the accuracy of organic facies classification results and the rationality of geological interpretation. Furthermore, by combining intelligent well logging field recognition, multi-format depth analysis, automatic well name matching, data quality control, and configurable organic facies discrimination criteria, automated data processing and flexible adaptation to different study areas and strata were achieved. This approach boasts advantages such as high automation, strong versatility, and high engineering application value. Attached Figure Description
[0032] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the accompanying drawings used in the description of the specific embodiments or the prior art will be briefly introduced below. In all the drawings, similar elements or parts are generally identified by similar reference numerals. In the drawings, the elements or parts are not necessarily drawn to scale.
[0033] Figure 1 This is a flowchart of a method for predicting organic phase types based on machine learning according to the present invention;
[0034] Figure 2 Scatter plot for the test set verification of the machine learning prediction model for the four key organic phase discrimination parameters of this invention;
[0035] Figure 3 This is a comprehensive profile of the continuous prediction results of geochemical parameters and automatic identification of organic phases applied to Well A by the present invention. Detailed Implementation
[0036] To enable those skilled in the art to better understand the present invention, 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.
[0037] The terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this invention are used to distinguish different objects, not to describe a specific order. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, apparatus, product, or end that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or ends.
[0038] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0039] like Figure 1As shown in the flowchart, a specific embodiment of the present invention provides a method for predicting organic phase types based on machine learning, including the following steps:
[0040] S1: Data Acquisition and Preprocessing: Collect well logging data and corresponding geochemical experimental analysis data from core samples of the target well. Core samples mainly include cuttings, core fragments, and other rock fragments. Perform quality control on the well logging data and geochemical experimental analysis data, and perform depth matching between the geochemical experimental analysis data and well logging data to establish a correlation between well logging and geochemical experimental analysis data. S2: Feature Engineering and Predictive Model Construction: Construct a feature matrix based on well logging data and derived features. Develop machine learning regression prediction models for four geochemical parameters: total organic carbon content, hydrogen index, hydrogen-to-carbon atomic ratio, and kerogen type index. Determine the optimal prediction model for each of the four geochemical parameters through cross-validation. This involves model training and validation, and... S3: Continuous Parameter Prediction: The optimal prediction model is applied to the logging curve data of the target well, and the continuous prediction profile of the four geochemical parameters is output according to the depth point; S4: Automatic Organic Phase Classification: An organic phase discrimination standard system covering the threshold of the four geochemical parameters is established. The predicted values of the four geochemical parameters at each depth point of the target well are input into a weighted K-nearest neighbor classifier for automatic classification point by point, and the organic phase type identification result is output. It should be noted that the above process is not simply throwing the predicted values of the four geochemical parameters directly into a regular KNN, but first calculating the distance between the depth point to be classified and the threshold range of different organic phase parameters, and then combining the parameter weights to form a comprehensive distance and classify.
[0041] Well logging data includes spontaneous potential, spontaneous gamma, deep lateral resistivity, shallow lateral resistivity, sonic transit time, density logging, and neutron porosity curves; geochemical experimental analysis data includes total organic carbon content, hydrogen index, hydrogen-to-carbon atomic ratio, and kerogen type index.
[0042] The data acquisition in step S1 is achieved through the following methods: batch file scanning, file classification, and intelligent field recognition are used to automatically read well logging curve data and geochemical experimental analysis data; a well logging curve alias mapping relationship is pre-established, and for multiple curve names corresponding to the same well logging parameter in different sources, field name matching is used to uniformly identify curves with the same parameter from different sources as the same standard well logging parameter, thus completing the unified standardization identification of well logging curve data; the depth and well name information of the geochemical experimental analysis data are standardized, specifically including:
[0043] Multi-format depth analysis: For single-point depths, the numerical value is directly extracted; for depth intervals represented by connectors, wavy lines, "to", or slash separators, the starting and ending depths are extracted, and the midpoint of the interval is used as the representative depth of each sample in the geochemical experimental analysis data; if the starting depth, separator, and ending depth are distributed in different cells, the depth interval is automatically reconstructed first, and then the representative depth is calculated.
[0044] Automatic well name matching: The well names of logging curve data and geochemical experimental analysis data are standardized and preprocessed. According to the matching rules of complete well name consistency, inclusion relationship, and name consistency or inclusion relationship after removing non-alphanumeric characters, the correspondence between logging curve data and geochemical experimental analysis data of the same well is established.
[0045] Well logging-geochemical data correlation: Taking the representative depth obtained from the analysis of each sample in the geochemical experimental analysis data as the target, the well logging record with the smallest depth difference is found in the well logging curve data of the corresponding well, and the well logging curve data and geochemical experimental analysis data are correlated point by point within the preset depth tolerance range.
[0046] The quality control in step S1 includes: logging curve correction: caliper enlargement, mud invasion, and surrounding rock correction are performed on the logging curve data; specifically, with the availability of corresponding auxiliary logging and wellbore parameters, the effects of caliper enlargement, mud invasion, and surrounding rock can be further identified based on the caliper, drill bit size, depth resistivity, and longitudinal variation characteristics of the logging curve, and curve correction, abnormal sample removal, sample weight adjustment, and / or quality marking can be performed according to the degree of influence.
[0047] Dual-source data quality processing: The well logging data and geochemical experimental analysis data are sequentially subjected to valid value screening, missing value handling, outlier filtering, and sample weight optimization, specifically including:
[0048] Valid value screening: Data that cannot be converted into valid values and those with preset invalid identifiers are marked as missing values; samples with values of the four geochemical parameters (TOC, HI, H / C, TI) exceeding the preset reasonable range are removed; Missing value handling: Samples with missing depths or the four geochemical parameters in geochemical experimental analysis data are not included in subsequent model training; Samples with only partial missing well logging features and meeting the preset minimum number of valid well logging features are retained and filled using the median of the corresponding well logging features; Outlier filtering: The upper and lower limits of outliers are determined according to the data distribution of each well logging feature, and extreme values exceeding the upper and lower limits of outliers are truncated; Weight optimization: Samples with values of the four geochemical parameters in the distribution boundary or extreme range are given lower training weights to reduce the excessive influence of extreme samples on model fitting;
[0049] Systematic review of geochemical experimental analysis data: removal of contaminated and abnormal samples;
[0050] Training sample set construction: Taking the effective depth of the samples in the processed geochemical experimental analysis data as the target, the data points with the smallest depth difference are searched in the logging curve data of the corresponding wells, and paired within the preset depth tolerance range to form a logging-geochemical training sample set.
[0051] The depth matching in step S1 includes: within the set depth search window, with the archived depth of geochemical experimental analysis data as the target, finding the logging depth point with the smallest depth difference in the logging curve data, determining whether the depth difference is less than or equal to the preset depth tolerance, and if so, completing the pairing to reduce the impact of depth system bias.
[0052] The feature matrix construction in step S2 includes: using natural potential, natural gamma, density logging, neutron porosity and resistivity logging as basic features, and constructing the ratio of density logging to neutron porosity, the ratio of natural gamma to sonic transit time, and the ratio of deep lateral resistivity to shallow lateral resistivity as derived features. The feature matrix is composed of the basic features and the derived features.
[0053] Step S2 further includes: using models such as random forest, extreme random forest, and gradient boosting regression as candidate prediction models, determining the optimal prediction model for the four geochemical parameters through cross-validation and combined with comprehensive performance evaluation indicators; based on the optimal prediction model, calculating the importance of each input feature, i.e., the original features of each well logging curve to the four geochemical parameters; and presetting the sensitivity correction coefficients for each well logging curve according to the sensitivity of each well logging curve to the organic matter in the source rock, with larger correction coefficients for well logging curves that are sensitive to the organic matter in the source rock and smaller correction coefficients for well logging curves that are less sensitive to the organic matter in the source rock. The well curve is configured with a small correction coefficient; the original feature importance is multiplied by the corresponding sensitivity correction coefficient and then normalized to obtain the corrected feature contribution, which takes into account both the model statistical contribution and the well logging geological response characteristics; based on the ranking results of the corrected feature contribution, the optimal feature subset corresponding to the four geochemical parameters is selected. Specifically, the above selection is mainly used for ranking, plotting and outputting reports after obtaining the corrected feature importance, without further filtering out some features according to the ranking, but only adding them to the subsequent prediction, and weakly processing these weak features.
[0054] The organic phase discrimination standard system in step S4 is established based on the geological characteristics of the study area, covering the four-dimensional parameter spatial numerical range thresholds of four geochemical parameters. The organic phase discrimination standard system is managed using an independent configuration file, and the organic phase type and the thresholds of the four geochemical parameters are adjusted by modifying the independent configuration file.
[0055] The weighted K-nearest neighbor classifier in step S4 classifies the data as follows: It calculates the parameter distance between the predicted values of the four geochemical parameters of the depth point to be classified and the discrimination range of each organic phase. When the predicted value is within the corresponding parameter threshold range, the parameter distance is recorded as zero. When the predicted value exceeds the threshold range, the distance between the predicted value and the nearest boundary is used as the parameter deviation. Differential weights are assigned based on the contribution of the four geochemical parameters to the organic phase discrimination. A comprehensive distance index is constructed by combining the parameter distance and the differential weights. The preset number of nearest neighbors K=7, and the voting strategy uses distance-inverse weighted voting (K value and weight parameters can be flexibly configured according to the actual application scenario). The nearest neighbor sample with the smallest comprehensive distance index participates in the weighted voting to determine the organic phase type of the depth point to be classified.
[0056] The organic phase type identification results output in step S4 are output synchronously with the predicted values of the corresponding depth and four geochemical parameters to form the continuous organic phase identification results of the target well.
[0057] Example 1
[0058] The method described in this embodiment includes the following steps:
[0059] This embodiment adopts an integrated technical system of "data acquisition and preprocessing - machine learning prediction - intelligent classification of organic phases", which takes into account the automation of data processing, the accuracy of model prediction, the reliability of classification results and the scalability of engineering applications. The invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0060] Data acquisition and preprocessing (corresponding to step S1)
[0061] This step enables automatic reading, standardization correction, and depth matching of multi-source heterogeneous data to construct a high-quality training sample set. Specifically, it includes the following sub-steps:
[0062] Automatic acquisition and standardized identification of multi-source data: Addressing the issue that the same logging parameter may use different curve names in different data sources, the program pre-establishes a mapping relationship for logging curve aliases. For example, natural gamma curves may use different names such as GR, GAMMA, and GR1. The program identifies these different names as the same standard logging parameter through field name matching. For depth and well name information in geochemical experimental analysis data, standardized parsing is performed. For single-point depths, the numerical value is directly extracted; for depth intervals represented by connectors, wavy lines, "to", or diagonal lines, the starting and ending depths are extracted, and the midpoint of the interval is used as the representative depth; if the starting depth, separator, and ending depth are distributed in different cells, automatic reconstruction is performed first, and then the corresponding representative depth is calculated.
[0063] In terms of data association, the well names in the logging data and geochemical data are first standardized. Matching is performed based on the complete consistency of well names, inclusion relationships, and consistency or inclusion relationships of names after removing non-alphanumeric characters to establish the correspondence between logging data and geochemical data of the same well. Then, taking the depth after the geochemical sample is analyzed as the target, the logging record with the smallest depth difference is found in the logging data of that well, and the point-by-point association of the two types of data is completed within the preset depth tolerance range.
[0064] The system automatically identifies well logging data files and geochemical experimental data files in various formats, including LAS, DLIS, Excel, and CSV, by batch scanning and traversing the target block's well logging data folders and geochemical experimental data folders, and automatically classifies them according to file type. To address the issue of inconsistent naming of well logging curves from different sources, a multi-alias mapping rule library for well logging curves is established. For example, different names such as "GR," "GRAPI," and "Natural Gamma" are uniformly mapped to the standard field "Natural Gamma (GR)," and "RT," "RLLD," and "Deep Lateral" are uniformly mapped to "Deep Lateral Resistivity (RT)," achieving unified and standardized identification of well logging data from different sources. To address the issues of significant differences in geochemical data formats and non-standard depth storage, a multi-format depth parsing algorithm and dispersed cell depth reconstruction technology are employed to uniformly parse geochemical experimental analysis data in top-bottom depth format, midpoint depth format, and row-based dispersed depth, calculating the corresponding midpoint depth for each sample. Simultaneously, fuzzy well name matching technology is used to match well names between well logging data and geochemical experimental analysis data through string similarity calculation, automatically completing the inter-well association between the well logging dataset and the geochemical experimental analysis dataset.
[0065] In this embodiment, the logging data collected from the target well includes spontaneous potential (SP), natural gamma (GR), deep lateral resistivity (RT), shallow lateral resistivity (RS), sonic transit time (AC), density logging (DEN), and neutron porosity (CNL); the corresponding geochemical experimental analysis data of the core sample includes total organic carbon content (TOC), hydrogen index (HI), hydrogen-carbon atomic ratio (H / C), and kerogen type index (TI).
[0066] Data quality control and environmental correction
[0067] First, data that cannot be converted into valid values and data with preset invalid value identifiers are identified and uniformly marked as missing values. Simultaneously, samples exceeding the preset valid range are discarded based on the reasonable value ranges of geochemical parameters such as TOC, HI, H / C, and TI. For missing values, if the sample depth or target geochemical parameter is missing, the sample will not participate in subsequent training. For samples with missing logging parameters, they are retained if they still meet the minimum number of valid logging features, and the median of the corresponding logging feature is used to fill in the missing values.
[0068] For outliers in well logging features, upper and lower limits for outliers are determined based on the data distribution of each feature. Extreme values exceeding these limits are truncated to reduce the impact of outlier data on model training results. Furthermore, lower training weights are assigned to geochemical samples within boundary or extreme ranges to mitigate the excessive influence of a small number of extreme samples on model fitting. After these processing steps, using the depth of the geochemical samples as the target, the data point with the smallest depth difference is searched in the well logging data of the corresponding well. Within a preset depth tolerance range, a correspondence between well logging data and geochemical samples is established, ultimately forming a well logging-geochemical training sample set.
[0069] The logging curve fields are standardized and identified, and the logging data undergoes valid value checks, missing value handling, and outlier handling. Logging data that cannot be converted into valid values, has a preset invalid identifier, or significantly exceeds a preset data range is marked as missing. Samples with only partial missing logging features that meet the preset minimum number of valid logging features are retained and filled using the median of the corresponding logging feature. Outlier upper and lower limits are determined based on the data distribution of each logging feature, and extreme values exceeding these limits are truncated to reduce the impact of abnormal logging responses on model training. Furthermore, with well diameter, drill bit size, shallow and deep resistivity, and other auxiliary wellbore parameters available, well diameter enlargement, mud invasion, and surrounding rock effects can be identified, and curve correction, outlier sample removal, sample weight adjustment, and / or quality labeling can be implemented based on the degree of influence.
[0070] Well logging-geochemical depth matching and sample set construction
[0071] A depth search window of ±0.1m is set. Within this window, the archived depth of each geochemical experimental analysis data point is compared and calibrated with the depth sequence of the well logging curves one by one to eliminate systematic depth bias between drilling coring and well logging. A depth matching tolerance of 0.1m is set (the original sampling interval of the well logging curves is 0.125m). When the difference between the depth of the geochemical experimental analysis data point and the well logging depth point is less than or equal to this depth tolerance, the depth matching is considered successful. All well logging curve values at that depth point are then paired with the corresponding geochemical experimental parameter values. After completing the matching of all samples, a well logging-geochemical pairing training sample set with one-to-one depth correspondence is constructed. In this embodiment, after quality control and depth matching, a total of 268 sets of measured samples were obtained from the target well. These samples were divided into training and testing sets according to a preset ratio, providing a reliable data foundation for model training and validation.
[0072] Feature engineering and prediction model construction (corresponding to step S2)
[0073] This section is based on the preprocessed and depth-matched logging-geochemical training samples. Through feature engineering, model training and performance evaluation, a geochemical parameter prediction model is established to achieve high-precision prediction of parameters such as TOC, HI, H / C and TI. It can be divided into the following four parts: (1) Using conventional logging curves such as SP, GR, DEN, CNL and RT as basic features, and constructing feature ratios such as DEN / CNL, GR / DT, RT / RS to form a feature matrix for model training; (2) Establishing feature matrices for the four geochemical parameters TOC, HI, H / C and TI respectively. Independent regression prediction models, with random forest, extreme random forest and gradient boosting regression as candidate models, determine the optimal prediction model through cross-validation and comprehensive performance evaluation; (3) Based on the optimal prediction model, conduct feature importance analysis, and combine the geological sensitivity of different logging curves to organic matter response to correct the feature contribution, so that the feature importance evaluation takes into account both statistical features and geological significance; (4) Apply the determined optimal prediction model to logging curve data to continuously predict the four geochemical parameters TOC, HI, H / C and TI, providing continuous input parameters for subsequent organic phase identification.
[0074] This step involves feature construction, model optimization, and feature selection based on paired sample sets. High-precision machine learning regression prediction models are established for each of the four geochemical parameters. Specifically, this includes the following sub-steps:
[0075] Feature matrix construction
[0076] Seven preprocessed conventional logging curves were used as basic features, including spontaneous potential (SP), natural gamma ray (GR), density logging (DEN), neutron porosity (CNL), deep lateral resistivity (RT), shallow lateral resistivity (RS), and acoustic transit time (AC). Based on these, three derived ratio features were constructed: the ratio of density logging to neutron porosity (DEN / CNL), the ratio of natural gamma ray to acoustic transit time (GR / AC), and the ratio of deep lateral resistivity to shallow lateral resistivity (RT / RS), to enhance the difference in the logging curves' response to organic matter. These seven basic features and three derived features together constituted a 10-dimensional initial feature matrix, which served as the input for model training.
[0077] Candidate model selection and optimal model determination
[0078] The original importance of each input feature is calculated based on the optimized prediction model, and corresponding sensitivity correction coefficients are preset according to the sensitivity of different logging curves to the response of organic matter geochemical parameters. The original importance of each feature is multiplied by the corresponding sensitivity correction coefficient to obtain the corrected feature contribution value. All corrected feature contribution values are then normalized to obtain the final feature importance. Specifically, logging curves that are more sensitive to organic matter response are assigned larger correction coefficients, while logging curves with relatively weaker responses are assigned smaller correction coefficients. This ensures that the feature importance evaluation considers both the model's statistical contribution and the geological response characteristics of the logging parameters.
[0079] For four geochemical parameters—total organic carbon (TOC), hydrogen index (HI), hydrogen-to-carbon atomic ratio (H / C), and kerogen type index (TI)—independent regression prediction models were constructed to avoid the accuracy loss of single parameters caused by multi-parameter joint modeling. Specifically, the coefficient of determination (R²) on the test set ranged from 0.63 to 0.79, indicating that the prediction model constructed in this invention has good prediction accuracy and generalization ability, which can meet the accuracy requirements of subsequent automatic organic phase classification. Random forest regression, extreme random forest regression, and gradient boosting regression were selected as candidate models, and a 5-fold cross-validation method was used to train and validate each candidate model, with the coefficient of determination... The Mean Absolute Error (MAE) is used as a comprehensive performance evaluation index to select the best prediction model for each parameter. In this embodiment, the optimal prediction model for the TOC parameter is the Random Forest model, the optimal prediction model for the HI parameter is the Voting Regression Ensemble model, and the optimal prediction model for the H / C and TI parameters is the Gradient Boosting Regression model.
[0080] Feature Importance Assessment and Correction
[0081] Based on the optimal prediction model corresponding to each geochemical parameter, the original feature importance of each input feature to the prediction result of the corresponding geochemical parameter is calculated. For prediction models that can directly output feature importance, the statistical contribution of each input feature is obtained based on the model output; for prediction models that cannot directly output feature importance, the corresponding feature contribution can be obtained based on the model coefficients or by using feature substitution evaluation methods. The feature contribution is corrected by combining the geological sensitivity of different logging curves to organic matter response: for example, natural gamma (GR) is most sensitive to organic matter abundance response, and the feature importance of TOC and HI parameters is positively corrected; resistivity (RT) is more strongly correlated with organic matter maturity, and the feature importance of TI parameter is positively corrected, so that the feature importance evaluation takes into account both statistical regularity and geological significance. The corrected feature contributions are sorted from high to low, according to the logic: original feature importance → sensitivity correction → normalization → sorting. Specifically, based on the optimal prediction model corresponding to each geochemical parameter, the original feature importance of each input feature to the prediction result of the corresponding geochemical parameter is calculated. For prediction models that can directly output feature importance, the statistical contribution of each input feature is obtained based on the model output. For prediction models that cannot directly output feature importance, the corresponding feature contribution can be obtained based on model coefficients or by using feature substitution evaluation methods. Furthermore, considering the sensitivity of different input features to the geological response of source rock organic matter and corresponding geochemical parameters, corresponding sensitivity correction coefficients are preset. The original feature importance is multiplied by the corresponding sensitivity correction coefficient, and the resulting correction value is normalized to obtain the corrected feature contribution. The corrected feature contributions are then sorted from high to low to comprehensively characterize the model's statistical contribution and geological response characteristics of different input features, providing a basis for subsequent feature optimization and model interpretation, and improving model computational efficiency while ensuring prediction accuracy.
[0082] Model hyperparameter optimization
[0083] A grid search combined with 5-fold cross-validation method is used to optimize the hyperparameters of each optimal prediction model. Examples include the number of decision trees, maximum depth, and minimum number of leaf node samples in a random forest; and the learning rate, number of iterations, and subsampling ratio in gradient boosting regression. This completes the final training and solidification of the model. Furthermore, multiple candidate parameter combinations can be set for the prediction model's hyperparameters, and the prediction performance of different parameter combinations is evaluated using the 5-fold cross-validation results to determine the optimal model parameter configuration. The hyperparameters include one or more of the following: the number of decision trees, maximum depth, and minimum number of leaf node samples in the random forest regression model; and the learning rate, number of iterations, and subsampling ratio in the gradient boosting regression model. The final training of the corresponding prediction model is completed based on the determined model parameter configuration.
[0084] Continuous prediction of geochemical parameters (corresponding to step S3)
[0085] The pre-processed logging data for the entire target well section is used to input the optimal prediction model for four parameters at each depth point, according to the original 0.125m depth sampling interval of the logging data. The predicted values for TOC, HI, H / C, and TI parameters for each depth point are output, forming four vertically continuous geochemical parameter prediction profiles. For depth points with available measured geochemical experimental analysis data, a measured data priority review mechanism is activated, replacing the model prediction values with the measured experimental values to ensure the authenticity and accuracy of the data from known sample points.
[0086] Combination Figure 2 The test set validation results illustrate the model's accuracy: Figure 2 Scatter plots are provided to validate the prediction models for four geochemical parameters on the test set. Subplot A corresponds to the TOC parameter, with a test sample size of N=268 and a coefficient of determination R²=0.79; subplot B corresponds to the HI parameter, with a test sample size of N=181 and a coefficient of determination R²=0.73; subplot C corresponds to the H / C parameter, with a test sample size of N=225 and a coefficient of determination R²=0.63; and subplot D corresponds to the TI parameter, with a test sample size of N=123 and a coefficient of determination R²=0.67. The black diagonal solid line in the plot represents the 1:1 ideal prediction reference line, the red solid line represents the linear fit line between the measured and predicted values, and the red shaded area represents... Confidence intervals. The test data points for all parameters are evenly distributed on both sides of the 1:1 reference line, and the fitting trend is highly consistent with the ideal line, indicating that the prediction model constructed in this invention has good prediction accuracy and generalization ability, which can meet the accuracy requirements of subsequent automatic classification of organic phases. The above sample size is the number of test set samples used for model validation, that is, the number of samples selected for comparison between the measured geochemical data at the corresponding depth and the model prediction values, not the number of training samples.
[0087] Automatic organic phase classification (corresponding to step S4)
[0088] This step, based on continuously predicted four-dimensional geochemical parameters, uses a weighted K-nearest neighbor classifier to automatically identify organic phase types point-by-point. Specifically, it includes the following sub-steps:
[0089] Construction of Organic Phase Discrimination Criterion System
[0090] Based on the geological characteristics and geochemical statistical regularities of the source rocks in the study area, a quantitative discrimination standard system for organic phases was established, encompassing four-dimensional parameter spatial numerical thresholds (TOC, HI, H / C, TI). The organic phases in the study area were classified into seven types: A, AB, B, BC, C, CD, and D. The following is a chart illustrating the organic phase discrimination standards:
[0091]
[0092] The organic phase discrimination standard system is managed using an independent configuration file. The configuration file stores the threshold ranges of TOC, HI, H / C, and TI parameters for various organic phases. When the study area or target stratum changes or geological understanding is updated and the discrimination standard needs to be adjusted, the discrimination standard can be adjusted by modifying the organic phase type and parameter thresholds in the configuration file, thereby improving the adaptability and scalability of the method to different study areas and different strata.
[0093] Weighted K-Nearest Neighbor Classifier Configuration and Classification Calculation
[0094] An organic phase classifier is constructed using the weighted K-nearest neighbors (KNN) algorithm. The classification process is as follows: (1) Single parameter distance calculation: For any four-dimensional prediction parameter of a depth point to be classified, the distance between each parameter and the corresponding parameter threshold interval of a certain class of organic phase is calculated. If the predicted value of the parameter falls within the threshold interval of the class, the distance of the parameter is recorded as 0. If the predicted value exceeds the upper or lower limit of the interval, the absolute difference between the predicted value and the nearest interval boundary is calculated as the deviation distance of the parameter. (2) Comprehensive distance construction: Based on the contribution of the four parameters to the organic phase discrimination, differentiated weight coefficients are assigned: In this embodiment, the weight of TOC is 2, the weight of HI is 2, the weight of TI is 2, and the weight of H / C is 1. In this embodiment, the number of nearest neighbors K is preset to 7, and the voting strategy adopts distance reciprocal weighted voting. It should be noted that the above K value and weight parameters can be flexibly configured according to the actual application scenario.
[0095] Classification results output
[0096] The depth value, predicted values of four geochemical parameters, and organic phase type identification results of each depth point in the target well are output simultaneously to form a vertically continuous organic phase identification profile. The vertical resolution of the identification results is consistent with the logging curve, reaching 0.125m.
[0097] Combination Figure 3 The results of single-well application are explained: Figure 3 This is a comprehensive profile of the continuous prediction of geochemical parameters and automatic identification of organic phases in well A of the study area, using this method. The depth range is... The cross-section, from left to right, includes the lithology channel, logging curve channel, TOC parameter channel, HI parameter channel, H / C parameter channel, TI parameter channel, and organic phase type channel. In the various geochemical parameter channels, red dots represent core experimental data points, and black solid lines represent the continuous predicted curves output by this invention. The measured points and predicted curves generally show good agreement, verifying the reliability of depth matching and the prediction model. In the organic phase type channel, four organic phase segments—BC type, C type, BC type, and B type—are identified sequentially from shallow to deep, clearly depicting the vertical heterogeneous variation characteristics of organic phases in the target layer. Compared to methods that rely solely on discrete geochemical experimental samples for organic phase identification, this invention can extend the organic phase identification results to a continuous logging depth sequence, improving the continuity and precision of vertical organic phase identification.
[0098] In summary, this embodiment, through the complete process described above, achieves continuous, quantitative, and automated identification of the organic phases of source rocks, effectively solving the technical problems of insufficient sampling density, low vertical resolution, low efficiency of manual judgment, and strong subjectivity in traditional methods. It provides reliable technical support for the evaluation of source rocks and the selection of "sweet spot" intervals in unconventional oil and gas exploration.
[0099] The beneficial effects of this invention are as follows: Compared with the prior art, this invention constructs a technical system that integrates well logging and geochemical experimental data processing, continuous prediction of geochemical parameters and automatic classification of organic phases, realizes continuous automatic identification of organic phases along the well depth of the target well, improves the vertical continuity and work efficiency of organic phase identification, and reduces the dependence on manual point-by-point classification and discrete geochemical experimental samples. By establishing independent prediction models for four geochemical parameters—TOC, HI, H / C, and TI—and combining feature engineering, multi-model training, model validation, and comprehensive performance evaluation, the method extends prediction results from discrete geochemical measured data to continuous geochemical parameters. A prioritized back-checking mechanism for measured data ensures that measured values are retained at depths corresponding to existing geochemical measured data, preventing model predictions from replacing existing measured information. A weighted K-nearest neighbor classification method based on threshold range distances and differential parameter weights for the four geochemical parameters is constructed, comprehensively considering the differences in the contribution of different geochemical parameters to organic facies identification, thus improving the consistency of automatic organic facies identification and the rationality of geological interpretation. Furthermore, by combining automatic well logging field identification, multi-format depth parsing, well name matching, well logging-geochemical data depth correlation, and data quality control, the method achieves batch and automated processing of data from different sources, improving the engineering implementation efficiency and applicability of the proposed method.
[0100] The above descriptions are merely embodiments of the present invention. Commonly known technical solutions or characteristics are not described in detail here. It should be noted that those skilled in the art can make various modifications and improvements without departing from the present invention, and these should also be considered within the scope of protection of the present invention. These modifications and improvements will not affect the effectiveness of the present invention or the practicality of the patent. The scope of protection of the present invention should be determined by the content of its claims, and the specific embodiments described in the specification can be used to interpret the content of the claims.
Claims
1. A method for predicting organic phase types based on machine learning, characterized in that, The method includes the following steps: S1: Data Acquisition and Preprocessing: Collect logging curve data of the target well and geochemical experimental analysis data of the corresponding core samples, perform quality control on the logging curve data and the geochemical experimental analysis data, and perform depth matching between the geochemical experimental analysis data and the logging curve data to construct a logging-geochemical experimental analysis data correlation. S2: Feature Engineering and Prediction Model Construction: Based on the well logging curve data, a feature matrix is constructed. Machine learning regression prediction models are constructed for the four geochemical parameters: total organic carbon content, hydrogen index, hydrogen-carbon atomic ratio, and kerogen type index. The optimal prediction model for the four geochemical parameters is determined through cross-validation. S3: Continuous prediction of parameters: Apply the optimal prediction model to the logging curve data of the target well and output the continuous prediction profile of the four geochemical parameters according to the depth point; S4: Automatic classification of organic phases: Establish an organic phase discrimination standard system covering the thresholds of the four geochemical parameters, input the predicted values of the four geochemical parameters at each depth point of the target well into a weighted K-nearest neighbor classifier for automatic classification point by point, and output the organic phase type identification result.
2. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The logging data includes spontaneous potential, spontaneous gamma, deep lateral resistivity, shallow lateral resistivity, sonic transit time, density logging, and neutron porosity curves; the geochemical experimental analysis data includes total organic carbon content, hydrogen index, hydrogen-to-carbon atomic ratio, and kerogen type index.
3. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps Data acquisition is achieved through the following methods: the well logging curve data and the geochemical experimental analysis data are automatically read through batch file scanning, file classification and intelligent field recognition; a well logging curve alias mapping relationship is pre-established, and for multiple curve names corresponding to the same well logging parameter in different sources, the same parameter curves in different sources are uniformly identified as the same standard well logging parameter by field name matching, thus completing the unified and standardized identification of the well logging curve data. The depth and well name information of the geochemical experimental analysis data are standardized, specifically including: Multi-format depth parsing: Directly extracts the depth value of a single point; For depth intervals represented by connectors, wavy lines, "to", or slashes, the starting depth and ending depth are extracted, and the midpoint of the interval is used as the representative depth of each sample in the geochemical experimental analysis data; if the starting depth, the separator, and the ending depth are distributed in different cells, the depth interval is automatically reconstructed first, and then the representative depth is calculated. Automatic well name matching: The well names of the logging curve data and the geochemical experimental analysis data are standardized and preprocessed. According to the matching rules of complete well name consistency, inclusion relationship, and name consistency or inclusion relationship after removing non-alphanumeric characters, the correspondence between the logging curve data and the geochemical experimental analysis data of the same well is established. Well logging-geochemical data correlation: Taking the representative depth obtained from the analysis of each sample in the geochemical experimental analysis data as the target, the well logging record with the smallest depth difference is found in the well logging curve data of the corresponding well, and the point-by-point correlation between the well logging curve data and the geochemical experimental analysis data is completed within the preset depth tolerance range.
4. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps Quality control in the process includes: Well logging curve correction: The well logging curve data is corrected for wellbore enlargement, mud invasion, and surrounding rock. Dual-source data quality processing: The well logging data and the geochemical experimental analysis data are sequentially subjected to valid value screening, missing value processing, outlier filtering, and sample weight optimization. Specifically, this includes: Valid value screening: Data that cannot be converted into valid values and data with preset invalid identifiers are marked as missing values; samples with values of the four geochemical parameters exceeding the preset reasonable range are removed; Missing value processing: When the sample depth or the four geochemical parameters to be predicted in the geochemical experimental analysis data is missing, the sample does not participate in the model training for the corresponding parameter; only samples with missing well logging features that meet the preset minimum number of valid well logging features are retained and filled using the median of the corresponding well logging features; Outlier filtering: The upper and lower limits of outliers are determined according to the data distribution of each well logging feature, and extreme values exceeding the upper and lower limits of outliers are truncated; Weight optimization: Samples with values of the four geochemical parameters at the distribution boundary or extreme range are given lower training weights to reduce the excessive influence of extreme samples on model fitting. Systematic review of geochemical experimental analysis data: removal of contaminated and abnormal samples; Training sample set construction: Taking the effective depth of the sample in the processed geochemical experimental analysis data as the target, search for the data point with the smallest depth difference in the logging curve data of the corresponding well, and pair them within the preset depth tolerance range to form a logging-geochemical training sample set.
5. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps The depth matching process includes: calibrating the archived depth of the geochemical experimental analysis data and the depth of the well logging curve one by one within a set depth search window to eliminate depth system bias, and completing the nearest neighbor depth matching between the well logging curve and the geochemical experimental analysis data according to the set depth tolerance.
6. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps The feature matrix is constructed by using natural potential, natural gamma, density logging, neutron porosity and deep lateral resistivity as basic features, and constructing the ratio of density logging to neutron porosity, the ratio of natural gamma to sonic transit time, and the ratio of deep lateral resistivity to shallow lateral resistivity as derived features. The feature matrix is composed of the basic features and the derived features.
7. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps The method also includes: using random forest, extreme random forest, and gradient boosting regression models as candidate prediction models, determining the optimal prediction model for the four geochemical parameters through cross-validation and combined with comprehensive performance evaluation indicators; calculating the original feature importance of each well logging curve to the four geochemical parameters based on the optimal prediction model; pre-setting sensitivity correction coefficients for each well logging curve and derived well logging curve according to the sensitivity of each well logging curve to the organic matter in the source rock, wherein well logging curves sensitive to the organic matter in the source rock are assigned larger correction coefficients, and well logging curves with weaker responses to the organic matter in the source rock are assigned smaller correction coefficients; multiplying the original feature importance by the corresponding sensitivity correction coefficient and then normalizing the result to obtain the corrected feature contribution, so that the corrected feature contribution simultaneously takes into account the model statistical contribution and well logging geological response characteristics; and using this to evaluate and rank the relative contributions of different input features to the prediction results of the corresponding geochemical parameters.
8. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps The organic phase discrimination standard system is established based on the geological characteristics of the study area, covering the four-dimensional parameter spatial numerical range thresholds of the four geochemical parameters. The organic phase discrimination standard system is managed using an independent configuration file, and the organic phase type and the thresholds of the four geochemical parameters can be adjusted by modifying the independent configuration file.
9. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps The weighted K-nearest neighbor classifier in the model classifies data in the following way: it calculates the parameter distance between the predicted values of the four geochemical parameters of the depth point to be classified and the discrimination range of each organic phase. When the predicted value is within the corresponding parameter threshold range, the parameter distance is recorded as zero. When the predicted value exceeds the threshold range, the distance between the predicted value and the nearest boundary is used as the parameter deviation. Differential weights are assigned to the contribution of the four geochemical parameters to the organic phase identification. A comprehensive distance index is constructed by combining the parameter distances and the differential weights. The optimal number of nearest neighbors and the distance weighting strategy are determined in advance through cross-validation. The candidate organic phase types are sorted from smallest to largest according to the comprehensive distance. When the minimum comprehensive distance is zero, the candidate organic phase type is determined as the organic phase type of the depth point to be classified. When the minimum comprehensive distance is greater than zero, a preset number of K candidate organic phase types are selected, and a weighted vote is performed according to the reciprocal of the distance. The organic phase type with the most votes is the organic phase type of the depth point to be classified.
10. The method for predicting organic phase types based on machine learning according to claim 1, characterized in that, The steps The organic phase type identification results output in the output are synchronized with the corresponding depth and the predicted values of the four geochemical parameters to form the continuous organic phase identification results of the target well.
