CN114004999A - Drilling fluid rheological parameter real-time measurement method based on machine learning - Google Patents
Drilling fluid rheological parameter real-time measurement method based on machine learning Download PDFInfo
- Publication number
- CN114004999A CN114004999A CN202111295919.4A CN202111295919A CN114004999A CN 114004999 A CN114004999 A CN 114004999A CN 202111295919 A CN202111295919 A CN 202111295919A CN 114004999 A CN114004999 A CN 114004999A
- Authority
- CN
- China
- Prior art keywords
- drilling fluid
- rheological
- model
- machine learning
- pictures
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000005553 drilling Methods 0.000 title claims abstract description 162
- 239000012530 fluid Substances 0.000 title claims abstract description 150
- 238000010801 machine learning Methods 0.000 title claims abstract description 23
- 238000000691 measurement method Methods 0.000 title claims abstract description 14
- 238000012360 testing method Methods 0.000 claims abstract description 27
- 238000012549 training Methods 0.000 claims abstract description 20
- 239000007788 liquid Substances 0.000 claims abstract description 10
- 238000013527 convolutional neural network Methods 0.000 claims abstract description 7
- 238000007781 pre-processing Methods 0.000 claims abstract description 5
- 230000003068 static effect Effects 0.000 claims description 15
- 238000003756 stirring Methods 0.000 claims description 14
- 230000006870 function Effects 0.000 claims description 12
- 238000011156 evaluation Methods 0.000 claims description 4
- 238000011176 pooling Methods 0.000 claims description 4
- 238000013210 evaluation model Methods 0.000 claims description 2
- 238000005259 measurement Methods 0.000 abstract description 8
- 239000002002 slurry Substances 0.000 abstract description 5
- 238000000034 method Methods 0.000 description 25
- 230000008569 process Effects 0.000 description 10
- 238000010200 validation analysis Methods 0.000 description 5
- 239000003795 chemical substances by application Substances 0.000 description 4
- 239000011159 matrix material Substances 0.000 description 4
- 238000012545 processing Methods 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 3
- 230000008859 change Effects 0.000 description 3
- 238000011161 development Methods 0.000 description 3
- 239000011435 rock Substances 0.000 description 3
- 238000005070 sampling Methods 0.000 description 3
- 238000004458 analytical method Methods 0.000 description 2
- 239000003638 chemical reducing agent Substances 0.000 description 2
- 238000005520 cutting process Methods 0.000 description 2
- 238000001514 detection method Methods 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 239000003077 lignite Substances 0.000 description 2
- 238000013507 mapping Methods 0.000 description 2
- 238000012544 monitoring process Methods 0.000 description 2
- 210000002569 neuron Anatomy 0.000 description 2
- 239000002245 particle Substances 0.000 description 2
- 239000011347 resin Substances 0.000 description 2
- 229920005989 resin Polymers 0.000 description 2
- 239000007787 solid Substances 0.000 description 2
- 206010063385 Intellectualisation Diseases 0.000 description 1
- VYPSYNLAJGMNEJ-UHFFFAOYSA-N Silicium dioxide Chemical compound O=[Si]=O VYPSYNLAJGMNEJ-UHFFFAOYSA-N 0.000 description 1
- 230000004913 activation Effects 0.000 description 1
- 239000000654 additive Substances 0.000 description 1
- 238000013019 agitation Methods 0.000 description 1
- 239000003637 basic solution Substances 0.000 description 1
- 229920001222 biopolymer Polymers 0.000 description 1
- 230000015572 biosynthetic process Effects 0.000 description 1
- 210000004027 cell Anatomy 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 238000013135 deep learning Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000006073 displacement reaction Methods 0.000 description 1
- 238000009826 distribution Methods 0.000 description 1
- 230000007613 environmental effect Effects 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 239000000706 filtrate Substances 0.000 description 1
- 238000005755 formation reaction Methods 0.000 description 1
- 238000009472 formulation Methods 0.000 description 1
- 230000005484 gravity Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 239000000203 mixture Substances 0.000 description 1
- 230000000877 morphologic effect Effects 0.000 description 1
- 230000006855 networking Effects 0.000 description 1
- 239000003208 petroleum Substances 0.000 description 1
- 239000000047 product Substances 0.000 description 1
- 238000000518 rheometry Methods 0.000 description 1
- 238000004513 sizing Methods 0.000 description 1
- 239000002689 soil Substances 0.000 description 1
- 239000000243 solution Substances 0.000 description 1
- 230000006641 stabilisation Effects 0.000 description 1
- 238000011105 stabilization Methods 0.000 description 1
- 239000004094 surface-active agent Substances 0.000 description 1
- 239000000725 suspension Substances 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
- 229920001285 xanthan gum Polymers 0.000 description 1
- 229940082509 xanthan gum Drugs 0.000 description 1
- 235000010493 xanthan gum Nutrition 0.000 description 1
- 239000000230 xanthan gum Substances 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/24—Classification techniques
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/40—Extraction of image or video features
- G06V10/44—Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components
- G06V10/443—Local feature extraction by analysis of parts of the pattern, e.g. by detecting edges, contours, loops, corners, strokes or intersections; Connectivity analysis, e.g. of connected components by matching or filtering
- G06V10/449—Biologically inspired filters, e.g. difference of Gaussians [DoG] or Gabor filters
- G06V10/451—Biologically inspired filters, e.g. difference of Gaussians [DoG] or Gabor filters with interaction between the filter responses, e.g. cortical complex cells
- G06V10/454—Integrating the filters into a hierarchical structure, e.g. convolutional neural networks [CNN]
-
- E—FIXED CONSTRUCTIONS
- E21—EARTH OR ROCK DRILLING; MINING
- E21B—EARTH OR ROCK DRILLING; OBTAINING OIL, GAS, WATER, SOLUBLE OR MELTABLE MATERIALS OR A SLURRY OF MINERALS FROM WELLS
- E21B21/00—Methods or apparatus for flushing boreholes, e.g. by use of exhaust air from motor
- E21B21/08—Controlling or monitoring pressure or flow of drilling fluid, e.g. automatic filling of boreholes, automatic control of bottom pressure
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01N—INVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
- G01N11/00—Investigating flow properties of materials, e.g. viscosity, plasticity; Analysing materials by determining flow properties
- G01N11/10—Investigating flow properties of materials, e.g. viscosity, plasticity; Analysing materials by determining flow properties by moving a body within the material
- G01N11/14—Investigating flow properties of materials, e.g. viscosity, plasticity; Analysing materials by determining flow properties by moving a body within the material by using rotary bodies, e.g. vane
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/21—Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
- G06F18/214—Generating training patterns; Bootstrap methods, e.g. bagging or boosting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/045—Combinations of networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
- G06T7/0004—Industrial image inspection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/82—Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01N—INVESTIGATING OR ANALYSING MATERIALS BY DETERMINING THEIR CHEMICAL OR PHYSICAL PROPERTIES
- G01N11/00—Investigating flow properties of materials, e.g. viscosity, plasticity; Analysing materials by determining flow properties
- G01N2011/006—Determining flow properties indirectly by measuring other parameters of the system
- G01N2011/008—Determining flow properties indirectly by measuring other parameters of the system optical properties
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20081—Training; Learning
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/20—Special algorithmic details
- G06T2207/20084—Artificial neural networks [ANN]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T2207/00—Indexing scheme for image analysis or image enhancement
- G06T2207/30—Subject of image; Context of image processing
- G06T2207/30108—Industrial image inspection
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Life Sciences & Earth Sciences (AREA)
- General Physics & Mathematics (AREA)
- Evolutionary Computation (AREA)
- Artificial Intelligence (AREA)
- Data Mining & Analysis (AREA)
- General Health & Medical Sciences (AREA)
- Health & Medical Sciences (AREA)
- General Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Computing Systems (AREA)
- Software Systems (AREA)
- Molecular Biology (AREA)
- Biomedical Technology (AREA)
- Computational Linguistics (AREA)
- Biophysics (AREA)
- Mathematical Physics (AREA)
- Geology (AREA)
- Multimedia (AREA)
- Evolutionary Biology (AREA)
- Bioinformatics & Computational Biology (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Mining & Mineral Resources (AREA)
- Mechanical Engineering (AREA)
- General Life Sciences & Earth Sciences (AREA)
- Biodiversity & Conservation Biology (AREA)
- Environmental & Geological Engineering (AREA)
- Fluid Mechanics (AREA)
- Medical Informatics (AREA)
- Databases & Information Systems (AREA)
- Quality & Reliability (AREA)
- Geochemistry & Mineralogy (AREA)
- Chemical & Material Sciences (AREA)
- Analytical Chemistry (AREA)
- Biochemistry (AREA)
- Immunology (AREA)
- Pathology (AREA)
- Image Analysis (AREA)
Abstract
The invention discloses a drilling fluid rheological parameter real-time measurement method based on machine learning, which adopts image recognition and machine learning to output rheological parameters of drilling fluid in a flowing state in real time, and specifically comprises the steps of establishing a drilling fluid picture database, preparing drilling fluids with the same volume and different rheological parameters, respectively acquiring pictures of free liquid surfaces of the drilling fluids with different rheological parameters when the drilling fluids flow at the same set rotating speed, preprocessing the picture data, constructing a convolutional neural network model, compiling the model and a training model, finally importing the drilling fluid pictures which are acquired in real time and in the flowing state at the same rotating speed into the trained model, and outputting the rheological parameters of the drilling fluid by the model. The rheological parameter of the drilling fluid can be obtained without using any mechanical equipment and sensors, the real-time measurement can be realized, the measurement frequency reaches the second level, the rheological parameter can be further infinitely copied to different fluid rheological property test application scenes, such as slurry rheological property tests in engineering slurries, trenchless projects, tunnels and other projects, and the application range is wide.
Description
Technical Field
The invention belongs to the technical field of drilling exploration, and particularly relates to a method for measuring drilling fluid rheological parameters in real time.
Background
The well wall is maintained to be stable and not to be separated from the drilling fluid in the exploration and development of energy and the deep geological drilling process. During drilling, a large amount of rock cuttings and debris is produced. Through circulation of the drilling fluid, the rock debris crushed by the drill bit is carried to the ground, a well is kept clean, tripping is smooth, the drill bit is ensured to be always in contact with and crush a new stratum at the bottom of the well, repeated cutting is not caused, and safe and rapid drilling is realized.
In the process, the carrying and suspension of the rock debris, well wall stabilization, hydraulic jet and the like are closely related to the rheological property of the drilling fluid. The main methods for measuring the rheological parameters of the drilling fluid are divided into two methods, namely a funnel viscosity agent and a six-speed rotational viscometer. The viscosity value measured by the funnel viscosity agent is time and the unit is s, and the six-speed rotational viscometer can obtain the shear rate and the shear stress value, thereby calculating the plastic viscosity, the apparent viscosity and the like of the drilling fluid, and the unit is mPa & s.
In the drilling process, in order to ensure the drilling safety and the stability of the well wall, the density and rheological parameters of the drilling fluid can be monitored in real time. However, in the actual operation process on site, the rheological property of the drilling fluid cannot be monitored in real time. Thus, in the fields of geological and petroleum engineering, the drilling fluid rheological parameters are mainly measured and data recorded by mud engineers once an hour. The hourly measurement data is essentially the funnel viscosity value due to field condition limitations. Drilling fluid plastic viscosity and apparent viscosity testing occurs substantially only in significant drilling projects.
With the continuous progress of society and technology, drilling fluid testing is turning to automation, and therefore some instruments for automatically measuring drilling fluid rheological parameters are also introduced. For example, the on-line drilling fluid testing system developed by the Brazilian national oil company can automatically monitor the drilling fluid rheology. For another example, the intelligent detection of the great wall drilling engineering institute gradually replaces the manual detection of the drilling fluid performance, the construction of the system platform combines the traditional drilling fluid testing technology in the oil and gas industry with the internet of things platform and the big data platform, a large amount of accurate reference data is provided for the real-time return of field data and the scheme formulation in a laboratory through the intelligent analysis system, and technical support is provided for the digital transformation of the drilling fluid industry.
Currently, patents related to automatic testing of drilling fluid viscosity include: a method and a device (CN102140911A) for acquiring the viscosity and the density of drilling fluid in the process of drilling and a drilling mud continuous automatic measurement displacement, specific gravity and viscometer (CN 101446198A). The conventional testing devices have the problems and disadvantages that the testing process takes a long time, real-time monitoring cannot be achieved, and a large amount of manpower and material resources are required. The main measure of the emerging technical scheme is that a machine replaces manual testing, but the defect is that the testing method is based on mechanization and automation, the testing is complex, still needs mechanical equipment, and only replaces manual measurement; the cost of the product is high, although the test speed can be increased, the data monitoring per second cannot be achieved, and most of the measured data are funnel viscosity values.
Disclosure of Invention
The invention aims to provide a drilling fluid rheological parameter real-time measuring method based on machine learning, and solves the problems of poor real-time performance (long sampling and measuring time needs to be waited), complex testing equipment, high cost and the like in the conventional drilling fluid measuring method.
The core of the method is that image acquisition, image recognition and machine learning are applied to real-time measurement of drilling fluid rheological parameters, a high-accuracy prediction model is trained by combining morphological (shape) characteristics (including but not limited to ripple distribution density characteristics, ripple width, wave crest, wave trough, wavelength and the like) of the drilling fluid on a free liquid surface in a flowing state (stably rotating at a certain rotating speed), and rheological parameters (apparent viscosity, plastic viscosity, dynamic shear force, static shear force, thixotropy and the like) are compared and classified with a real-time acquired drilling fluid free liquid surface picture in the flowing state at the same rotating speed, and an accurate drilling fluid rheological parameter result is output.
In order to achieve the purpose, the invention adopts the following scheme:
a drilling fluid rheological parameter real-time measuring method based on machine learning is characterized in that rheological parameters of drilling fluid in a flowing state are output in real time in a mode of combining image acquisition and image recognition.
Further, the image acquisition and image recognition combination includes,
step one, establishing a drilling fluid picture database, preparing drilling fluids with the same volume and different rheological parameters, respectively acquiring pictures of free liquid surfaces when the drilling fluids with different rheological parameters flow at the same set rotating speed, acquiring a plurality of pictures under the same rheological parameter, then measuring the rheological parameters of the drilling fluids, establishing a data set with the rheological parameters corresponding to the pictures of the drilling fluids one by one, for example, after acquiring one picture, measuring the apparent viscosity, the plastic viscosity, the dynamic shear force, the static shear force and the thixotropy of the drilling fluids corresponding to the picture, and then, forming a data set corresponding to one by one;
step two, preprocessing data, loading and formatting the pictures in the data set obtained in the step one, adjusting the sizes of the pictures, decoding the pictures into tensors, marking each picture in the data set in a label mode, establishing a data set in a (picture and label) mode, and splitting the data set into a training set and a testing set, wherein the labels are rheological parameters corresponding to the pictures; here, (picture, label) means that a one-to-one mapping relationship is established between one drilling fluid picture and one rheological parameter, that is, the apparent viscosity, plastic viscosity, dynamic shear force, static shear force and thixotropy corresponding to one picture in the step one are divided into five data sets: (picture, apparent viscosity), (picture, plastic viscosity), (picture, dynamic shear), (picture, static shear), and (picture, thixotropy);
constructing a model, wherein a convolutional neural network model is adopted, and the output of the model is the rheological parameter of the drilling fluid;
compiling a model and a training model, wherein the compiling model comprises an optimizer, a loss function and an evaluation index, and the training model comprises the difference of the accuracy of the evaluation model on a training set and a testing set so as to adjust the model;
and step five, testing the rheological parameters of the drilling fluid, introducing the drilling fluid picture which is obtained in real time and is in the flowing state with the same rotating speed as the set rotating speed in the step one into the model which is trained to be qualified in the step four, and outputting the rheological parameter values of the drilling fluid by the model. And when the picture of the drilling fluid is obtained in real time, the total volume of the drilling fluid is kept unchanged.
Further, the rheological parameters include apparent viscosity, plastic viscosity, dynamic shear force, static shear force, and thixotropy.
Alternatively, when the rheological parameters of the drilling fluid are measured in the first step, a six-speed rotational viscometer is used for reading the drilling fluidAndreading at the rotating speed and calculating the rheological parameters of the drilling fluid.
Alternatively, in the first step, when acquiring drilling fluid dynamic pictures with different rheological parameters, the pictures are acquired from different angles above the free liquid level of the drilling fluid for the drilling fluid with the same rheological parameter. The different angles are different positions on a circle with a normal line of a liquid level center when the drilling fluid is static as a rotating axis (the circle can move up and down along the rotating axis to change the picture acquisition height, and can also expand or reduce the diameter of the circle to change the acquisition position), for example, the different angles are performed in a mode that one picture is taken along the circle in each increment.
Alternatively, in the second step, the picture is adjusted to be a 28 × 28 pixel gray scale picture.
Alternatively, in the third step, the convolutional neural network model includes at least 2 convolutional layers and 1 pooling layer.
Preferably, in each of the 2 convolutional layers, the sizes of the convolutional kernels are 3 × 3, and the number of the convolutional kernels is 32 and 64, respectively.
It should be noted that the setting of the convolution kernel size, convolution layer and pooling layer in the convolutional neural network model is adjusted according to the accuracy of model prediction, and the above solution is only the most basic solution.
Alternatively, in the fourth step, the evaluation index is accuracy, and the accuracy is the percentage of correctly classified images.
Optionally, in the fifth step, the drilling fluid to be measured is placed in a container and continuously stirred at a stable rotating speed, and a picture of the free liquid level of the drilling fluid in a flowing state is acquired in real time through an image acquisition device arranged at the drilling fluid stirring container. The vessel is understood here to be a space which ensures a constant volume of drilling fluid, i.e. no change in the total volume of drilling fluid in the vessel during stirring. For example, the drilling fluid to be measured is stored in a stirring tank, the total volume of the drilling fluid in the stirring tank is constant, and the drilling fluid is stirred in a rotating mode at a stable rotating speed, wherein the rotating speed of the stirring is the same as the set rotating speed when the picture is acquired in the step one.
When pictures in a drilling fluid flowing state are collected, the following rules are usually followed, environmental factors can be reduced to the minimum, and the accuracy of machine learning image recognition is ensured.
(1) In the aspect of drilling fluid, the volume of the drilling fluid needs to be consistent. For example, the volume of the drilling fluid is uniformly 350mL when the picture is acquired, and the volume of the drilling fluid is the same when the picture is acquired each time.
(2) In the aspect of acquiring the color of the picture, taking a camera as an example, the current pictures acquired by the camera are all color pictures, but are limited by the huge limitation of computer memory and data volume, and all the acquired pictures are subjected to gray level processing, so that the pictures are changed into gray level pictures and then large data training is carried out.
(3) In the aspect of drilling fluid configuration, different formations and different oil and gas resources adopt different drilling fluid systems, so that the added treating agents are different. For example, XC xanthan gum is white solid particles, SPNH sulfonated lignite resin is brown solid particles, and the color of the drilling fluid is different after the SPNH sulfonated lignite resin is added into a drilling fluid system. Therefore, the picture gray level processing is carried out on all the drilling fluid systems, and the misjudgment of color on the rheological parameter prediction can be reduced.
(4) In the aspect of the flow rate of the drilling fluid, the key point of image acquisition is that the drilling fluid flows at a fixed rotating speed. The specific rotating speed is not limited as long as the drilling fluid can be stably and continuously stirred. For example, a drilling fluid agitation speed of 300rpm is used. The reason why the drilling fluid in a stirring state is adopted as a flowing state is that in the oil and gas field development and the unconventional energy development process, the actual drilling fluid passes through a stirring pool in the circulating process, and the stirrer rotates at a fixed rotating speed. Therefore, the image acquisition equipment can be placed beside the stirring pool, so that a real-time drilling fluid picture is obtained, and the rheological parameters are predicted and output, so that the existing drilling fluid sampling is replaced, and then the testing is carried out through equipment such as a six-speed rotary viscometer, and the intellectualization is realized.
(5) The method has the advantages that the light rays in the image acquisition environment and the image acquisition angle do not influence the final output result of the drilling fluid rheological parameters, and the acquired images can be subjected to gray processing, so that the light rays in the image acquisition environment are not influenced, the conditions in the actual production process are met, and the final result is not influenced in sunny days, cloudy days and rainy days. In the aspect of image acquisition angles, images at any angles need to be acquired, the acquired image data volume is ensured to be large enough, and the situations of non-learning and non-training under special conditions are reduced. For example, each drilling fluid is subjected to picture acquisition of the free fluid level of the drilling fluid along different angles under the same rheological parameter.
The invention relates to a drilling fluid rheological parameter testing method based on image acquisition, image recognition and depth machine learning. The method can obtain the rheological parameters of the drilling fluid without using any mechanical equipment and sensors, can measure in real time, and can measure the plastic viscosity, the apparent viscosity, the dynamic shear force, the static shear force and the thixotropy of a drilling fluid system per second when the measuring frequency reaches the second level, thereby saving the economic cost, the time cost and the human resources.
In the traditional method for testing the rheological parameters of the drilling fluid, if the complete rheological parameters of a drilling fluid system are required to be obtained, a six-speed rotational viscometer is required, the static shear force and thixotropy test takes about 20 minutes, but in the drilling process, a drilling engineer needs to master the properties of the drilling fluid to accurately know the drilling condition, so that accidents such as blowout, drill sticking and the like are prevented. Casualties and economic losses caused by major accidents such as blowout of a single well are difficult to predict, taking the blowout event of gulf of Mexico as an example, 11 people die, and the economic losses cannot be predicted according to a 200 hundred million dollar compensation scheme. Therefore, the method is more significant in time cost, economic cost and safety promotion.
The drilling fluid rheological parameter data generated by the real-time measurement method can provide quick and effective reference for drilling fluid parameter adjustment and safe drilling in the fields of geology, resources, energy and engineering.
Based on the analysis, compared with the existing drilling fluid testing method, the method has the following characteristics:
(1) the rheological parameters of the drilling fluid can be obtained without using any mechanical equipment and sensors;
(2) the measurement can be carried out in real time, and the measurement frequency reaches the second level, so that the plastic viscosity, the apparent viscosity, the dynamic shear force, the static shear force and the thixotropy of a drilling fluid system per second can be measured;
(3) after the deep learning algorithm of the rheological property of the drilling fluid based on the image is established, the drilling fluid can be copied to different application scenes (such as engineering slurry, rock-soil slurry, trenchless slurry and the like) infinitely, and the application range is wide.
Drawings
FIG. 1 is a schematic flow chart of a method for measuring rheological parameters of drilling fluid in real time based on image recognition and machine learning according to the present invention;
FIG. 2 is a graph of experimental results of the present invention when the flow of variable parameter accuracy is output in real time by the validation model when training the model;
fig. 3 is a diagram of the operating principle of the convolution kernel.
Detailed Description
The implementation, functional features and advantages of the present invention will be further described in conjunction with the following embodiments and the accompanying drawings, but the scope of the present invention is not limited to the following.
As shown in fig. 1, the implementation process of the present invention specifically comprises the following steps:
1. establishing a database:
1.1 preparing a drilling fluid system with the same volume but different rheological parameters in a beaker by adopting different additives such as a tackifier, a filtrate reducer, a viscosity reducer, a weighting agent, a surfactant, a biopolymer and the like.
1.2 stirring the drilling fluid in a beaker at the rotating speed of 300rpm, respectively taking pictures of the flowing drilling fluid system, and then measuring the drilling fluid system by using a six-speed rotational viscometer Andand (4) reading the time, and calculating the apparent viscosity, plastic viscosity, dynamic shear force, static shear force and thixotropy of the drilling fluid system.
1.3, 6000 sets of pictures of the drilling fluid system with different rheological parameters are established, and each picture corresponds to one set of rheological parameters (apparent viscosity, plastic viscosity, dynamic shear force, static shear force and thixotropy) so as to establish a data set.
1.4 80% of the dataset images were used for training and the remaining 20% were used for validation.
2. Preprocessing data;
2.1 load and format pictures.
2.2 decode the picture into tensors.
2.3 model sizing.
And 2.4, slicing the character string array to obtain a character string data set.
2.5 tagging the dataset with (picture, label) results in datasets such as (picture, apparent viscosity), (picture, plastic viscosity), (picture, dynamic shear), (picture, static shear) and (picture, thixotropy).
2.6 because the data sets are in the same order, the data sets can be packed to obtain the dimensions and types of the data sets.
3. Building a model and setting layers and compiling the model:
3.1 in convolutional neural networks, the image is first converted from a two-dimensional array (28x28 pixels) to a one-dimensional array (28x 28-784 pixels). The layer is treated as unstacked rows of pixels in the image and arranged. This layer has no parameters to learn and it simply reformats the data.
3.2 after flattening the pixels, the network will comprise a sequence of two layers. The first layer has 128 nodes (or neurons) and the second layer returns an array of length 60.
3.3 compiling the model:
before the model is ready to be trained, some additional settings are required. A loss function is first added for measuring the accuracy of the model during training, while minimizing the loss function. In addition, an optimizer is arranged to determine how the model is updated according to the data it sees and its own loss function.
3.4 the model consists of 2 convolution blocks, one maximum pool level in each convolution block. The fully connected layer has 128 cells.
The 3.5 convolution operation is implemented by the layers. conv2d and the pooling operation is implemented by the function layers. maxpolingg 2 d. Part of the code is as follows:
layers.Input((28,28,1)),
layers.Conv2D(32,3,padding='same'),
layers.Conv2D(64,3,padding='same'),
layers.MaxPooling2D(),
layers.Flatten(),
layers.Dense(10),
3.6 two classes are first defined, named ds _ train and ds _ validation, respectively. The method comprises the steps of data acquisition, taking an image os, an image _ dataset _ from _ direction function, a data processing function augmenter, a model definition and prediction function optimizer, and defining accuracy by using predictions and loss as a prediction result function. Then, 10 convolutional layers are defined, wherein the activation functions all use the rectifying linear unit layer.
3.7 convert the RGB values from [0,255] to [ -1,1] using the Inceptation function. The main codes are as follows:
ds_train=ds_train/255.0
ds_validation=ds_validation/255.0
4. training a model:
4.1 the data is substantially scrambled; then migrating the data to the model; dividing the data into different batches;
repeating the training data set; the trained variables contain two parameters: a weight and a bias; each calculation step is 100 steps, and the memory is adopted to store all data, so that the calculation speed is increased.
4.2 model learning associates images and labels, feeds training data to the model, verifies that the prediction matches the labels in the array.
43 assuming an image of size M N, given a convolution kernel W of size M N, the formula for the convolution can be defined as:
the coincidence degree of the shape of the convolution kernel and the original image is high, so that the image characteristics are extracted, if a certain region of the image is similar to the characteristics which can be detected by the convolution kernel, the region can activate the convolution kernel to obtain a high value, and conversely, if the certain region of the image is not similar to the characteristics which can be detected by the convolution kernel, the value of the region is relatively low after the convolution operation. The diversity of the convolution is increased by the sliding step size of the convolution kernel and zero padding.
In convolutional layers, a feature map is a feature output obtained by convolving an image (or other feature map) of an input layer. One convolution kernel is only responsible for extracting a certain specific feature, and a plurality of convolution kernels are used for sufficiently extracting information in an image. The general structure of a convolutional layer can be represented as follows:
(1) the set of input eigenmaps is a three-dimensional tensor (tensor), where each slice (slice) matrix is an input eigenmap.
Each feature map is of size M x N, D being the number of input feature maps.
(2) Outputting a characteristic mapping group:
wherein the set of output eigenmaps is also a three-dimensional tensor, wherein each slice matrix is similar to the input matrix:
(3) and (3) convolution kernel: each slice matrix of the convolution kernel is a two-dimensional tensor,
the convolution output calculation formula is:
referring to fig. 3, a schematic diagram of the operation of the convolution kernel is shown.
4.4 the sub-sampling layer acts as a feature selection after the convolutional layer, reducing the number of features and thus the number of parameters in the network. The feature map is divided into a plurality of regions, and then the largest neuron within a region is selected as a generalization of that region.
And 4.5, in order to improve the model training efficiency, feature extraction is adopted. Meaningful features are extracted from the new sample using representations learned from previous networking. A new classifier is added on the pre-trained model and can be trained from scratch, so that the feature map which is learned for the data set before can be reused, the whole model does not need to be (re) trained, and the model training efficiency is improved.
5. Testing rheological parameters of the drilling fluid:
stirring the drilling fluid in a field stirring pool at a rotating speed of 300rpm, collecting a drilling fluid flowing photo in a stirring state in real time through a camera, introducing the processed photo (the size is adjusted, the gray level is converted, and the like, and the requirement is the same as the requirement of a training set and a verification concentrated picture) into a trained model, and outputting drilling fluid rheological parameter values including plastic viscosity, apparent viscosity, dynamic shear force, static shear force and thixotropy by the model.
And 5.1, preprocessing the flowing picture of the drilling fluid and then leading the pretreated flowing picture into a trained model, wherein the model outputs the rheological parameter values of the drilling fluid, including plastic viscosity, apparent viscosity, dynamic shear force, static shear force and thixotropy.
And 5.2, taking the plastic viscosity of the drilling fluid as an example, and outputting the plastic viscosity value of the drilling fluid system by identifying the picture of the flowing drilling fluid. As shown in fig. 2, the drilling fluid plastic viscosity test structure based on image recognition and machine learning is tested by a six-speed rotational viscometer, and the drilling fluid plastic viscosity of 6 graphs in fig. 2 is 8, 10, 13, 15, 21 and 25mPa · s respectively. The histogram on the right side of the experimental graph is the prediction result obtained by the machine learning model. The result shows that the prediction accuracy of the machine learning model for the plastic viscosity of the drilling fluid under the situation can reach 100%.
The above description is only for the preferred embodiment of the present invention and is not intended to limit the scope of the present invention, and all equivalent structural changes made by using the contents of the present specification and the drawings, or any other related technical fields, are intended to be covered by the scope of the present invention.
Claims (10)
1. A drilling fluid rheological parameter real-time measurement method based on machine learning is characterized by comprising the following steps: and outputting rheological parameters of the drilling fluid in a flowing state in real time by adopting a mode of combining image acquisition and image recognition.
2. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 1, characterized in that: the combination of image acquisition and image recognition includes,
establishing a drilling fluid picture database, preparing drilling fluids with the same volume and different rheological parameters, respectively acquiring pictures of free liquid surfaces when the drilling fluids with different rheological parameters flow at the same set rotating speed, acquiring a plurality of pictures under the same rheological parameter, then measuring the rheological parameters of the drilling fluids, and establishing a data set in which the rheological parameters correspond to the drilling fluid pictures one to one;
step two, preprocessing data, loading and formatting the pictures in the data set obtained in the step one, adjusting the sizes of the pictures, decoding the pictures into tensors, marking each picture in the data set in a label mode, establishing a data set in a (picture and label) mode, and splitting the data set into a training set and a testing set, wherein the labels are rheological parameters corresponding to the pictures;
constructing a model, wherein a convolutional neural network model is adopted, and the output of the model is the rheological parameter of the drilling fluid;
compiling a model and a training model, wherein the compiling model comprises an optimizer, a loss function and an evaluation index, and the training model comprises the difference of the accuracy of the evaluation model on a training set and a testing set so as to adjust the model;
and step five, testing the rheological parameters of the drilling fluid, introducing the drilling fluid picture which is obtained in real time and is in the flowing state with the same rotating speed as the rotating speed in the step one into the model which is trained to be qualified in the step four, and outputting the rheological parameter values of the drilling fluid by the model.
3. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 1, characterized in that: the rheological parameters include apparent viscosity, plastic viscosity, dynamic shear force, static shear force and thixotropy.
4. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 2, characterized in that: when the rheological parameters of the drilling fluid are measured in the step one, a six-speed rotational viscometer is used for reading the drilling fluidAndreading at the rotating speed and calculating the rheological parameters of the drilling fluid.
5. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 2, characterized in that: in the first step, when drilling fluid dynamic pictures with different rheological parameters are acquired, the pictures are acquired from different angles above the free liquid level of the drilling fluid aiming at the drilling fluid with the same rheological parameter.
6. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 2, characterized in that: in the second step, the picture is adjusted to be a 28 × 28 pixel gray scale picture.
7. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 2, characterized in that: in the third step, the convolutional neural network model comprises at least 2 convolutional layers and 1 pooling layer.
8. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 7, characterized in that: in each of the 2 convolutional layers, the sizes of the convolutional kernels are 3 × 3, and the number of the convolutional kernels is 32 and 64, respectively.
9. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 2, characterized in that: in the fourth step, the evaluation index is the accuracy, and the accuracy is the percentage of correctly classified images.
10. The machine learning-based drilling fluid rheological parameter real-time measurement method according to claim 2, characterized in that: and fifthly, placing the drilling fluid to be measured in a container and continuously stirring at a stable rotating speed, and acquiring a free liquid level picture of the drilling fluid in a flowing state in real time through image acquisition equipment arranged at the drilling fluid stirring container.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111295919.4A CN114004999A (en) | 2021-11-03 | 2021-11-03 | Drilling fluid rheological parameter real-time measurement method based on machine learning |
NL2033450A NL2033450B1 (en) | 2021-11-03 | 2022-11-03 | A Real Time Measurement Method for Rheological Parameters of Drilling Fluid Based on Machine Learning |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111295919.4A CN114004999A (en) | 2021-11-03 | 2021-11-03 | Drilling fluid rheological parameter real-time measurement method based on machine learning |
Publications (1)
Publication Number | Publication Date |
---|---|
CN114004999A true CN114004999A (en) | 2022-02-01 |
Family
ID=79927003
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111295919.4A Pending CN114004999A (en) | 2021-11-03 | 2021-11-03 | Drilling fluid rheological parameter real-time measurement method based on machine learning |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN114004999A (en) |
NL (1) | NL2033450B1 (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115021986A (en) * | 2022-05-24 | 2022-09-06 | 中国科学院计算技术研究所 | Construction method and device for Internet of things equipment identification deployable model |
CN115907236A (en) * | 2023-02-17 | 2023-04-04 | 西南石油大学 | Underground complex condition prediction method based on improved decision tree |
CN116212722A (en) * | 2023-05-08 | 2023-06-06 | 中国汽车技术研究中心有限公司 | Automobile collision dummy skin raw material treatment control method and treatment device |
CN116297016A (en) * | 2023-05-23 | 2023-06-23 | 武汉誉城千里建工有限公司 | Full-automatic online detection device and detection method for drilling fluid performance |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101446198A (en) | 2008-07-11 | 2009-06-03 | 杨晖 | Apparatus for automatic and continuous measurement of delivery capacity, specific gravity and viscosity of drilling mud |
CN102140911A (en) | 2010-10-13 | 2011-08-03 | 中国石油天然气股份有限公司 | Method and device for acquiring viscosity and density of drilling fluids in drilling process |
WO2020221644A1 (en) * | 2019-04-29 | 2020-11-05 | Bayer Aktiengesellschaft | Determination of the rheological behavior of a fluid |
-
2021
- 2021-11-03 CN CN202111295919.4A patent/CN114004999A/en active Pending
-
2022
- 2022-11-03 NL NL2033450A patent/NL2033450B1/en active
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115021986A (en) * | 2022-05-24 | 2022-09-06 | 中国科学院计算技术研究所 | Construction method and device for Internet of things equipment identification deployable model |
CN115907236A (en) * | 2023-02-17 | 2023-04-04 | 西南石油大学 | Underground complex condition prediction method based on improved decision tree |
CN115907236B (en) * | 2023-02-17 | 2023-11-03 | 西南石油大学 | Underground complex situation prediction method based on improved decision tree |
CN116212722A (en) * | 2023-05-08 | 2023-06-06 | 中国汽车技术研究中心有限公司 | Automobile collision dummy skin raw material treatment control method and treatment device |
CN116212722B (en) * | 2023-05-08 | 2023-09-01 | 中国汽车技术研究中心有限公司 | Automobile collision dummy skin raw material treatment control method |
CN116297016A (en) * | 2023-05-23 | 2023-06-23 | 武汉誉城千里建工有限公司 | Full-automatic online detection device and detection method for drilling fluid performance |
CN116297016B (en) * | 2023-05-23 | 2023-09-19 | 武汉誉城千里建工有限公司 | Full-automatic online detection device and detection method for drilling fluid performance |
Also Published As
Publication number | Publication date |
---|---|
NL2033450A (en) | 2023-06-01 |
NL2033450B1 (en) | 2024-01-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN114004999A (en) | Drilling fluid rheological parameter real-time measurement method based on machine learning | |
Li et al. | An image recognition method for the deformation area of open-pit rock slopes under variable rainfall | |
Buscombe | SediNet: A configurable deep learning model for mixed qualitative and quantitative optical granulometry | |
Karimpouli et al. | Coal cleat/fracture segmentation using convolutional neural networks | |
CN103026202A (en) | Method for obtaining consistent and integrated physical properties of porous media | |
Hacıefendioğlu et al. | Landslide detection using visualization techniques for deep convolutional neural network models | |
Moradi et al. | Inversion of well logs into rock types, lithofacies and environmental facies, using pattern recognition, a case study of carbonate Sarvak Formation | |
US20210090239A1 (en) | Automating Microfacies Analysis of Petrographic Images | |
CN112163496A (en) | Embedded terminal reservoir water level early warning method based on semantic segmentation | |
WO2022046795A1 (en) | System and method for detection of carbonate core features from core images | |
CN110532974B (en) | High-resolution remote sensing geological disaster information automatic extraction method based on deep learning | |
Chandan et al. | An intelligent model for indian soil classification using various machine learning techniques | |
CN112085725B (en) | Residual film residual quantity detection method and early warning system based on heuristic iterative algorithm | |
Abedini et al. | Porosity classification from thin sections using image analysis and neural networks including shallow and deep learning in Jahrum formation | |
Mokhtari et al. | Feasibility study of EPB shield automation using deep learning | |
Zhou et al. | Knowledge-based U-Net and transfer learning for automatic boundary segmentation | |
CN113688901A (en) | Reservoir discontinuous boundary identification method based on expansion convolution neural network | |
Shi et al. | Semi-universal geo-crack detection by machine learning | |
Sattarin et al. | GeoPixAI: from pixels to intelligent, unbiased and automated fast track subsurface characterization | |
Zhan et al. | Accelerate fine-scale geological mapping with UAV and convolutional neural networks | |
Grant et al. | Leveraging spatial metadata in machine learning for improved objective quantification of geological drill core | |
Yi et al. | Rock mass structural surface trace extraction based on transfer learning | |
CN117351212B (en) | Point cloud segmentation method based on bidirectional multi-scale attention under water conservancy environment | |
TSURUTA et al. | Development of an Automated System for the Evaluation and 3D Modelling of Site Geological Strata Using Artificial Intelligence | |
Yang et al. | Artificial Intelligence In Source Discrimination of Mine Water: A Deep Learning Algorithm For Water Source Discrimination |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |