Machine learning assisted in-situ monitoring of well entry fluid systems and devices
By using machine learning-assisted methods, combined with ultrasonic signals and model analysis, the components and concentrations of the well fluid system can be identified, solving the problem of real-time monitoring that is not possible in existing technologies. This enables accurate monitoring of the performance of the well fluid, ensuring the safety and economic benefits of drilling operations.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-29
- Publication Date
- 2026-03-17
AI Technical Summary
Existing technologies cannot monitor the properties of each component of the well fluid system in real time and accurately, which makes it impossible to take remedial measures in a timely manner, affecting the safety, efficiency and economic benefits of drilling operations.
A machine learning-assisted approach was adopted, combining ultrasonic signals and machine learning models, to analyze the ultrasonic signal characteristics of the well fluid system, identify components, and determine their concentration and viscosity. This included analysis using random forest models, support vector machines, and neural network models.
It enables real-time and relatively accurate monitoring of the performance of the well fluid system, allowing for timely remedial measures to ensure the safety, efficiency, and economic benefits of drilling operations.
Smart Images

Figure CN121027340B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of materials technology by measuring the chemical or physical properties of materials, and particularly to a machine learning-assisted in-situ monitoring method and apparatus for well fluid systems. Background Technology
[0002] The well fluid system refers to all fluids pumped into the wellbore (i.e., the drilled hole) and circulated during oil and gas drilling operations. The well fluid system is crucial for oil and gas exploration and development; the properties of its various components (such as concentration and viscosity) directly affect the safety, operational efficiency, and economic benefits of the oil and gas extraction process.
[0003] However, existing technologies have limited methods for monitoring the performance of injection fluids, and cannot monitor the performance of each component in the injection fluid system in real time and accurately. Therefore, they cannot guarantee timely remedial measures when the performance of the injection fluid system is unfavorable to drilling operations, thus failing to guarantee the safety, operational efficiency, and economic benefits of the mining process. Summary of the Invention
[0004] This invention proposes a machine learning-assisted in-situ monitoring method and device for well fluid systems. By combining the ultrasonic signals of the target well fluid system with a machine learning model, the signal characteristics of the ultrasonic signals of the target well fluid system are analyzed to obtain the multiple components contained in the target well fluid system, as well as the concentration and viscosity of each component. This enables real-time and relatively accurate monitoring of the performance of the well fluid system, thereby ensuring timely remedial measures can be taken when the performance of the well fluid system is unfavorable to drilling operations, thus guaranteeing the safety, operational efficiency, and economic benefits of the extraction process.
[0005] To achieve the above objectives, the present invention adopts the following technical solution:
[0006] In a first aspect, the present invention provides a machine learning-assisted in-situ monitoring method for well fluid systems, comprising: processing ultrasonic signals of a target well fluid system to determine the signal characteristics of the ultrasonic signals; wherein the signal characteristics of the ultrasonic signals include time-domain characteristics, frequency-domain characteristics, and statistical characteristics. Based on the signal characteristics of the ultrasonic signals and a first signal feature analysis model, the various components contained in the target well fluid system are determined; the first signal feature analysis model is trained based on a classifier model. Then, based on the signal characteristics of the ultrasonic signals, the various components in the target well fluid system, and a second signal feature analysis model, the concentration of each component in the target well fluid system is determined; the second signal feature analysis model is trained based on a classifier model. Finally, based on the signal characteristics of the ultrasonic signals, the various components in the target well fluid system, and a third signal feature analysis model, the viscosity of each component in the target well fluid system is determined; the third signal feature analysis model is trained based on a classifier model or a neural network model.
[0007] In one implementation of the first aspect, determining the multiple components contained in the target drilling fluid system includes: inputting the signal characteristics of an ultrasonic signal into a first signal feature analysis model, the first signal feature analysis model analyzing the signal characteristics of the ultrasonic signal, and outputting the multiple components contained in the target drilling fluid system, as well as the signal characteristics of the ultrasonic signal corresponding to each of the multiple components; wherein the first signal feature analysis model is trained based on a random forest model.
[0008] In one implementation of the first aspect, determining the concentration of each component among the multiple components of the target drilling fluid system includes: for each component among the multiple components, inputting the signal features corresponding to the component from the signal features of the component and the ultrasonic signal into a second signal feature analysis model; the second signal feature analysis model analyzes the signal features corresponding to the component from the signal features of the component and the ultrasonic signal, and outputs the concentration of the component; the second signal feature analysis model is obtained based on support vector machine training.
[0009] In one implementation of the first aspect, determining the viscosity of each component among the multiple components of the target drilling fluid system includes: for each component among the multiple components, inputting the signal features corresponding to the component from the signal features of the component and the ultrasonic signal into a third signal feature analysis model; the third signal feature analysis model analyzes the signal features corresponding to the component from the signal features of the component and the ultrasonic signal, and outputs the viscosity of the component; the third signal feature analysis model is obtained based on a classifier model training.
[0010] In one implementation of the first aspect, the classifier model on which the third signal feature analysis model is based is an XGBoost model, a random forest model, a LightGBM model, or a decision tree.
[0011] In one implementation of the first aspect, determining the viscosity of each component among the multiple components of the target drilling fluid system includes: inputting the signal characteristics of the multiple components and ultrasonic signals into a third signal feature analysis model; the third signal feature analysis model analyzes the signal characteristics of the multiple components and ultrasonic signals and outputs the viscosity of each component among the multiple components of the target drilling fluid system; the third signal feature analysis model is obtained based on a neural network model training.
[0012] Secondly, this invention provides a machine learning-assisted in-situ monitoring device for well fluid systems, used to implement the method provided in the first aspect above, including a signal feature determination module, a component identification module, a concentration determination module, and a viscosity determination module. The signal feature determination module processes the ultrasonic signal of the target well fluid system to determine the signal features of the ultrasonic signal; wherein the signal features of the ultrasonic signal include time-domain features, frequency-domain features, and statistical features. The component identification module determines the multiple components contained in the target well fluid system based on the signal features of the ultrasonic signal and a first signal feature analysis model based on a classifier model; the first signal feature analysis model is trained based on the classifier model. The concentration determination module determines the concentration of each component among the multiple components of the target well fluid system based on the signal features of the ultrasonic signal, the multiple components in the target well fluid system, and a second signal feature analysis model; the second signal feature analysis model is trained based on the classifier model. The viscosity determination module is used to determine the viscosity of each component in the target drilling fluid system based on the signal characteristics of the ultrasonic signal, the multiple components in the target drilling fluid system, and the third signal feature analysis model; the third signal feature analysis model is trained based on a classifier model or a neural network model.
[0013] In one implementation of the first and second aspects, the time-domain features include peak amplitude, rise time, pulse width, and clawback attenuation rate; the frequency-domain features include dominant frequency, bandwidth, and spectral centroid; and the statistical features include root mean square value, peak factor, skewness, and kurtosis.
[0014] Thirdly, the present invention provides an electronic device including a processor and a memory coupled to the processor; the memory is used to store computer instructions, and when the electronic device is running, the processor executes the computer instructions stored in the memory to cause the electronic device to perform the method described in the first aspect above or any implementation thereof.
[0015] Fourthly, the present invention provides a computer-readable storage medium including computer program instructions that, when executed by a computer, cause the computer to perform the method described in the first aspect above or any implementation thereof.
[0016] Fifthly, the present invention provides a computer program product, including computer program instructions, which, when executed on a computer, cause the computer to perform the method described in the first aspect above or any implementation thereof.
[0017] The technical effects corresponding to the second to fifth aspects and their possible implementations can be referred to the above description of the technical effects of the first aspect and its possible implementations, and will not be repeated here.
[0018] Compared with the prior art, the present invention has the following beneficial effects.
[0019] The present invention provides a machine learning-assisted in-situ monitoring method for well fluid systems. First, the ultrasonic signal of the target well fluid system is analyzed to obtain its signal characteristics. Then, the various components contained in the well fluid system are obtained through the signal characteristics and a first signal characteristic analysis model. A second signal characteristic analysis model and a third signal characteristic analysis model are then used to analyze the signal characteristics of the ultrasonic signal and the various components, respectively, to obtain the concentration and viscosity of each component in the target well fluid system. This enables real-time and relatively accurate monitoring of the performance of the well fluid system, ensuring timely remedial measures can be taken when the performance of the well fluid system is unfavorable to drilling operations, thereby guaranteeing the safety, operational efficiency, and economic benefits of the extraction process. Attached Figure Description
[0020] Figure 1 This is one of the schematic diagrams of a machine learning-assisted in-situ monitoring method for well fluid systems provided in this application embodiment;
[0021] Figure 2 This is a schematic diagram showing the importance ranking of the signal features of the ultrasound signal provided in the embodiments of this application;
[0022] Figure 3 This is the second schematic diagram of a machine learning-assisted in-situ monitoring method for well fluid systems provided in this application embodiment;
[0023] Figure 4 This is a schematic diagram illustrating the accuracy of the three classifier models provided in the embodiments of this application for identifying the components of the injected fluid;
[0024] Figure 5 This is the third schematic diagram of a machine learning-assisted in-situ monitoring method for well fluid systems provided in this application embodiment;
[0025] Figure 6 This is a schematic diagram illustrating the prediction accuracy of four machine learning regression models provided in the embodiments of this application for the concentration of guar gum-based fracturing fluid;
[0026] Figure 7 This is the fourth schematic diagram of a machine learning-assisted in-situ monitoring method for well fluid systems provided in this application embodiment;
[0027] Figure 8 This is the fifth schematic diagram of a machine learning-assisted in-situ monitoring method for well fluid systems provided in this application embodiment;
[0028] Figure 9 This is a schematic diagram illustrating the prediction accuracy of the four machine learning regression models provided in the embodiments of this application for the viscosity of guar gum-based fracturing fluid;
[0029] Figure 10 This is one of the schematic diagrams illustrating the prediction accuracy of the CNN model for the viscosity of guar gum-based fracturing fluid provided in the embodiments of this application;
[0030] Figure 11 This is a schematic diagram of the attention of the CNN model to the ultrasound signal provided in the embodiments of this application;
[0031] Figure 12 This is the second schematic diagram illustrating the prediction accuracy of the CNN model for the viscosity of guar gum-based fracturing fluid provided in the embodiments of this application.
[0032] Figure 13 This is a schematic diagram of the structure of a machine learning-assisted in-situ monitoring device for well fluid systems provided in an embodiment of this application. Detailed Implementation
[0033] In the specification and claims of this invention, the terms "first" and "second," etc., are used to distinguish different objects, rather than to describe a specific order of objects.
[0034] In the embodiments of this application, "and / or" indicates a relationship between objects. For example, A and / or B can represent the following three situations: A exists alone, B exists alone, and A and B exist simultaneously.
[0035] In the embodiments of this application, the terms "exemplary" or "for example" are used to indicate that something is an example, illustration, or description. Any embodiment or design that is described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design. Specifically, the use of the terms "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0036] In the description of this invention, unless otherwise stated, "multiple" means two or more. For example, multiple components means two or more components.
[0037] The method and apparatus provided in this application relate to monitoring of well fluid systems, and can be used to monitor the concentration and viscosity of each component among the various components contained in the well fluid system in real time.
[0038] Understandably, the well fluid system includes drilling fluid, fracturing fluid, and other functional fluids. In the process of oil and gas exploration and development, well fluids can carry and suspend rock cuttings to prevent wellbore blockage, stabilize the wellbore to prevent collapse, and also provide functions such as cooling, lubricating the drill bit, controlling formation pressure, and improving formation permeability. The properties of well fluids (such as concentration and viscosity) directly affect the safety, operational efficiency, and economic benefits of the oil and gas extraction process.
[0039] In practical applications, the composition and performance parameters of the well fluid (such as component ratios, concentrations, viscosity, and stability) are constantly changing. For example, when the concentration of certain chemical components decreases, the cuttings-carrying capacity of the well fluid weakens; changes in viscosity affect circulation efficiency and pressure transmission; and if some additives fail, wellbore stability may decrease. Abnormalities in these performance indicators can easily lead to wellbore instability, blowouts, increased drill bit wear, and decreased operational efficiency within a short period. Therefore, real-time and accurate in-situ monitoring of the well fluid's composition and physicochemical properties is crucial for ensuring the safety and continuity of oil and gas extraction operations.
[0040] Therefore, real-time monitoring of the performance of the drilling fluid during drilling operations allows for timely remedial measures to be taken when the performance of the drilling fluid is unfavorable to the drilling operation, thereby ensuring the safety, efficiency, and economic benefits of the extraction process.
[0041] Currently, in-situ monitoring of well fluids primarily employs contact sensors to acquire macroscopic physicochemical parameters such as temperature, pressure, pH, conductivity, and turbidity. For example, some methods deploy temperature sensors inside the discharge pipe to monitor the temperature of the well fluid; others use turbidimeters and conductivity meters to measure turbidity, conductivity, and total organic carbon. However, these methods have significant shortcomings: firstly, contact sensors are prone to wear and contamination during long-term use, leading to signal attenuation, decreased accuracy, and insufficient reliability; secondly, the range of monitored parameters is limited, only acquiring conventional properties such as temperature and pH of the well fluid, making it difficult to identify and quantify changes in different chemical components and their concentrations. Currently, analyzing the composition and concentration of well fluids typically requires sending samples to a laboratory for testing using large-scale instruments such as liquid chromatography and mass spectrometry. This is not only time-consuming, labor-intensive, and costly, but also results in delayed results, failing to meet the needs of real-time on-site monitoring.
[0042] To address the limitations of existing technologies in monitoring the performance of drilling fluids, which cannot provide real-time and accurate monitoring of the properties of each component within the drilling fluid system, and consequently cannot guarantee timely remedial measures when the performance of the drilling fluid system is unfavorable to drilling operations, thus compromising the safety, efficiency, and economic benefits of the extraction process, this application provides a machine learning-assisted in-situ monitoring method and device for drilling fluid systems. This method combines the ultrasonic signals of the target drilling fluid system with a machine learning model to analyze the signal characteristics of the ultrasonic signals, obtaining the various components contained in the target drilling fluid system and the concentration and viscosity of each component. This enables real-time and relatively accurate monitoring of the performance of the drilling fluid system, ensuring timely remedial measures can be taken when the performance of the drilling fluid system is unfavorable to drilling operations, thereby guaranteeing the safety, efficiency, and economic benefits of the extraction process.
[0043] For example, the machine learning-assisted in-situ monitoring device for well fluid systems provided in this embodiment of the invention can be executed by an electronic device with processing capabilities, such as a computer or server. Taking a computer as an example, the hardware of the computer may include: a processor, memory, a network interface, a user interface, a communication bus, etc.
[0044] The processor controls the electronic equipment to perform related processing and calculation tasks, such as processing ultrasonic signals, determining the multiple components contained in the well fluid system, and determining the concentration and viscosity of each component. The processor may include a central processing unit (CPU) or other processors, and may be single-core or multi-core; for example, the processor may include multiple CPUs.
[0045] Memory is used to store computer instructions and related data, such as ultrasonic signals, signal characteristics of ultrasonic signals, multiple components, and the concentration and viscosity of each component. Memory can be random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), flash memory, optical storage, magnetic disk storage media, or other magnetic storage devices, or any other medium capable of storing program code or data accessible by a computer. Optionally, memory can be integrated into the processor, or it can be independent of the processor.
[0046] A network interface is used for communication between a computer and other devices or communication networks. A network interface can be a transceiver with transmit and receive capabilities. Optionally, a network interface may include standard wired interfaces or wireless interfaces (such as Wi-Fi interfaces, Bluetooth interfaces, and 5G interfaces).
[0047] The communication bus is used to enable communication between different components. For example, the processor, memory, network interface and user interface mentioned above can be interconnected through the communication bus.
[0048] The user interface may include a display screen and an input unit (such as a keyboard). Optionally, the user interface may also include a standard wired interface or a wireless interface.
[0049] Those skilled in the art will understand that the computer described above may include more or fewer components, or combine certain components, or have different component arrangements; the embodiments of this application do not limit this.
[0050] like Figure 1 As shown, the in-situ monitoring method for well fluid system assisted by machine learning provided in this application includes S101-S104;
[0051] S101. Process the ultrasonic signal of the target drilling fluid system to determine the signal characteristics of the ultrasonic signal;
[0052] In this embodiment, the ultrasonic signal of the target drilling fluid system is acquired using an ultrasonic time-domain reflectometry (UTDR) device; in some embodiments, the ultrasonic signal is automatically acquired, with a minimum acquisition interval of 2 seconds; the acquisition table is stored in CSV format, recording information such as waveform time, voltage, and sampling frequency; this embodiment does not specify the ultrasonic signal acquisition method.
[0053] The signal characteristics of the aforementioned ultrasound signal include time-domain characteristics, frequency-domain characteristics, and statistical characteristics. Time-domain characteristics include peak amplitude, rise time, pulse width, and attenuation rate. Frequency-domain characteristics include main frequency, bandwidth, and spectral centroid. Statistical characteristics include root mean square value, peak factor, skewness, and kurtosis.
[0054] Understandably, among the time-domain characteristics mentioned above, Peak Amplitude refers to the maximum amplitude value of the ultrasonic signal, reflecting the energy intensity of the ultrasonic signal; Rise Time refers to the time it takes for the ultrasonic signal to rise from 10% of its peak intensity to 90% of its peak intensity, reflecting the steepness of the ultrasonic signal; Pulse Width refers to the length of time it takes for the ultrasonic signal to exceed 50% of its peak intensity, reflecting the sustainability of the ultrasonic signal's energy; Echo Attenuation Rate refers to the amplitude attenuation rate of the first and second peaks (i.e., the echo) of the ultrasonic signal, and this indicator is related to the viscosity and density of the propagation medium (i.e., the well fluid system).
[0055] The aforementioned frequency domain characteristics refer to performing a Fast Fourier Transform (FFT) on the ultrasound signal, converting it from a time-domain signal to a frequency-domain signal. The dominant frequency is the frequency corresponding to the point with the largest amplitude in the ultrasound signal spectrum, reflecting the most prominent characteristic of the ultrasound signal. The bandwidth refers to the width of the frequency range corresponding to ultrasound signal amplitudes greater than -3 dB. The spectral centroid is the frequency of the ultrasound signal obtained through energy-weighted averaging within a certain frequency range, representing the center position of the ultrasound signal spectrum.
[0056] The above statistical characteristics describe the distribution pattern of ultrasonic signal amplitude values, depicting the overall shape and randomness of the ultrasonic signal. The root mean square (RMS) is the square root of the average of the sum of the squares of all amplitude values over a certain time period, used to measure the average energy of the ultrasonic signal. The crest factor is a dimensionless parameter measuring the peak level of the ultrasonic signal waveform, defined as the ratio of the peak value to its RMS value. Skewness measures the asymmetry of the ultrasonic signal amplitude probability distribution; a skewness of 0 indicates a symmetrical distribution. Kurtosis measures the "peak" level of the ultrasonic signal amplitude probability distribution; a high kurtosis value indicates that the ultrasonic signal amplitude distribution is sharper than a Gaussian distribution.
[0057] For the classifier model, the importance ranking of the signal features of the ultrasound signal mentioned above is as follows: Figure 2 As shown, the parameters are, in order: Echo Attenuation, Root Mean Square, Crest Factor, Spectral Centroid, Kurtosis, Temperature, Peak Amplitude, Skewness, Bandwidth, Dorninant Frequency, and Concentration.
[0058] It should be noted that since processing ultrasonic signals to obtain their signal characteristics is a common technique in this field, the specific process of ultrasonic signal processing described above will not be further explained in the embodiments of this application.
[0059] S102. Based on the signal characteristics of the ultrasonic signal and the first signal characteristic analysis model, determine the multiple components contained in the target drilling fluid system.
[0060] The first signal feature analysis model described above is obtained by training a classifier model;
[0061] Optionally, the above-mentioned components may include pure water, guar gum, xanthan gum, crosslinking agent, and drilling fluid;
[0062] In one implementation, combined with Figure 1 ,like Figure 3 As shown, S102 includes S1021;
[0063] S1021. Input the signal characteristics of the ultrasonic signal into the first signal characteristic analysis model. The first signal characteristic analysis model analyzes the signal characteristics of the ultrasonic signal and outputs the multiple components contained in the target drilling fluid system, as well as the signal characteristics of the ultrasonic signal corresponding to each of the multiple components.
[0064] Therefore, the input of the first signal feature analysis model is the signal feature of the ultrasonic signal of the target drilling fluid system, and the output of the first signal feature analysis model is the signal feature of each component in the target drilling fluid system and the signal feature of the ultrasonic signal.
[0065] In this embodiment, the first signal feature analysis model is trained based on a random forest model. Specifically, the first training dataset is used to train the random forest model to obtain the first signal feature analysis model. The first training dataset may include multiple ultrasonic signals from multiple drilling fluid systems, multiple components contained in the drilling fluid systems corresponding to the multiple ultrasonic signals, the concentration and viscosity of each component, and the signal features of the ultrasonic signals corresponding to each component. Since the training process of the random forest model is common knowledge in this technical field, this embodiment will not elaborate on the training process of the random forest model.
[0066] The following example uses the various components of the well fluid system, including pure water, guar gum, xanthan gum, crosslinking agent, and drilling fluid, to illustrate the process of selecting a random forest model as the base model for the first signal feature analysis model in this application embodiment.
[0067] Step 1: Construct an ultrasonic signal database of multiple components in the well fluid system;
[0068] This ultrasonic signal database contains multiple ultrasonic signals obtained from 100 consecutive data acquisitions at each of the following conditions: 10°C, guar gum, xanthan gum, crosslinking agent, and drilling fluid; and 100 data acquisitions of each of the following seven temperature conditions (10°C, 15°C, 20°C, 25°C, 30°C, 35°C, and 40°C) and six concentration conditions (0.2%, 0.4%, 0.6%, 0.8%, 1.0%, and 1.2% by volume mass fraction); the database contains 4200 ultrasonic signals for each individual component.
[0069] Step 2: The above 4200 ultrasound signals are then processed to analyze their time-domain characteristics (such as peak, rise time, pulse width, and echo attenuation rate), frequency-domain characteristics (dominant frequency, bandwidth, and spectral centroid), and statistical characteristics (root mean square value, peak factor, skewness, and kurtosis). The time-domain characteristics, frequency-domain characteristics, statistical characteristics, and component names of the 4200 ultrasound signals are then compiled to obtain an ultrasound signal feature database.
[0070] Step 3: Using the ultrasonic signal characteristics of the well fluid system as input and the well fluid components as output, construct three classifier models: Random Forest, Decision Tree, and Gradient Boosting Decision Tree.
[0071] Step 4: Use the ultrasound signal feature database obtained in Step 2 to train the three classifier models constructed in Step 3, and obtain the trained random forest model, decision tree, and gradient boosting decision tree.
[0072] Step 5: Randomly extract time-domain features, frequency-domain features, statistical features, and component names of multiple ultrasound signals from the ultrasound signal feature database obtained in Step 2, and test the trained random forest model, decision tree, and gradient boosting decision tree respectively.
[0073] Specifically, such as Figure 4 As shown, the accuracy of the three classifier models in identifying the components of the injected fluid (corresponding to...) Figure 4 The accuracy scores are as follows: Random Forest model 0.88, Gradient Boosting Decision Tree 0.85, and Decision Tree 0.73. Understandably, the Random Forest model performs best among all metrics, with an F1-score of 0.87, indicating that the model has high accuracy and good balance in distinguishing components. In addition, the Precision and Recall values of the Random Forest model are close, indicating that the output results of the Random Forest model on positive and negative samples are very balanced, with fewer false positives and false negatives, and it can effectively identify component waveforms and distinguish non-component waveforms.
[0074] S103. Based on the signal characteristics of ultrasonic signals, multiple components in the target drilling fluid system, and the second signal characteristic analysis model, determine the concentration of each component in the multiple components of the target drilling fluid system;
[0075] The aforementioned second signal feature analysis model is obtained based on a classifier model trained.
[0076] For example, in combination Figure 3 ,like Figure 5 As shown, S103 above includes S1031;
[0077] S1031. For each component in the multiple components, the signal features corresponding to the component in the signal features of the component and the ultrasound signal are input into the second signal feature analysis model. The second signal feature analysis model analyzes the signal features corresponding to the component in the signal features of the component and the ultrasound signal and outputs the concentration of the component.
[0078] As can be seen from the above, the input of the above second signal feature analysis model is the signal feature corresponding to the component in the signal features of the component and the ultrasound signal, and the output of the above second signal feature analysis model is the concentration of the component;
[0079] In this embodiment, the second signal feature analysis model is obtained based on support vector machine training. Specifically, the second training dataset is used to train the support vector machine to obtain the second signal feature analysis model. The second training dataset may include multiple components contained in the drilling fluid system, the ultrasonic characteristics of each component, and the concentration of each component. Since the training process of the support vector machine is common knowledge in this technical field, this embodiment will not elaborate on the training process of the support vector machine.
[0080] The following example uses a guar gum-based fracturing fluid to illustrate the process of selecting a support vector machine as the base model for the second signal feature analysis model in this application.
[0081] Step 1: Construct a database of ultrasonic signals for guar gum-based fracturing fluids;
[0082] The aforementioned guar gum-based fracturing fluid ultrasonic signal database contains 1400 ultrasonic signals obtained from 200 consecutive ultrasonic signal acquisitions at seven concentrations of guar gum-based fracturing fluid: 0.002 g / L, 0.005 g / L, 0.01 g / L, 0.02 g / L, 0.1 g / L, 0.2 g / L, and 0.3 g / L.
[0083] Step 2: The above 1400 ultrasonic signals are then processed to analyze their time-domain, frequency-domain, and statistical characteristics. The time-domain, frequency-domain, statistical, and concentration characteristics of the 1400 ultrasonic signals are then organized to obtain a database of ultrasonic signal characteristics of guar gum-based fracturing fluid.
[0084] Step 3: Using the ultrasonic signal characteristics of the guar gum-based fracturing fluid in the well fluid system as input and the concentration of the guar gum-based fracturing fluid as output, construct four machine learning regression models: Support Vector Machine (SVM), Random Forest (RF), Decision Tree (DT), and eXtreme Gradient Boosting (XGBoost).
[0085] Step 4: Use the guar gum-based fracturing fluid ultrasonic signal feature database obtained in Step 2 to train the four machine learning regression models constructed in Step 3, and obtain the four trained machine learning regression models.
[0086] Step 5: Randomly extract multiple ultrasonic signal features and concentrations from the ultrasonic signal feature database of guar gum-based fracturing fluid obtained in Step 2, and test the four machine learning regression models trained above.
[0087] Specifically, the coefficient of determination (R²) and root mean square error (RMSE) were used to evaluate the predictive performance of the four machine learning regression models trained above. All four models demonstrated good predictive performance in predicting the concentration of guar gum-based fracturing fluid; among them, such as... Figure 6 As shown, the support vector machine has the best prediction performance, with the highest R² value of 0.824 and the lowest RMSE value of 0.367; indicating that the model has high goodness of fit and prediction accuracy.
[0088] It should be noted that, apart from the different concentrations of guar gum, the above seven concentrations of guar gum-based fracturing fluids are prepared using the same method; all are prepared by adding 0.3% (v / v) of a crosslinking agent after constant stirring in ultrapure water at 80°C for 4 hours; the coefficient of determination R... 2 R reflects the goodness of fit of the model, ranging from 0 to 1. 2 The closer to 1, the higher the model's explanatory power for the variables and the better the model fit; the root mean square error (RMSE) measures the standard deviation between the predicted value and the true value. The smaller the RMSE value, the higher the model's prediction accuracy.
[0089] S104. Based on the signal characteristics of ultrasonic signals, multiple components in the target drilling fluid system, and the third signal characteristic analysis model, determine the viscosity of each component in the target drilling fluid system.
[0090] The third signal feature analysis model is obtained by training a classifier model or a neural network model.
[0091] In one implementation, combined with Figure 5 ,like Figure 7 As shown, S104 includes S1041;
[0092] S1041. For each component in the multiple components, the signal features corresponding to the component in the signal features of the component and the ultrasonic signal are input into the third signal feature analysis model. The third signal feature analysis model analyzes the signal features corresponding to the component in the signal features of the component and the ultrasonic signal and outputs the viscosity of the component.
[0093] The aforementioned third signal feature analysis model is trained based on a classifier model; optionally, the classifier model on which the aforementioned third signal feature analysis model is based is an XGBoost model, a random forest model, a LightGBM model, or a decision tree.
[0094] In another implementation method, combined with Figure 5 ,like Figure 8As shown, S104 includes S1042;
[0095] S1042. Input the signal characteristics of multiple components and ultrasonic signals into the third signal characteristic analysis model. The third signal characteristic analysis model analyzes the signal characteristics of multiple components and ultrasonic signals and outputs the viscosity of each component in the target drilling fluid system.
[0096] The aforementioned third signal feature analysis model is obtained by training a neural network model (CNN);
[0097] Specifically, a third signal feature analysis model is obtained by training an XGBoost model, a random forest model, a LightGBM model, a decision tree model, or a neural network model using a third training dataset. The third training dataset may include multiple components contained in the drilling fluid system, the ultrasonic characteristics of each component, and the viscosity of each component. Since the training process of the above model is common knowledge in this technical field, the embodiments of this application will not elaborate on the training process of the above model.
[0098] The following example uses a guar gum-based fracturing fluid to illustrate the process of selecting XGBoost, Random Forest, LightGBM, Decision Tree, or Neural Network (CNN) models as the base models for the third signal feature analysis model in this application.
[0099] Step 1: Construct a database of ultrasonic signals from fracturing fluids;
[0100] The aforementioned fracturing fluid ultrasonic signal database contains 15 concentrations selected in the concentration range of 0.3 g / L to 0.6 g / L at concentration intervals of 0.02 g / L. Ultrasonic signals of guar gum-based fracturing fluid were stably collected 100 times at each concentration. Viscosity data were continuously collected 20 times using a rotational viscometer, resulting in a total of 1,500 ultrasonic signals and the viscosity corresponding to each of the 1,500 ultrasonic signals.
[0101] Step 2: The above 1500 ultrasonic signals are then processed to analyze their time-domain, frequency-domain, and statistical characteristics. The time-domain, frequency-domain, statistical, and viscosity data of the 1500 ultrasonic signals are then combined to obtain a fracturing fluid ultrasonic signal characteristic database.
[0102] Step 3: Construct five machine learning regression models: XGBoost, Random Forest, LightGBM, Decision Tree, and Neural Network (CNN). The inputs of XGBoost, Random Forest, LightGBM, and Decision Tree are the signal characteristics of the ultrasonic signal of the guar gum-based fracturing fluid in the well fluid system, and the output is the viscosity of the guar gum-based fracturing fluid. The input of the Neural Network (CNN) model is the ultrasonic signal of the guar gum-based fracturing fluid in the well fluid system, and the output is the viscosity of the guar gum-based fracturing fluid.
[0103] Step 4: Use the fracturing fluid ultrasonic signal feature database obtained in Step 2 to train the 5 models constructed in Step 3, and obtain the 5 trained models.
[0104] Step 5: Randomly extract multiple ultrasonic signal features and viscosity from the fracturing fluid ultrasonic signal feature database obtained in Step 2, and test the five models that have been trained above respectively.
[0105] Test results are as follows Figure 9 and Figure 10 As shown, all five models exhibit excellent prediction accuracy in viscosity prediction tasks, with each model having an R-value of [missing value]. 2 The scores are as follows: XGBoost 0.87, Random Forest 0.91, LightGBM 0.89, Decision Tree 0.90, and CNN 0.97; the CNN model has the highest fit and the highest prediction accuracy.
[0106] Furthermore, to verify the reliability of the high prediction accuracy of the third signal feature analysis model (hereinafter referred to as the CNN model) trained on the CNN model in this embodiment of the application, the CNN model was subjected to Grad-CAM (Gradient-weighted Class Activation Mapping) analysis. This analysis method is an advanced interpretability technique that can generate a model attention heatmap to explain the part that the model is interested in.
[0107] Specifically, such as Figure 11 As shown, Figure 11 The blue line represents the ultrasound signal waveform (corresponding to...). Figure 11In the OriginalSignal model, the background color represents attention, with blue to red indicating increasing attention intensity. The analysis results show that the excellent predictive performance of the CNN model is based on a deep understanding of ultrasonic signals. The convolutional layers of the CNN model can effectively learn the features of ultrasonic signals, and the CNN model focuses on the trough signals of ultrasonic signals. Therefore, it can be seen that the third signal feature analysis model trained using the CNN model as the base model can meet the requirements for predicting the viscosity of each component in the multiple components contained in the well fluid system.
[0108] In one application scenario, a CNN model can achieve stable, continuous, and accurate prediction of the viscosity of guar gum-based fracturing fluid; in this embodiment, the guar gum concentration in the guar gum-based fracturing fluid is 0.3 g / L; Figure 12 As shown, Figure 12 In this context, Predicted represents the predicted value, and True represents the actual value. Figure 12 It can be seen that, by combining the high-frequency automatic acquisition software SBQ.exe for ultrasonic signals and the CNN model, the prediction accuracy of the CNN model has always remained above 90%. Therefore, it can be determined that the CNN model can achieve high-frequency automatic monitoring of guanidine fracturing fluid at 30 points / min.
[0109] In summary, the machine learning-assisted in-situ monitoring method for well fluid systems provided in this application first analyzes the ultrasonic signals of the target drilling well fluid system to obtain the signal characteristics of the ultrasonic signals. Then, the various components contained in the well fluid system are obtained through the signal characteristics and a first signal characteristic analysis model. The signal characteristics and the various components of the ultrasonic signals are then analyzed using a second signal characteristic analysis model and a third signal characteristic analysis model to obtain the concentration and viscosity of each component in the target drilling well fluid system. This enables real-time and relatively accurate monitoring of the performance of the well fluid system, thereby ensuring timely remedial measures can be taken when the performance of the well fluid system is unfavorable to drilling operations, thus guaranteeing the safety, operational efficiency, and economic benefits of the extraction process.
[0110] Accordingly, embodiments of this application provide a machine learning-assisted in-situ monitoring device for well fluid systems, such as... Figure 13 As shown, it includes a signal feature determination module 501, a component identification module 502, a concentration determination module 503, and a viscosity determination module 504.
[0111] The signal feature determination module 501 is used to process the ultrasonic signal of the target drilling fluid system to determine the signal features of the ultrasonic signal; wherein the signal features of the ultrasonic signal include time domain features, frequency domain features, and statistical features. For example, the signal feature determination module 501 is used to implement S101 of the above method.
[0112] The component identification module 502 is used to determine the multiple components contained in the target drilling fluid system based on the signal characteristics of the ultrasonic signal and a first signal feature analysis model based on a classifier model. The first signal feature analysis model is obtained by training the classifier model. For example, the component identification module 502 is used to implement S102 of the above method.
[0113] The concentration determination module 503 is used to determine the concentration of each component in the target drilling fluid system based on the signal characteristics of the ultrasonic signal, the multiple components in the target drilling fluid system, and a second signal feature analysis model; the second signal feature analysis model is obtained by training a classifier model. For example, the concentration determination module 503 is used to implement S103 of the above method.
[0114] The viscosity determination module 504 is used to determine the viscosity of each component in the target drilling fluid system based on the signal characteristics of the ultrasonic signal, the multiple components in the target drilling fluid system, and a third signal feature analysis model; the third signal feature analysis model is obtained by training a classifier model or a neural network model. For example, the viscosity determination module 504 is used to implement S104 of the above method.
[0115] Each module of the above-mentioned machine learning-assisted in-situ monitoring device for well fluid systems can also be used to perform other steps in the above method embodiments. All relevant content involved in the above method embodiments can be referred to in the functional description of the corresponding functional module, and will not be repeated here.
[0116] This application also provides an electronic device, including: a processor and a memory coupled to the processor; the memory is used to store computer instructions, and when the electronic device is running, the processor executes the computer instructions stored in the memory to cause the electronic device to perform the methods described in the above embodiments. The processor can implement the signal feature determination module 501, component identification module 502, concentration determination module 503, and viscosity determination module 504 described above; the memory can also be used to store ultrasonic signals, signal features of the ultrasonic signals, multiple components, and the concentration and viscosity of each component, etc.
[0117] This application also provides a computer-readable storage medium including a computer program that, when run on a computer, performs the methods described in the above embodiments.
[0118] This application also provides a computer program product, which includes computer program instructions that, when run on a computer, execute the methods described in the above embodiments.
[0119] The various embodiments in this specification are described in a progressive manner. The same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on describing the differences from other embodiments.
[0120] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application.
Claims
1. A machine learning assisted in situ monitoring method of an entry fluid system, characterized in that, The method comprises the following steps: processing an ultrasonic signal of a target drilling well fluid system to determine signal characteristics of the ultrasonic signal; wherein the signal characteristics of the ultrasonic signal include time domain characteristics, frequency domain characteristics, and statistical characteristics; determining multiple components contained in the target drilling well fluid system according to the signal characteristics of the ultrasonic signal and a first signal characteristic analysis model; the first signal characteristic analysis model is trained based on a classifier model; the determination of the multiple components contained in the target drilling well fluid system comprises inputting the signal characteristics of the ultrasonic signal into the first signal characteristic analysis model, analyzing the signal characteristics of the ultrasonic signal by the first signal characteristic analysis model, and outputting the multiple components contained in the target drilling well fluid system and the signal characteristics of the ultrasonic signal corresponding to each of the multiple components; wherein the first signal characteristic analysis model is trained based on a random forest model; determining the concentration of each of the multiple components of the target drilling well fluid system based on the signal characteristics of the ultrasonic signal, the multiple components in the target drilling well fluid system, and a second signal characteristic analysis model; the second signal characteristic analysis model is trained based on a classifier model; the determination of the concentration of each of the multiple components of the target drilling well fluid system comprises, for each of the multiple components, inputting the component and the signal characteristics of the ultrasonic signal corresponding to the component into the second signal characteristic analysis model, analyzing the component and the signal characteristics of the ultrasonic signal corresponding to the component by the second signal characteristic analysis model, and outputting the concentration of the component; the second signal characteristic analysis model is trained based on a support vector machine; determining the viscosity of each of the multiple components of the target drilling well fluid system based on the signal characteristics of the ultrasonic signal, the multiple components in the target drilling well fluid system, and a third signal characteristic analysis model; the third signal characteristic analysis model is trained based on a classifier model or a neural network model; the third signal characteristic analysis model is trained based on a classifier model, and the determination of the viscosity of each of the multiple components of the target drilling well fluid system comprises, for each of the multiple components, inputting the component and the signal characteristics of the ultrasonic signal corresponding to the component into the third signal characteristic analysis model, analyzing the component and the signal characteristics of the ultrasonic signal corresponding to the component by the third signal characteristic analysis model, and outputting the viscosity of the component; the classifier model used by the third signal characteristic analysis model is an XGBoost model, a random forest model, a LightGBM model, or a decision tree. The third signal feature analysis model is trained based on a neural network model, and the determination of the viscosity of each component in the target drilling well entry fluid system includes: inputting the plurality of components and the signal features of the ultrasonic signal into the third signal feature analysis model, analyzing the plurality of components and the signal features of the ultrasonic signal by the third signal feature analysis model, and outputting the viscosity of each component in the target drilling well entry fluid system.
2. The method of claim 1, wherein, The time domain features include peak amplitude, rise time, pulse width, and echo attenuation rate. The frequency domain features include main frequency, bandwidth, and spectral centroid. The statistical features include root mean square value, peak factor, skewness, and kurtosis.
3. A machine learning assisted in situ monitoring device for an invasion fluid system for implementing the method of claim 1, characterized in that, The signal feature determination module, the component identification module, the concentration determination module, and the viscosity determination module are included. The signal feature determination module is configured to process an ultrasonic signal of a target drilling well entry fluid system and determine signal features of the ultrasonic signal, wherein the signal features of the ultrasonic signal include time domain features, frequency domain features, and statistical features. The component identification module is configured to determine a plurality of components contained in the target drilling well entry fluid system based on the signal features of the ultrasonic signal and a first signal feature analysis model based on a classifier model, wherein the first signal feature analysis model is trained based on a classifier model, and the determination of the plurality of components contained in the target drilling well entry fluid system includes: inputting the signal features of the ultrasonic signal into the first signal feature analysis model, analyzing the signal features of the ultrasonic signal by the first signal feature analysis model, and outputting the plurality of components contained in the target drilling well entry fluid system and the signal features of the ultrasonic signal corresponding to each of the plurality of components. The concentration determination module is configured to determine the concentration of each component in the plurality of components of the target drilling well entry fluid system based on the signal features of the ultrasonic signal, the plurality of components in the target drilling well entry fluid system, and a second signal feature analysis model, wherein the second signal feature analysis model is trained based on a classifier model, and the determination of the concentration of each component in the plurality of components of the target drilling well entry fluid system includes: for each component in the plurality of components, inputting the component and the signal features of the ultrasonic signal corresponding to the component into the second signal feature analysis model, analyzing the component and the signal features of the ultrasonic signal corresponding to the component by the second signal feature analysis model, and outputting the concentration of the component, wherein the second signal feature analysis model is trained based on a support vector machine. The viscosity determination module is configured to determine the viscosity of each component in the target drilling well fluid system based on the signal features of the ultrasonic signal, the plurality of components in the target drilling well fluid system, and a third signal feature analysis model; the third signal feature analysis model is obtained based on a classifier model or a neural network model. The third signal feature analysis model is obtained based on a classifier model, and the determination of the viscosity of each component in the target drilling well fluid system includes: for each component in the plurality of components, inputting the component and the signal feature corresponding to the component in the signal features of the ultrasonic signal into the third signal feature analysis model; the third signal feature analysis model analyzes the component and the signal feature corresponding to the component in the signal features of the ultrasonic signal, and outputs the viscosity of the component; the classifier model used by the third signal feature analysis model is an XGBoost model, a random forest model, a LightGBM model, or a decision tree. The third signal feature analysis model is obtained based on a neural network model, and the determination of the viscosity of each component in the target drilling well fluid system includes: inputting the plurality of components and the signal features of the ultrasonic signal into the third signal feature analysis model; the third signal feature analysis model analyzes the plurality of components and the signal features of the ultrasonic signal, and outputs the viscosity of each component in the target drilling well fluid system.
4. An electronic device, comprising: The electronic device comprises a processor and a memory coupled to the processor; the memory is configured to store computer instructions; when the electronic device runs, the processor executes the computer instructions stored in the memory, so that the electronic device executes the method of claim 1.
5. A computer readable storage medium, characterized in that, The computer program instructions, when executed by a computer, cause the computer to execute the method of claim 1.
Citation Information
Patent Citations
Downhole fluid density and viscosity sensor based on ultrasonic plate waves
US20190196041A1
Ultrasonic sensor systems for characterizing liquids
US20250102474A1