An intelligent identification method for gas-liquid two-phase spiral flow pattern in a horizontal circular tube
The two-phase distribution images of gas-liquid phases are processed by high-speed cameras, and the gas-containing fluctuation signal is extracted and PDF curves are generated. Multi-dimensional feature vectors are constructed. The two-phase spiral flow patterns of gas-liquid phases in a horizontal circular tube are used to identify the problem of lack of recognition in the existing technology and achieve efficient and accurate recognition effects.
Patent Information
- Application Number
- CN202310194202.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-02
- Publication Date
- 2025-04-01
- Estimated Expiration
- 2043-03-02
AI Technical Summary
The prior art lacks the identification of the two-phase spiral flow patterns of gas-liquid and liquid spiral flow in a horizontal circular tube.
A high-speed camera is used to capture images of the distribution of gas-liquid and liquid phases over time, and the binary images of the gas-liquid phase interface are obtained through batch processing of software, the fluctuation value of the gas-liquid ratio over time is extracted, the PDF curve is generated, a multi-dimensional feature vector is constructed, and a variety of machine learning algorithms are used for identification.
Intelligent recognition of the two-phase spiral flow type of gas-liquid in a horizontal circular tube is achieved, avoiding interference to flow, reducing the dimension of the feature vector, relatively small calculation amount, and high recognition accuracy.
Smart Images

Figure CN116341213B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of gas-liquid two-phase spiral flow measurement, and in particular to an intelligent identification method for the flow pattern of the gas-liquid two-phase spiral flow in a horizontal circular tube. Background Art
[0002] Gas-liquid two-phase flow is widely present in nature and industry. The two-phase flow pattern reflects the macroscopic structure of the phase interface and the state characteristics of the macroscopic distribution of each phase. The flow and heat transfer characteristics of different flow patterns are different. The control method of changing the original flow pattern by artificial methods is an effective method commonly used in industry to improve the flow characteristics of gas-liquid two-phase. Spiral flow is a flow that has both axial and tangential velocity components, and the tangential velocity cannot be ignored. It has the characteristics of energy concentration, strong carrying capacity and high conveying depth. It is an effective flow pattern control method widely used in the industrial field. The gas-liquid two-phase spiral flow pattern is the basis for studying gas-liquid two-phase flow, and is crucial to the gas-liquid two-phase flow characteristics, resistance characteristics and heat and mass transfer performance. The prior art lacks the identification of the gas-liquid two-phase spiral flow pattern in the horizontal circular tube. Summary of the invention
[0003] Based on this, in order to solve the problem of lack of recognition of the flow pattern of gas-liquid two-phase spiral flow in a horizontal circular tube in the prior art, the present invention provides an intelligent recognition method for the flow pattern of gas-liquid two-phase spiral flow in a horizontal circular tube, and its specific technical solution is as follows:
[0004] An intelligent identification method for a gas-liquid two-phase spiral flow pattern in a horizontal circular tube comprises the following steps:
[0005] Step S1, using a high-speed camera to capture images of the gas-liquid two-phase distribution changing with time over a continuous period of time under different working conditions, manually identifying the fluid images obtained by high-speed photography and recording the flow patterns of the gas-liquid two-phase spiral flow under different working conditions;
[0006] Step S2, using software to batch process the captured images to obtain a binary image with a clear gas-liquid phase boundary;
[0007] Step S3, obtaining the fluctuation value of gas content over time based on the image processing method;
[0008] Step S4, extracting features of the fluctuation signal of the gas content changing with time and generating a PDF curve;
[0009] Step S5, constructing a multidimensional feature vector based on multiple feature parameters summarized from the extracted PDF curve;
[0010] Step S6, using a variety of machine learning algorithms, inputting multidimensional feature vectors of all working conditions, and dividing all working conditions into a training set and a validation set;
[0011] Step S7: analyzing the accuracy of the results identified by the various machine learning algorithms.
[0012] Preferably, the device for photographing the gas-liquid spiral flow pattern includes a high-speed camera, a computer, an LED light source, white rice paper, transparent square bricks, a vortexer, a transparent plexiglass tube and a flange. Flanges are installed at both ends of the horizontally placed transparent plexiglass tube and a vortexer is installed at one inner end. A high-speed camera connected to a computer is placed directly in front of a test section of the transparent plexiglass tube, an LED light source is placed directly behind the test section and white rice paper is set between the test section and the LED light source, and a transparent square brick is covered on the periphery of the test section.
[0013] Preferably, the size of the flow image collected by the high-speed camera is 912*168 and the frame rate is 2000 frames / s.
[0014] Preferably, the gas-liquid two-phase spiral flow pattern includes stratified flow, spiral gas column flow, spiral bubbly flow, spiral intermittent flow and spiral annular flow.
[0015] Preferably, the process of batch processing the captured images using software to obtain a clear binary picture of the gas-liquid interface includes image cropping, uniform illumination, contrast enhancement, image filtering, image binarization and image filling.
[0016] Preferably, the fluctuation value of the gas content over time is obtained based on the image processing method. The gas content is obtained by selecting a cross section with a pixel width at a fixed position Z perpendicular to the flow direction, and the ratio of the area of the gas phase at Z to the area of the pipeline cross section is used to obtain the gas content; the gas content at a fixed position Z of multiple consecutive images within the same operating time period is used to obtain the fluctuation value of the gas content at Z within the time period.
[0017] Preferably, the four characteristic parameters of the PDF curve are the number of peaks, the gas content value corresponding to the main peak, the main peak peak value and the variance of the PDF.
[0018] Preferably, the multiple machine learning algorithms include DT, SVM, KNN, NB and RUSBoost tree.
[0019] The present invention has the following beneficial technical effects:
[0020] 1. An intelligent identification method for a gas-liquid two-phase spiral flow pattern in a horizontal circular tube provided by an embodiment of the present invention adopts a non-contact measurement method to obtain gas content data, thereby avoiding influence on the flow.
[0021] 2. An intelligent identification method for a gas-liquid two-phase spiral flow pattern in a horizontal circular tube provided in an embodiment of the present invention extracts four key parameters from the gas content fluctuation signal of each operating condition as feature vectors, and intelligently identifies the gas-liquid two-phase spiral flow pattern in the horizontal tube, thereby reducing the dimension of the feature vector and requiring relatively little calculation. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] The present invention can be further understood from the following description in conjunction with the accompanying drawings. The components in the figures are not necessarily drawn to scale, but the emphasis is placed on illustrating the principles of the embodiments. In different views, the same reference numerals designate corresponding parts.
[0023] Figure 1 is a flow chart of intelligent identification of gas-liquid two-phase spiral flow in a horizontal pipe in one embodiment of the present invention;
[0024] Figure 2 is a photographic schematic diagram of a gas-liquid spiral flow pattern in one embodiment of the present invention;
[0025] Figure 3 is a flow chart of processing a gas-liquid spiral flow pattern image in one embodiment of the present invention;
[0026] Figure 4 is a schematic diagram of calculating the gas content rate of a spiral flow pattern cross section of a gas-containing column in one embodiment of the present invention;
[0027] Figure 5 is a schematic diagram of calculating the gas content of a cross section of a stratified flow pattern in one embodiment of the present invention;
[0028] Figure 6 is a fluctuation curve of gas content over time in one embodiment of the present invention;
[0029] Figure 7 is a PDF (probability density function) curve of gas content in one embodiment of the present invention;
[0030] Description of reference numerals:
[0031] 1. High-speed camera; 2. Computer; 3. LED light source; 4. White rice paper; 5. Transparent square bricks; 6. Rotator; 7. Transparent plexiglass tube; 8. Flange. DETAILED DESCRIPTION
[0032] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with its embodiments. It should be understood that the specific implementation methods described herein are only used to explain the present invention and do not limit the protection scope of the present invention.
[0033] It should be noted that when an element is referred to as being "fixed to" another element, it may be directly on the other element or there may be a central element. When an element is considered to be "connected to" another element, it may be directly connected to the other element or there may be a central element at the same time. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only and do not represent the only implementation method.
[0034] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. The terms used herein in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more related listed items.
[0035] The “first” and “second” mentioned in the present invention do not represent specific quantities and orders, but are merely used to distinguish names.
[0036] like Figure 1 As shown, an intelligent identification method of a gas-liquid two-phase spiral flow pattern in a horizontal circular tube in one embodiment of the present invention comprises the following steps:
[0037] Step S1, using a high-speed camera to capture images of the gas-liquid two-phase distribution changing with time over a continuous period of time under different working conditions, manually identifying the fluid images obtained by high-speed photography and recording the flow patterns of the gas-liquid two-phase spiral flow under different working conditions;
[0038] Step S2, using software to batch process the captured images to obtain a binary image with a clear gas-liquid phase boundary;
[0039] Step S3, obtaining the fluctuation value of gas content over time based on the image processing method;
[0040] Step S4, extracting features of the fluctuation signal of the gas content changing with time and generating a PDF (probability density function) curve;
[0041] Step S5, constructing a multidimensional feature vector based on multiple feature parameters summarized from the extracted PDF curve;
[0042] Step S6, using a variety of machine learning algorithms, inputting multidimensional feature vectors of all working conditions, and dividing all working conditions into a training set and a validation set;
[0043] Step S7: analyzing the accuracy of the results identified by the various machine learning algorithms.
[0044] like Figure 2As shown, in one of the embodiments, flanges 8 are fixed at both ends of a transparent organic glass tube 7 and the test section is surrounded by transparent square bricks 5, a high-speed camera 1 is placed in front of the test section and connected to a computer 2, an LED light source 3 is placed behind the test section and white rice paper 4 is provided between the LED light source 3 and the test section to obtain a uniform backlight, thereby improving the shooting effect, and a spiral flow is generated by a vortex generator 6 installed at the flange 8, and the gas-liquid spiral flow pattern under different working conditions is recorded, and a flow pattern image with a size of 912×168 and a frame rate of 2000 frames / s is collected in real time.
[0045] The non-contact measurement method is used to obtain the gas-liquid distribution information in the spiral flow, which avoids flow interference compared with the contact measurement method.
[0046] The gas-liquid two-phase spiral flow patterns include stratified flow, spiral gas column flow, spiral bubbly flow, spiral intermittent flow and spiral annular flow.
[0047] like Figure 3 As shown, in one embodiment, Matlab software is used to process the captured image to obtain a clear binary image of the gas-liquid interface, and the processing process includes the following steps:
[0048] Step S201, reduce the influence of redundant images, and use the "imcrop" function to crop the original image to the required position, so that the measurement result is more accurate;
[0049] Step S202, using the morphological processing methods "imtophat" and "imbothat" functions to reduce the influence of uneven illumination in some areas of the image;
[0050] Step S203, using a histogram to adjust the "imadjust" function to improve the contrast between the gas-liquid interface and the background in the image;
[0051] Step S204: using a median filter function (“medfilter”) with a sliding window of 3×3 to filter the image noise so as to reduce the image noise;
[0052] Step S205, using Ostu's method to perform threshold segmentation on the image, converting the image from grayscale mode to binary mode, on this basis, using the "graythresh" function to calculate the optimal threshold for gas-liquid interface recognition, or manually inputting the threshold. After the threshold is defined, using the "im2bw" function to obtain a binary image, the image is composed of pixels, and the values of the pixels of the binary image are only 0 and 1. In the binary image, black (pixel value is 0) represents the gas phase, and white (pixel value is 1) represents the liquid phase;
[0053] Step S206: Since the brightness of the original image is uneven, the gas phase area of the binary image is not completely dark, and "imfill" and "imcomplement" are used to fill the blank space in the gas core area.
[0054] like Figure 4 As shown, in one embodiment, the spiral flow pattern containing gas columns, at a fixed position Z perpendicular to the flow direction, takes a pixel width section AA, the length of all black pixels in the section is the diameter of the gas core in the spiral flow, the gas-liquid interface in the flow appears as an irregular circle, the gas core is abstracted as a smooth circle, and the cross-sectional gas content α is calculated as follows:
[0055]
[0056] A is the area of the pipe cross section; A g is the area of the gas phase occupying the cross-sectional area of the pipe; d i is the sum of the number of black pixels in this column of the binary image, which is the diameter of the gas core; D is the sum of the number of pixels in this column, which is the diameter of the pipe section. The above formula is applicable to spiral gas column flow, spiral annular flow, spiral annular flow and spiral intermittent flow.
[0057] like Figure 5 As shown, in one embodiment, the gas phase in the stratified flow type tube is distributed at the top of the tube, and the liquid phase is distributed at the bottom of the tube. Similarly, at a fixed position Z along the axial direction, a section AA with a width of one pixel is taken. In the binary image, the black pixels are at the top and the white pixels are at the bottom. Due to the fluctuation of the gas-liquid interface, the liquid phase is irregularly shaped, which is abstracted as a regular sector. The calculation formula of the gas content α of the section is as follows:
[0058]
[0059] r is the radius of the pipe section and h is the height of the liquid phase.
[0060] like Figure 6 As shown, in one embodiment, the gas content is obtained by selecting a section with a pixel width at a fixed position Z perpendicular to the flow direction, and the ratio of the area of the gas phase in the pipe cross section to the area of the pipe cross section of the section; the gas content at a fixed position Z of multiple consecutive images within the same operating time period is used to obtain the fluctuation value of the gas content value at Z within the operating time period over time.
[0061] like Figure 7 As shown, in one embodiment, the fluctuation signal of the gas content α over time is statistically analyzed, and a PDF curve of the gas content α in the gas-liquid two-phase spiral flow is plotted, wherein the mathematical description of PDF is:
[0062]
[0063] In one embodiment, the four characteristic parameters of the PDF curve include the number of peaks P1, the gas content value corresponding to the main peak P2, the main peak peak value P3 and the PDF variance P4, and the characteristic parameters of the PDF curve of some flow types are shown in Table 1. The four characteristic parameters construct a 4-dimensional characteristic vector.
[0064] Four key characteristic parameters are selected from the gas content fluctuation signal of each operating condition as the feature vector, which reduces the dimension of the feature vector and reduces the amount of calculation.
[0065]
[0066] Table 1
[0067] In one of the embodiments, the four features of the PDF curve are converted into a 4-dimensional feature vector as the input feature vector for machine learning. For all 420 working conditions, five machine learning algorithms, DT, SVM, KNN, NB and RUSBoost tree, are used. The 4-dimensional feature vector of each working condition is input, 80% of the working conditions are used as training sets, and 20% of the working conditions are used as validation sets, and the accuracy of the five algorithms is obtained.
[0068] Different machine learning algorithms were used to identify the gas-liquid two-phase spiral flow pattern in the horizontal tube, and it was found that the RUSBoost tree algorithm had the highest recognition accuracy of 97.4%, as shown in Table 2 for the recognition accuracy of different machine learning algorithms. Table 3 shows the flow pattern recognition results of the RUSBoost tree algorithm. The RUSBoost tree algorithm has a 100% accuracy rate for identifying the spiral annular flow pattern and a 94% accuracy rate for identifying the spiral gas column flow, spiral bubbly flow, and spiral intermittent flow patterns.
[0069]
[0070] Table 2
[0071]
[0072] Table 3
[0073] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0074] The above-mentioned embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
Claims
1. An intelligent identification method for gas-liquid two-phase spiral flow pattern in a horizontal circular tube, characterized in that: The following steps are involved: Step S1, using a high-speed camera to capture images of the gas-liquid two-phase distribution changing with time over a continuous period of time under different working conditions, manually identifying the fluid images obtained by high-speed photography and recording the flow patterns of the gas-liquid two-phase spiral flow under different working conditions; Step S2, using software to batch process the captured images to obtain a binary image with a clear gas-liquid phase boundary; Step S3, obtaining the fluctuation value of gas content over time based on the image processing method; Step S4, extracting features of the fluctuation signal of the gas content changing with time and generating a PDF curve; Step S5, constructing a multidimensional feature vector based on multiple feature parameters summarized from the extracted PDF curve; Step S6, using a variety of machine learning algorithms, inputting multidimensional feature vectors of all working conditions, and dividing all working conditions into a training set and a validation set; Step S7, analyzing the accuracy of the results identified by multiple machine learning algorithms; Based on the image processing method, the fluctuation value of the gas content over time is obtained. The gas content is obtained by selecting a cross section with a pixel width at a fixed position Z perpendicular to the flow direction. The ratio of the area of the gas phase in the pipe cross section at Z to the area of the pipe cross section is used to obtain the gas content. The length of all black pixels in the cross section is the diameter of the gas core in the spiral flow. The gas-liquid interface in the flow appears as an irregular circle. The gas core is abstracted as a smooth circle. The cross-sectional gas content α is calculated as follows: The gas content at a fixed position Z of multiple consecutive images within the same working condition time period is obtained to obtain the fluctuation value of the gas content at Z over time within the time period; A is the area of the pipe cross section; A g is the area of the pipeline cross section occupied by the gas phase; d i is the sum of the number of black pixels in this column of the binary image, which is the diameter of the gas core; D is the sum of the number of pixels in this column, which is the diameter of the tube segment; For the stratified flow pattern, the gas phase in the pipe is distributed at the top of the pipe, and the liquid phase is distributed at the bottom of the pipe. At a fixed position Z along the axial direction, a section AA with a pixel width is taken. In the binary image, the black pixels are at the top and the white pixels are at the bottom. Due to the fluctuation of the gas-liquid interface, the liquid phase is an irregular fan shape, which is abstracted as a regular fan shape. The calculation formula of the cross-sectional gas content α is as follows: r is the radius of the pipe section and h is the height of the liquid phase.
2. The intelligent identification method of the gas-liquid two-phase spiral flow pattern in a horizontal circular tube according to claim 1, characterized in that: The device for photographing the gas-liquid spiral flow pattern includes a high-speed camera, a computer, an LED light source, white rice paper, a transparent square brick, a vortexer, a transparent plexiglass tube and a flange. Flanges are installed at both ends of the horizontally placed transparent plexiglass tube, and a vortexer is installed at one inner end. A high-speed camera connected to a computer is placed directly in front of a test section of the transparent plexiglass tube, an LED light source is placed directly behind the test section, and white rice paper is set between the test section and the LED light source, and a transparent square brick is covered on the periphery of the test section.
3. The intelligent identification method of the gas-liquid two-phase spiral flow pattern in a horizontal circular tube according to claim 1, characterized in that: The flow image captured by the high-speed camera has a size of 912*168 and a frame rate of 2000 frames / s.
4. The intelligent identification method of the gas-liquid two-phase spiral flow pattern in a horizontal circular tube according to claim 1, characterized in that: The gas-liquid two-phase spiral flow patterns include stratified flow, spiral gas column flow, spiral bubbly flow, spiral intermittent flow and spiral annular flow.
5. The intelligent identification method of the gas-liquid two-phase spiral flow pattern in a horizontal circular tube according to claim 1, characterized in that: The process of batch processing the captured images using software to obtain a clear binary picture of the gas-liquid interface includes image cropping, uniform illumination, contrast enhancement, image filtering, image binarization, and image filling.
6. The intelligent identification method of the gas-liquid two-phase spiral flow pattern in a horizontal circular tube according to claim 1, characterized in that: The four characteristic parameters of the PDF curve are the number of peaks, the gas fraction value corresponding to the main peak, the peak value of the main peak and the variance of PDF.
7. The intelligent identification method of the gas-liquid two-phase spiral flow pattern in a horizontal circular tube according to claim 1, characterized in that: The multiple machine learning algorithms include DT, SVM, KNN, NB and RUSBoost tree.
Citation Information
Patent Citations
Two-phase fluid flow pattern identification method based on time sequence and neural net pattern identification
CN1664555A