Submersible Pump Vortex Detection Using Image Processing Technique and Neuro-Fuzzy

The vortex means the mass of air or water that spins around very fast that often faced in the agriculture irrigation systems used the pump. The undesired effects like loss of hydraulic performance, erosion, vibration and noise may occur because of the vortex in pump systems. It is important to detect and prevent vortex for the economic life and efficiency of the agriculture pump. The image processing and neuro-fuzzy based novel model is proposed for the detection of a vortex in the deep well pump used in the agriculture system with this paper. The used images and data submergence, flow rate, the diameter of the pipe, power consumption, pressure values and noise values- is acquired from an experimental pump. The proposed approach consists of three steps; Neuro-Fuzzy Learning, Image Processing and Neuro-Fuzzy Testing. In the first step, the eighty-two data have employed for the training process of the Neuro-Fuzzy. Then, the images derived from a camera placed near the experimental pump are used to detect vortex in the image processing step. Finally, the relevant data to vortex cases have employed for the testing process of the Neuro-Fuzzy. The result of this study demonstrates that image processing and neuro-fuzzy based design can be successfully used to detect vortex formation. This paper has provided novel contributions in the vortex detection issue such as find out vortex cases by using image processing and Neuro-Fuzzy. The image processing method has shed light on the studies to be done in the classification of vortexes and the measurement of their strength.


Introduction
The submersible deep well pumps are one of the most used irrigation systems in the agriculture field. So, the pump's efficient operation is a significant factor for modern agriculture. The vortex is one of the factors that adversely affect the efficiency of the pump can occur due to pumps are placed at low submergence. The vortex causes that the air inlet interferes with the pump wing. Then, it affects negatively the efficiency and economic life of the pump [1].
The vortex formed by the effect of the diameter and height of the water inlet pipe in the pumps causes the pressure of the pump to decrease and to work more loudly [2,3]. Also, the vortex of deep well pumps causes the cavitation that is a physical effect that adversely affects performance in pump applications, causes abrasions in pump elements and causes severe reductions in pump life [4]. To prevent vortex formation, the submersible deep well pumps must be operated at the safe boundary [5].
The vortex cavitation directly depends on the submergence. Also, vortex causes the pump to operate loudly and vibration [6]. The noise and vibration caused by the pressure changes cause the pump to move away from the optimum efficiency point [7,8]. In the case of the vortex of pumps the noise levels that occur are different values according to the cavitation-free state. The noise frequency and levels in the case of vortex cavitation are specified as 147 Hz to 70-80 dBA [9]. It is also indicated that noise level is differentiated in the case of vortex cavitation-free operation and vortex cavitation estimation can be done from noise level measurements [9]. So, immersion depth, noise and pressure are important parameters to observe various types of the vortex and determine the beginning of vortex.
An artificial intelligence (AI) and image processing-based approach to determine the vortex problem in deep well pumps is proposed with this paper. The AI-based methods are being developed as an alternative approach for problem detection in many engineering applications. An example of this is to analyze the signal obtained from the vibration by means of fuzzy logic [10,11]. It is proposed a model for the fault detection of a pumping system using a feed forward network with back propagation algorithm and binary adaptive resonance network [12]. The Support Vector Machines (SVMs) based model for detecting and classifying pump faults is presented [13]. The hybrid approach that consists of the decision tree and fuzzy classifier is proposed for creating rules from statistical parameters extracted from vibration signals under both conditions (good and faulty) [14]. It has been used as an artificial immune recognition system for the fault classification of the centrifugal pump [15]. The fuzzy neural network has used for classification to determine errors and differentiate between error type [16]. The other study illustrated an artificial neural network (ANN)-based approach for fault detection and identification in gearboxes [17]. It is discussed an ANFIS based error diagnosis model for induction motor [18].
In this study, an approach to detect vortex cavitation in submersible pumps using adaptive neural fuzzy networks is presented. The presented study is outlined as follows Section 2 describes the data collection system that enables the acquisition of the experimental environment and the data used in this study. In section 3, adaptive neural fuzzy networks are defined and their layers are given in detail. The networks, network structures and parameters used to determine cavitation in the pumps are described in Section 4. Section 5 concludes the manuscript.

Model of Experimental Pump
This study was carried out in the Department of Agricultural Machinery and Technology Engineering of the Faculty of Agriculture of Selcuk University in the Deep Well Pump Test Tower (Figure 1), which was established under the project number TUBITAK 213O140. As seen in Figure  1, an experimental setup was developed to study the behavior of water in deep wells during pumping in deep wells. In the different submergence, the speed of the water at different points of the well and the pump, the output pressure of the pump, the level of fall in the well, the power the pump draws from the network, and the noise level generated is instantaneously measured. In addition, water movements detected by video cameras (K1-K2) located at two different points of the well were recorded. Pump submergence (S), flow rate (Q), pump diameter (D), power consumption (N), pressure values (P) and noise (G) values obtained from the experimental environment were used in network training.

Figure 1. Deep well pump test tower and installations
A typical submersible deep well pump placed in the well is given in Figure 2 as the basic elevation terms appropriate to the terminology.  Table 1. For pump actuation, 4 kW motor was used for D1 pump and 5.5 kW motors were used for D2 and D3 pumps. Technical specifications for measurement devices used in present experiments are provided in Table 2. Test assembly with deep wells equipment is high 10 m. Test assembly is kept constant during trials 4 m plexiglass pipe and 2 m well screen pipe from the bottom, 4 m steel casing pipe. Besides around the well screen pipe of 10 cm in width has filled with gravel which bulk density 1,54 kg m-3 geometrical diameter between 7-15 mm. Thus, it has formed environmental working of a deep well. The submersible pump has mounted form may seem at plexiglass pipe 2 m column pipe by connecting ( Figure 3). The standard of EN ISO 9906 is used for measurements and calculations of the pump operating characteristics and the standard of EN ISO 3740 is a measurement of the noise level. The noise meter which is next to the drain header has remained stationary throughout the whole measurement. Two cameras for side-view and top-view are used to view the vortex cavitation. The place of the camera for top-view is changed according to the water level and the camera angle. The side camera is connected to the outside of the transparent pipe in order to track the pump-inlet and the of vortex cavitation (See Figure 3).
Experiments were conducted at an 1880 mm pump submergence depth (constant hydraulic head). Depression was measured with a water level meter and submergence was calculated with the aid of Equation 1; where; S= Submergence depth (mm) and Δ = Depression (mm). Figure 4 and Figure 5 show images of vortex cavitation occurring at low submergence.

Record Process
A software and automation system has been implemented to record the measured quantities in the study. The block diagram of this system is given in Figure 6. As you can see from the block diagram, the information received from the sensors in the system is transferred to the computer wirelessly (Bluetooth) via a central data collection card (Figure 7).  The information stored in the central processor is registered with the appropriate names at the intervals requested by the operator via the software interface prepared on the computer. The recording system is designed for can receive one data at each second. After the pump has entered the regime, the recording process has started and 50 data have been received from a sensor. The average of these data is given in tables (Table 3). The submersible pump has taken measurements at 5-7 different dynamic levels for each of the 4 different flow ranges (40-50-55-60 m 3 h -1 ) at the optimum operating speed. The pump is operated at any specified flow rate and the immersion depth is reduced after the initial values are recorded. With the drop of the water level, the changing flow rate is readjusted by the valve in the measuring pipe. In this way, five different levels of immersion depth measurements at one flow rate are recorded and displayed.

Methods
In Section 3, it is presented the basic theory of Neuro-Fuzzy and Image Processing.

Neuro-Fuzzy
Detailed coverage of Neuro-Fuzzy -also known as ANFIS-can be found in [19,20]. An adaptive neuro-fuzzy inference system (ANFIS) developed by Jang is a hybrid artificial intelligence method that uses parallel computing and learning the ability of artificial neural networks and fuzzy logic extraction [20,21]. ANFIS consists of if-then rules and couples of input-output which as a part of fuzzy logic. The learning algorithms of the neural network are used for the training process in the ANFIS model [22][23][24][25].
Adaptive networks consist of directly connected nodes [26]. Each node represents a processing unit. The links between the nodes indicate an irrelevant (weight) value between them that is not quite obvious. Adaptation is established by determining the outputs of these nodes with variable parameters. The learning rules determine how the variable parameters change the difference between the output of the entire network and the target value (the minimized error value).
ANFIS is one of the very powerful approaches to establishing a complex, nonlinear relationship between a set of input and output data sets [27]. ANFIS consists of a set of rules and input/output information pairs in the fuzzy inference system [28]. ANFIS can make rules for the problem or make use of expert opinions to create rules possible.

Figure 8. ANFIS architecture
The ANFIS' architecture with two inputs and one output is as shown in Figure 8. ANFIS architecture consists of 5 different layers [20,24,29]. These layers are as follows; Layer 1: It is also called the fuzzification layer. The fuzzification layer fuzzyfies the input signals. The output of each node consists of membership values that depend on the input values and the membership function used. The node output is the result of a predetermined membership function.
Layer 2: Rule layer. Each node in this layer represents the rules and number of rules generated by the fuzzy logic inference system. Layer 3: Normalization layer. Each node in this layer accepts all nodes coming from the rule layer as input values and calculates the normalized value of each rule.
Layer 4: Defuzzification layer. The weighted result values of a given rule are calculated at each node in the defuzzification layer. The parameters in this layer are called result parameters.
Layer 5: This layer has only one node and is labeled with Σ. Here, the output value of each node in the fourth layer is summed up, resulting in the real value of the ANFIS system.
The most important parameters of an ANFIS structure are the initial and result parameters. The data to be used in education are introduced to the artificial neural network and the input-output functional relation of the training data is best learned with a random training algorithm. This is an optimization process. It is aimed to determine the minimum conditions (difference function) between the model output and the output of the training data, that is, to determine the appropriate values of the parameters [29].

Image Processing
In today's technology, it is easy to create images and videos or to access images and videos. The interpretation of human being by seeing their surroundings revealed the idea that images and videos can be used for decisionmaking, detection, recognition, etc. purposes. The resulting image processing area includes all kinds of mathematical operations on the image or video frame. Using image processing, the image is processed to obtain the desired results, resulting in either a new image or numerical values (e.g. features). Obtaining numerical values is called computer vision. Denoising, image enhancement, image restoration, image segmentation, feature extraction, object recognition etc. tasks are performed using image processing [30,31]. These tasks are used for different purposes in many different areas such as security [32], medical [33,34], military [35], agricultural [36,37], robotics [38]. From a computer's point of view, the image consists of a foreground of objects of interest and background representing everything except the foreground. If both of these can be strongly parsed, object detection and object recognition tasks are completed successfully. While object detection determines the existence and location of an object, object recognition identifies the class to which the object belongs [39]. Both are a fundamental requirement that most computer and robot vision systems need. However, successful object recognition depends on object detection. The general image processing steps for object recognition are shown in Figure 9. As a result of recent studies, there has been rapid and successful progress for both tasks. The strongest reason for this is the development of computer performance and therefore the successful implementation of machine learning methods [40]. Using machine learning methods, the presence or classification of an object or event can be easily accomplished.

Submersible Pump Vortex Detection Using Image Processing Technique and Neuro-Fuzzy
The proposed submersible pump vortex detection using Image Processing and Neuro-Fuzzy approach consists of three steps; Neuro-Fuzzy Learning, Image Processing and Neuro-Fuzzy Testing.

Neuro-Fuzzy Learning
The research data used in this study derived from the experimental pump (submergence, flow rate, the diameter of the pipe, power consumption, pressure and noise values) were used to train the Neuro-Fuzzy. These parameters are given as input of ANFIS while the corresponding status of cavitation (1 or 0) was given a target, as indicated in Figure  10. In this figure, the parameters are taken from Table 3.
Totally, the eighty-two data were utilized for the training process. The used ANFIS parameter values are shown in Table 4. The triangular-shaped membership function (MF) was selected as an input member function, and the linear function was used for output.   Figure 11. Comparative results of training and ANFIS training outputs.
As illustrated in Figure 11, the experimental and training results are in very good agreement. The value of the average percentage error (APE) was found to be 0,08 for 82 data.

Detection of Vortex Cavitation Using Image Processing
In the mechanism shown in Figure 11, water movements were recorded using cameras placed at points K1 and K2 near the pump. These movements were analyzed by image processing methods and cavitations were determined. Because the cameras are stationary, it is relatively easy to detect moving parts (cavitations) on recorded images. The common method used for stationary camera applications is the background extraction method. The algorithm detects the stationary part, the background, and can capture the moving objects on the background. Because of this, the image specified as the background is subtracted from the subsequent frame. It is fast due to its simplicity. It is also the desired speed in real-time applications. However, it is a disadvantage of this method that it captures all background changes and is sensitive to undesirable changes.
Background subtraction has been successfully applied for this study. Figure 12 shows the image processing steps for detecting vortex cavitation. According to this, firstly, frames are obtained from videos recorded with the camera. The background is subtracted from each frame. Using a black-and-white (BW) mask, changes to the specific region are considered, rather than all background changes. For this, the background changes multiply with the mask so that only the region of vortex change is indicated. The next step is morphological operations for the exact determination of vortex blobs. Noise can be removed by removing noise. As a result, a vortex is detected. The final step is to determine the position of the vortex by the blob analysis methods and form a rectangle around the vortex (bounding box). Figure 11 shows the vortex in both BW and Red-Green-Blue (RGB) frames. These steps have been applied to all video frames. Because the background subtraction is fast, this application can be implemented in real time. As a result of the steps performed as in Figure  11, the BW and RGB results of the detected vortices of the different frames are shown in Figure 13.

Conclusion and Discussion
In this study, an approach to detect vortex cavitation in submersible pumps using Neuro-Fuzzy and Image Processing is presented. The presented approach consists of three steps; Neuro-Fuzzy learning, Image Processing and Neuro-Fuzzy Testing. Firstly, the research data used in this study derived from the experimental pump (submergence, flow rate, the diameter of the pipe, power consumption, pressure and noise values) has used for train the Neuro-Fuzzy. Then the images derived from the experimental pump are used to detect vortex cases in the second step. Lastly, the relevant data (submergence, flow rate, the diameter of the pipe, power consumption, pressure and noise values) about suspect images have used to test the Neuro-Fuzzy. The accuracy of vortex detection has obtained as nearly 99 %. The result of the proposed model shows that image processing and neuro-fuzzy based design can be successfully used to detect vortex formation.
Vortex formation was successfully estimated using some of the pump data. Thus, it may not be necessary to place some parts such as a vortex preventer before the pump blade entry. Before the vortex is formed, the pump can be stopped without cavitation due to the algorithm generated by the data obtained from the pump.

Acknowledgment
This study was supported by The Scientific and Technical Research Council of Turkey (TUBITAK, Project No:213O140). We would like to thank Prof. Dr. Sedat ÇALIŞIR who contributed to this work.