You are on page 1of 52

01-07-19

Taller I – Estudio de Casos en el


Análisis de Señales de Monitoreo
de la Condición de Salud de
Activos Físicos
Enrique López Droguett
Juan Tapia Farias

Introduction

We will work on six topics within the area of data acquisition


and preprocessing as well as health states identification and
fault diagnosis:

1. Load Monitoring Data with Python


2. Parameter Extraction
3. Dimensionality Reduction and Visualization
4. Clustering for Health State Identification
5. Anomaly and Novelty Detection
6. Fault Diagnosis

1
01-07-19

Case Studies

1. Rotor: fault identification and diagnostics in the rotor’s


ball bearings
2. Oil Data Analysis: equipment fault diagnostics
3. Thermography: for the inspection of pumps and electrical
cabinets
4. Chlorine Dioxide Generation System in a Cellulose Plant:
fault diagnostics of the plant and its equipment using
process sensors

Rotor: Ball Bearing Faults

This dataset contains 7 main


health states (classes):
1. Normal
2. Vertical misalignment
3. Horizontal misalignment
4. Imbalance
5. Ball Fault
6. Cage Fault
7. Outer Ring Fault

2
01-07-19

Rotor: Ball Bearing Faults

• Each health state can be further divide in subclasses,


according to the load imposed or the degree of
misalignment.
• The data is in csv format, with each file containing the
measurements of 8 sensors for 5 seconds at 50KHz à each
file is a table with 8 columns and 250.000 rows.
• The dataset contains 1951 different measurements.
• The sensors (columns) are:

Radial b1 Axial b1 Tangential b1 Radial b2 Axial b2 Tangential b2 Velocity Sound

Oil Data Analysis


• Study in collaboration with MCM Ingeniería.
• Oil data contains the chemical oil test results from 3
different types of equipment, each associated with a status
and a health state

Status Diagnosis
Normal Normal
Alert Wear of components
Abnormal Silica contamination
Water contamination
Lubricant contamination
Silica contamination and wear of components

3
01-07-19

Oil Data Analysis

• The dataset contains different chemical concentration of


components such as titanium, magnesium, silver, nickel,
lead, among others.

• It also contains the water concentration, oxidation index and


the amount of particles 4, 6 and 14 [𝜇𝑚].

Thermography

• The dataset of thermographic images from pumps and


electrical cabinets

4
01-07-19

Chlorine Dioxide Generation System

• Dataset with 7 sensor readings (temperature, pressure,


conductivity, pumps’ power) from 2008 to 2018
• Sampling frequency: 1 sample per 2 hours

Rotor: Ball Bearing Faults


Enrique López Droguett
Gabriel San Martin

5
01-07-19

Problem Statement

• For the following five modules we will work on the rotor’s


ball bearing faults dataset.

• This dataset assesses the health condition of a rotor.

• Goal: identify the health state and develop an anomaly


detection approach based on multi-sensor data

11

Module 1: Load Data in Python

• Python can load and read information from a wide variety of


file extensions

• Here, we will review the 5 most common ones:


1. .mat: used to store a wide range of objects created with MatLab.
2. .csv: used mainly to store data in form of tables. It is common
because excel spreadsheets can be exported to this format easily.
3. .txt: used in similar scenarios as .csv.
4. .npy or .npz: used to store a single Numpy array or a collection of
them. It is useful to store data that has been already pre-
processed.

12

6
01-07-19

Libraries Used to Load Data

File Extension Library Function


.mat Scipy.io loadmat()
.csv Pandas read_csv()
.txt Numpy loadtxt()
.npy, .npz Numpy load()

13

Module 2: Parameter Extraction

It is often the case where the information contained in a raw


signal is not clear enough for the different algorithms to work.

It is useful to extract parameters from the raw signal.

This parameters depends on the signal type:


• Stationary signal: parameters from the temporal of
frequency domain.
• Non-stationary signal: parameters form the temporal and
frequency domain.

14

7
01-07-19

Stationary Signal: Temporal Parameters

• Based on statistics parameters of the original signal.


The most common parameters for a signal 𝑥 𝑡 =
𝑥&, 𝑥(, 𝑥), … , 𝑥+ are:
RMS Energy contained in the 1
signal 1
. x/(
n
/0&

Peak Distance between the max 𝑥 𝑡 − min 𝑥 𝑡


maximum and minimum
Crest Relation between the 𝑥789:
peak and the RMS 𝑅𝑀𝑆
Mean Mean value of a signal +
1
. 𝑥?
𝑛
?0&

15

Stationary Signal: Temporal Parameters

Variance Second moment +


1 (
. 𝑥? − 𝜇
𝑛
?0&
Asymmetry Third moment 1 + )
∑ 𝑥? − 𝜇
𝑛 ?0&
)
1 + (
∑ 𝑥? − 𝜇 (
𝑛 ?0&
Kurtosis Fourth moment 1 +
∑ 𝑥? − 𝜇 A
𝑛 ?0&
A
1 + (
∑ 𝑥? − 𝜇 (
𝑛 ?0&
Higher order moments 𝑘≥5 1 +
∑ 𝑥? − 𝜇 :
𝑛 ?0&
:
1 + ( (
∑ 𝑥? − 𝜇
𝑛 ?0&
16

8
01-07-19

Stationary Signal: Temporal Parameters

• To increase the influence of higher frequency components,


it is useful to use the derivative of the original signal:
𝑥E8F?G9H?G8 ? = 𝑥? − 𝑥?I&

• To increase the influence of lower frequency components, it


is useful to use the integral of the original signal:
𝑥?+H8JF9K ? = 𝑥? + 𝑥?I&

17

Stationary Signal: Frequency Parameters

• In order to compute frequency parameters, first we need to


convert the original signal from the time domain to the
frequency domain.

• For almost every type of temporal data, this is done with the
discrete Fourier transform:
Q
?(S
𝐹(𝜔) = . 𝑥? 𝑒 I Q T?

?0&
• In Python, this is easily done with the fft function from the
scipy.fftpack library.

18

9
01-07-19

Stationary Signal: Frequency Parameters


• Once we convert the original signal from the time domain to
the frequency domain, we can extract frequency
parameters.
• The most useful parameters is the mean of the frequency
spectrum per bands.
• If the Fourier transform of 𝑥 𝑡 = 𝑥&, 𝑥(, 𝑥), … , 𝑥Q is
𝐹 𝜔 = 𝐹&, 𝐹(, 𝐹), … , 𝐹Q , then we can compute the mean
frequency spectrum of band 𝑖 as:

QZ[\ I&
1
𝐵? = . 𝑎𝑏𝑠(𝐹Y )
𝑁?X& − 𝑁?
Y0QZ

19

Non-Stationary Signal: Spectrograms

• For a signal that varies with time in a non-periodical way,


the spectrogram can be used to capture the frequency
spectrum for a discretization of time.
• In Python, spectrograms are easily computed with the
function spectrogram() from the library scipy.signal.

20

10
01-07-19

Non-Stationary Signal: Scalograms

• One of the disadvantages of the spectrograms is that there


exists a trade-off between the frequency and temporal
resolution.
• Scalograms, using base function that are not sinusoids,
allow for independent control of the frequency and
temporal resolution.

21

Module 3: Dimensionality Reduction and


Visualization
• Reducing the dimensionality of a signal or a set of
parameters can be useful to simplify the feature space,
which can improve a classifier or detector performance

• Also, for data visualization, reducing the dimensionality of


the data to 2-D or 3-D is mandatory

• For this, we will work with four algorithms:


• Principal Component Analysis (PCA)
• Kernel Principal Component Analysis (K-PCA)
• T-Distributed Stochastic Neighborhood (T-SNE)
• Lineal Discriminant Analysis (LDA)
22

11
01-07-19

Python Functions and Libraries for


Dimensionality Reduction and Visualization

Model Library Function


Principal Component Analysis sklearn.decomposition PCA
(PCA)
Kernel Principal Component sklearn.decomposition KernelPCA
Analysis (K-PCA)
T-Distributed Stochastic sklearn.manifold TSNE
Neighborhood Embedding (T-
SNE)
Linear Discriminant Analysis sklearn.discriminant_analysis LinearDiscriminantAnalysis
(LDA)

23

Principal Component Analysis (PCA)

• PCA uses a linear transformation to convert a set of


observations possibly correlated between them into a set of
uncorrelated variables of lower dimension.

24

12
01-07-19

Kernel-PCA
• For non-linear data, a better alternative to uncover a lower
dimensionality transformation is to use a non-linear
function (called ‘kernel’) to transform the data into a higher
dimensionality space and then use PCA.
• Possible kernels are ['linear', 'rbf', 'poly', 'sigmoid', 'cosine']

25

T-Distributed Stochastic Neighborhood


Embedding (T-SNE)
• While PCA and K-PCA try to maximize the variance in the
principal components, and therefore preserve the global
structure of the data, T-SNE uses probability distributions to
reduce the dimensionality of the data preserving the local
structure.
• This makes this algorithm ideal in cases where there are
clusters of data in the higher dimensional space.
Cluster 1
Cluster 1
Parameter 2

Cluster 1

Parameter One Dimension


26

13
01-07-19

Linear Discriminant Analysis (LDA)

• It uses a linear combination of parameters that separate


two or more classes of objects (e.g., health states)
• For this reason, the final dimensionality can be at most 𝑛 −
1, where 𝑛 is the number of classes in the dataset
• Note that this algorithm is supervised à it needs the labels

27

Module 4: Clustering for Health State


Identification
• Complex equipment might be monitored continuously:
• Each minute gigabytes of data could be generated
• Labeling this amount of data can be very expensive!
• Clustering provide a cheap way of identifying health states
(labels) according to distance and similarity criterions
• They can also serve as a verification method to ensure that
the assumed original number of classes are correct
• We will work on five clustering algorithms:
• K-Means
• DBScan
• Agglomerative Hierarchical Clustering
• Gaussian Mixture
• Means Shift
28

14
01-07-19

Python Functions and Libraries for Clustering

Model Library Function


K-Means sklearn.cluster KMeans
Means Shift Clustering sklearn.cluster MeanShift
DBScan sklearn.cluster DBSCAN
Gaussian Mixture sklearn Mixture
Agglomerative Hierarchical sklearn.cluster AgglomerativeClustering

29

K-Means
• It divides a set of 𝑛 datapoints onto 𝑘 groups by minimizing
the sum of square differences between each group and the
correspondent centroid
• Both centroids and the group of each point are iterated to
find this minimum

• k initial • k groups are


generated by • The centroids • Compute the
centroids choosing the closest are steps 2 and 3
datapoints recomputed. until
convergence. 30

15
01-07-19

Means Shift Clustering


• It uses the concept of Kernel Density Estimation (KDE) to
define peaks within the data centered around the high
density areas
• Then, it moves each datapoint to the nearest peak, grouping
them into different clusters

31

DBScan
• It is an algorithm similar to the Means Shifting, but with
some improvements:
1. It allows to identify outliers as noise
2. It can identify groups of arbitrary form in the N-dimensional
space

32

16
01-07-19

Gaussian Mixture
• One of the disadvantages of the K-means algorithm is that it
can only do circular clusters
• With Gaussian Mixture, we have two parameters per
dimension (mean and variance) to allow more flexibility
• For example, in 2-D, we can form elliptic-shape clusters

33

Agglomerative Hierarchical Clustering


• It treats each datapoint as an individual cluster (leaf). Then, by
some metric distance, it joins similar clusters into bigger clusters,
until it agglomerates all the data into one final cluster (root)
• The user defines the number of desired clusters and the
algorithm travel from the root to the leaves and return the
clusters closest to the root

34

17
01-07-19

Module 5: Anomaly & Novelty Detection


• We usually have massive amount of data without the details
of the potential health states (labels):
• We would like to know which datapoints show variation from the
rest: identify the outliers
• This is an Anomaly Detector

• In other situations, we only know that the data came from


an equipment operating under normal condition:
• Novelty Detector: identify new data that deviates from this normal
condition

35

Anomaly & Novelty Detector: Datasets

Anomaly Detector: Novelty Detector:


• One dataset used for training. • Two datasets:
• The model identifies which • One training dataset containing
only normal samples
datapoints deviates from the rest
(equipment under normal
(outliers) operating condition)
• One testing dataset containing
both normal samples and
abnormal samples

36

18
01-07-19

Anomaly & Novelty Detection: Algorithms


• The following algorithms work for both anomaly and novelty
detection:
• Robust Covariance
• Isolation Forest
• Local Outlier Factor
• One Class Support Vector Machine

Model Library Function


Robust Covariance sklearn.covariance EllipticEnvelope
Isolation Forest sklearn.ensemble IsolationForest
Local Outlier Factor sklearn.neighbors LocalOutlierFactor
One-Class Support Vector sklearn svm
Machine
37

Robust Covariance

• It assumes that the “normal” data comes from a known


Gaussian distribution
• The outliers are defined as those datapoints that deviates
from the mean by a threshold or more

38

19
01-07-19

Isolation Forest

• It tries to identify outliers by dividing the data iteratively


• The goal is to end the iterations when every datapoint has
been isolated
• The cuts are chosen randomly in the space of the data

39

Isolation Forest

• The process can be summarized in a decision tree


• For a particular point, the number of cuts until it is isolated
(length from the root to the particular leaf) is a measure of
normality
• More cuts à More Normal

40

20
01-07-19

Isolation Forest

• The algorithm is run many times, generating a decision tree


in each run à one measure of length for each datapoint in
each run

• Finally, the mean of the length is the measure of normality

• Every datapoint with final length under some threshold, will


be abnormal (as it was easy to isolate)

41

Local Outlier Factor


• It defines a factor (LOF) for each datapoint
• This LOF is a measure of local density. It asses, in a
neighborhood of a datapoint, how many other datapoints
are present
• It is expected that for outliers, the LOF will be much smaller
than the LOF of its neighbors

42

21
01-07-19

One Class Support Vector Machine

• It tries to find the smaller sphere that can contain all the
datapoints

• For the outliers, an extra term is added to the minimization


function
ξ1

(
1
(
min 𝑟 + . 𝜉?
F,` 𝑛𝑣
?0&
( c ξ2
sa: 𝑥? − 𝑐 ≤ 𝑟( + 𝜉? , for 𝑖 = 1,2, … , 𝑛
r

43

One Class Support Vector Machine

• As the decision frontier for the outliers is usually not shaped


as a sphere, a kernel is used to convert the data into a more
friendly distribution in space

Φ(𝑥)

44

22
01-07-19

45

Performance Metrics for Fault Diagnostics


(Classification)
• We will review the following four metrics:
• Accuracy
• Precision
• Recall
• F1 Score
• Confusion Matrix

46

23
01-07-19

Performance Metrics for Fault Diagnostics


(Classification)

• Accuracy: percentage of
elements correctly classified:

pqXpQ
𝐴𝑐𝑐𝑢𝑟𝑎𝑐𝑦 = pqXpQXrqXrQ

• Precision: percentage of positive


elements detected that
effectively were positive:

𝑇𝑃
𝑃𝑟𝑒𝑐𝑖𝑠𝑖𝑜𝑛 =
𝑇𝑃 + 𝐹𝑃
47

Performance Metrics for Fault Diagnostics


(Classification)

• Recall: ability of the classifier to


find all the positives samples:

pq
𝑅𝑒𝑐𝑎𝑙𝑙 =
pqXrQ

• F1 Score: harmonic mean


between the recall and the
precision:

𝑃𝑟𝑒𝑐𝑖𝑠𝑖𝑜𝑛×𝑅𝑒𝑐𝑎𝑙𝑙
𝐹1 = 2
𝑃𝑟𝑒𝑐𝑖𝑠𝑖𝑜𝑛 + 𝑅𝑒𝑐𝑎𝑙𝑙

48

24
01-07-19

Performance Metrics for Fault Diagnostics


(Classification)
• Confusion Matrix: allows to visualize the errors of the
algorithm per health state (class)

49

Oil Data Analysis: Equipment


Fault Diagnostics
Enrique López Droguett
Gabriel San Martin

25
01-07-19

Problem Statement: Oil Data from MCM


Ingeniería
• Data corresponds to oil samples from different types of
equipment: pumps, engines and shafts

• Oil samples are periodically produced in various industries.


Using that data for condition based monitoring could
improve the uptime of machines and reduce the resources
spent in maintenance

• The goal is to asses both the general state of the equipment


and perform fault diagnosis

51

Module 6: Fault Diagnostics

• We will work with four algorithms for multi health state


classification:
• K-Neighbors
• Decision Trees
• Support Vector Machines
• Random Forests

Model Library Function


K-Neighbors sklearn.neighbors KNeighborsClassifier
Decision Trees sklearn.tree DecisionTreeClassifier
Support Vector Machines sklearn.ensemble RandomForestClassifier
Random Forests sklearn.svm SVC
52

26
01-07-19

Multiclass Classification Performance Metrics

• Recall, Precision and F1 Score are defined for binary


classification
• How can we extend these metrics to the case where there
are more than two health states (classes)?
• The strategy is known as one v/s all. For example, if there
are three classes 𝐶&, 𝐶(, 𝐶) :
• First, we formulate a two classes problem by considering 𝐶& as the
first class and 𝐶( , 𝐶) as the second class. We can compute the
metrics as before
• This step is repeated for 𝐶( , 𝐶)
• Finally, the metrics are averaged

53

K-Neighbors

• Very simple algorithm


• For each point, its class is assigned as the most common
class between its k most nearest neighbors
• For example:

Value of k Class of green circle

3 Red Triangle

5 Blue Square

54

27
01-07-19

Decision Trees
• Using an attribute selection metric (Gini or Entropy), an
attribute is chosen and converted into a decision node
inside the tree. The data is divided into two sub-groups
according to that attribute
• This process is repeated until there are no more attributes
or every datapoint is already in a class

55

Random Forests
• Random Forest algorithm is an ensemble of different
decision trees, where each one of them is trained in a sub-
group of the original training dataset
• For a new point to be classified, it is fed to every decision
tree and the corresponding heath state is defined as the
most repeated prediction class of the forest

56

28
01-07-19

Support Vector Machines

• The original SVM is a binary classifier that first applies a


kernel to the data to change the domain in an attempt of
linearly separate the data and then tries to find the best
linear function that separate the two classes

57

SVM for Multiclass Fault Diagnosis


(Classification)
• There are two strategies to apply a SVM to a multiclass
problem:
• One v/s all: 𝐾 classifiers are built (where 𝐾 is the number of
classes) and for each new datapoint the predicted class
corresponds to the one given by the classifier with the best
performance

• One v/s One: For each pair of classes, a classifier is built. This
z zI&
means building classifiers. The predicted class is the most
(
frequent one given as a result between the classifiers

• SVM in Sklearn uses by default the One v/s One strategy

58

29
01-07-19

Training, Validation and Testing Datasets


• Using the same dataset to train and test the model is an
methodological error. It can lead to a final performance that
will not be achieved in new data
• For this, it is often the case that the data is divided in two
subsets: Training and Testing datasets
• If multiple hyper-parameters are being tested, using the
same testing dataset to tune the parameters and asses the
final performance can lead to the same problem
• Therefore, the data has to be divided into three subsets:
• Training dataset: to fit the model
• Validation dataset: to tune the hyper-parameters
• Testing dataset: to give a final assessment of the model’s predictive
capacity

59

Prediction

Train model

Training set Model

Data

Validation set

Final Evaluation
Final Model
Testing set

60

30
01-07-19

Cross-Validation
• If available data is not significant, dividing it into three
subsets could produce a too small training set
• Cross-validation is useful in these cases:
• In this strategy, the data is separated into a training and testing
dataset
• Then, the training dataset is divided into k subsets and the
following training/validation scheme is performed:
• A subset is chosen. The model is trained with the 𝑘 − 1 remaining
subsets
• The chosen subset is used to test the model. Metrics are generated
and stored
• This procedure is repeated for each subset
• Finally, the resulting metrics for each subset are averaged to
produce a validation metric
61

62

31
01-07-19

Selection of Hyper-Parameters
• Hyper-parameters: they are parameters in the model that
are not learned through data

Algorithm Hyper-Parameters
K-nearest neighbors algorithm Number of neighbors
(k-NN)
Decision Tree Selection criterion: Gini or
Entropy
Random Forest Number of trees, selection
criterion
Support Vector Classifier Kernel, parameter of
penalization C, kernel
parameters

63

Selection of Hyper-Parameters
Two strategies for selecting hyperparameters:

• Grid Search: evaluate all the desired combination of hyper-


parameters. Choose the one that result in the best cross-
validation performance

• Random Search: define a probability distribution for the


parameters, sample 𝑁 collection, evaluate them and choose
the one that result in the best cross-validation performance

64

32
01-07-19

Thermography: Fault
Identification in Pumps and
Electrical Cabinets
Juan Tapia F.
Enrique López Droguett

Thermography
• For the inspection of mechanical equipment (pumps and electrical
cabinet) infrared cameras are used to determine their operating
condition and prevent failures

• Each thermal image is reviewed by an analyst in order to evaluate


the emissivity values

• The analyst must verify that the elements (e.g., oil, grease varnish of
motor coils) of an equipment do not exceed the maximum and
minimum design temperatures of each component

• The temperature difference between the inner and outer part of an


equipment is on the average 30ºC

• Each equipment has a different temperature threshold

66

33
01-07-19

Thermography
• Pump and Electrical Cabinets

67

Thermography
• Outputs of the thermal camera are:

• 01 Fluke file format called IS2. This file has metadata as follows:
• One original image (R,G,B) 3 channel
• One thermal image (R,G,B) 3 channel
• One data matrix with the temperature of each pixels

Camera Fluke TIR-39

68

34
01-07-19

Thermography

• The TiR32 camera has a temperature range between -20°C and


150°C

• It can be used for building applications including energy audits,


protection against adverse weather conditions and the restoration

69

Thermography
• Electromagnetic Spectrum

70

35
01-07-19

Thermography

Data Temperature

Visualization: different representations of the same data

71

Problems & Challenges


• Lots of images are captured in a month for each equipment
• All the images need to be checked by a specialist
• For each image, one form must be filled out
• The results depend on the experience of the specialist:
subjective

Goal: detect high temperatures via automatic processing and


analysis of a significant number of thermal images
72

36
01-07-19

Unsupervised Health State Indentification

• Motor coils (sector of cooling fins in electric motors) must not


exceed 100°C and alert at 80°C (*)

• It is important to consider that mineral oils double their oxidation


rate for every 10°C increase in temperature above 50°C (*)

(*) Data reported by MCM Chile

73

Thermography

• Image processing
• One image is a 2D Signal
• Each image has 3 channels (Red, Green, Blue)
• Each channel is a matrix data

Image processing Libraries

74

37
01-07-19

Image Processing

75

Unsupervised Classification - Clustering

K-Means Clustering

K-means is a clustering algorithm. The goal is to partition n data points


into k clusters. Each of the n data points will be assigned to a cluster
with the nearest mean. The mean of each cluster is called its “centroid”
or “center”

76

38
01-07-19

Unsupervised Classification - Clustering

We will be clustering the pixel intensities of a RGB image

Given a MxN size image, we thus have MxN pixels, each consisting of
three components: Red, Green, and Blue, respectively

• Red colors represent higher temperatures


• Cold colors represent lower temperatures

77

Exercise – Part 1
Using K-mean Clustering identify the colors in the images according to the
visualization

Each color represents higher and lower temperatures

To do list
• Install Opencv library

• Install Imutils library

• Implement K-means
• Looking for the best number of cluster to represent the temperatures
in the images.
78

39
01-07-19

Exercise – Part 1: Work Flow

Dominant
K-Means N- Cluster Histogram
Colors

79

Exercise – Part 1: K-means Implementation

80

40
01-07-19

Exercise – Part 1: K-means Implementation

If a threshold is applied, then we can find a higher temperature


value!!!!

81

Exercise – Part 2
Using the temperature matrix of each image, identify the areas with higher
temperature to classify the images in three conditions:
• Low temperature
• In operation
• High temperature
To Do list
• Install Opencv library

• Install Imutils library

• To detect higher temperatures values in the images


• To draw a circle on the images to help in the analysis
• Improve the classification accuracy using statistical data from the images

82

41
01-07-19

Exercise – Part 2: Work Flow

Estimate
Position

Processing the Estimate Estimate the


images Max Temp Best threshold

Estimate • Low temperature


Min Temp • In operation
• High temperature

83

Exercise – Part 1: K-means Implementation

84

42
01-07-19

Exercise – Part 1: K-means Implementation

Our goal is to generate k clusters from n data points. We will be treating


our MxN image as our data points

To do this, we need to re-shape our image to be a list of pixels, rather


than MxNmatrix of pixels:

N cluster >> Variable to Find!!

85

Exercise – Part 1: K-means Implementation


Centroids

The k-means algorithm assigns each pixel in our image to the closest
cluster. We grab the number of clusters on Line 8 and then create a
histogram of the number of pixels assigned to each cluster on Line 9.
Line 12 to 16, counting the number of pixels that belong to each cluster.
86

43
01-07-19

Exercise – Part 1: K-means Implementation


Plot colors

87

Exercise – Part 1: K-means Implementation


Histogram of Clusters

88

44
01-07-19

Exercise – Part 2: Detecting the Hottest Area in


the Thermal Images

89

Exercise – Part 2: Detecting the Hottest Area in


the Thermal Images

90

45
01-07-19

Exercise – Part 2: Detecting the Hottest Area in


the Thermal Images

Thresholding
if minVal < 10:
result=('Low Temperature')
print("Low Temperature")
elif int(minVal) > 11 and int(maxVal) <= 200:
result=('Normal Operation')
print("Normal Operation")
elif maxVal > 201:
result=('High Temperature')
print("High Temperature")

91

Exercise – Part 2: Detecting the Hottest Area in


the Thermal Images
New Thresholding
rmean=abs((minVal+maxVal)/2)
print(rmean)

if rmean <= 100:


result=('Low Temperature')
print("Low Temperature")
elif rmean > 100 and rmean <= 110:
result=('In Operation')
print("In Operation")
elif rmean > 111:
result=('High Temperature')
print("High Temperature")

92

46
01-07-19

Exercise – Part 2: Detecting the Hottest Area in


the Thermal Images

93

Chlorine Dioxide Generation


System in a Cellulose Plant:
Multi-Sensor Fault Diagnostics
Enrique López Droguett
Andrés Ruiz-Tagle

47
01-07-19

Chlorine Dioxide Generation System

• Chlorine dioxide generation in a cellulose plant

• Goal: health-state diagnosis of the system using multiple


process sensors

95

System Diagram

96

48
01-07-19

System Equipment
The following equipment are considered:

1. Generator (G): generates chlorine dioxide


2. Reboiler (R): shell and tube heat exchanger. Reinjects output
water of the generator as vapor into the process
3. Condensate tank (CT): condensed water from the reboiler is
stored here
4. Hot-water system reinjection pump (M014): reinjects the
content of the CT to the hot-water system
5. Salts recuperation system reinjection pump (M015):
connected to the generator, it controls the flow of sub-products
from the generator such as salts, reinjecting them to a salt
recuperation system

97

System Degradation and Faults


• Sulphate inlays are generated in the interior of the reboiler
tubes (degradation)

• It also reduces the generation of chlorine dioxide


• This is considered as the anomalous behavior of the system

98

49
01-07-19

Process Sensors

The following 7 sensors are used to monitor the system:


1. Temperature sensor TIC8014 [◦C]: measures the
temperature of the water-vapor in the reboiler. High
temperatures, above 110◦C indicates, an anomalous
behavior
2. Temperature sensor TI8015 [◦C]: measures the
temperature of the condensate water that goes from the
reboiler to the condensate tank. High temperatures,
above 110°C, indicates an anomalous behavior
3. Conductivity sensor CI8017 [μS/cm]: measures the
conductivity of the condensed water that flows from the
condensate tank to the M014 pump. Sudden conductivity
increments indicates an anomalous behavior
99

Process Sensors

4. Pressure sensor PI8026 [kPa]: measures directly the


pressure in the top of the generator. A sudden increase of
pressure indicates an anomalous behavior
5. Pressure sensor PIC8025 [kPa]: measures the difference of
pressure in the generator from vacuum losses. A sudden
increase of differences of pressure indicates an anomalous
behavior
6. Power of the M014 pump [%]: measures the power load
on the hot-water system reinjection pump. A high-power
load indicates an anomalous behavior
7. Power of the M015 pump [%]: measures the power load
on the salts recuperation system reinjection pump. A high-
power load indicates an anomalous behavior
100

50
01-07-19

Dataset Characteristics

• Sensors monitoring data from October of 2008 to


September of 2018
• Sampling frequency: 2 hours
• Dataset comprised of 42,206 rows (time steps) and 7
columns (sensors)
• Prior-known health states (labels): last 2,475 time steps are
labeled as follows:
• Normal behavior: set to 0
• Anomalous behavior: set with a number ≠ 0 indicating a faulty
state of the reboiler. All of them are taken as 1

101

Problem 1

• Development of a semi-supervised approach for health


state identification of the system using the few known labels

• Based on this generated labels, develop a model for the


system diagnostics in terms of normal and anomalous
behavior

102

51
01-07-19

Problem 2

• Using the approach to generate the health states (labels) for


the whole system and the prior-known labels, develop a
criteria to label the health states of each equipment of the
system as normal or anomalous behavior

• With these labels, develop a health-state diagnostics model


for each equipment

103

52

You might also like