L G Moreira

L B Groff

J M Gomes Da Silva

S Tarbouriech

Event-triggered PI control for continuous plants with input saturation

This paper proposes a methodology to design stabilizing event-trigger strategies for PI controlled linear continuous-time plants subject to input saturation. Using Lyapunov theory techniques, LMI-based conditions are derived to guarantee regional (or global, when possible) asymptotic stability of the origin. These conditions can be cast in an optimization problem to choose the parameters of the trigger function aiming at reducing the sampling activity, while ensuring the regional stability of the origin with respect to a given set of admissible initial states. Simulation results illustrate the application and potentialities of the method.

I. INTRODUCTION

Event-triggered control techniques consist in sampling and transmitting data only when a trigger condition occurs [START_REF] Heemels | An introduction to eventtriggered and self-triggered control[END_REF]. A challenge in this case is to devise trigger conditions that ensure the stability of the closed-loop system under the aperiodic sampling strategy. With this respect, [START_REF] Tabuada | Event-triggered real-time scheduling of stabilizing control tasks[END_REF] is a widely cited work, which shows that there exist lower bounds for the inter-sampling time of a stabilizing event-triggered control when a threshold on the relative state measurement error is used as trigger condition. Moreover, it is of major interest in networked control systems to develop systematic methods to "tune" the parameters of the trigger condition aiming at reducing the number of samples to deal with the problems of limited bandwidth and energy consumption (mainly in wireless networks). More recently, other issues have also been addressed in the literature. For instance, the co-design between the trigger function and controller gains [START_REF] Abdelrahim | Co-design of output feedback laws and event-triggering conditions for linear systems[END_REF] and the application to nonlinear systems along with the assumption that there is one sensor and one event-trigger generator for each state variable [START_REF] Tallapragada | Decentralized event-triggering for control of nonlinear systems[END_REF].

On the other hand, PI controllers are of special interest due to its massive use in the process industry and applications where constant references and disturbances have to be tracked or rejected. Among the works dealing with eventtriggered PI or PID controlled systems, we can cite [START_REF] Durand | Further results on event-based PID controller[END_REF] and [START_REF]An Event-Based PID Controller With Low Computational Cost[END_REF] that propose triggering data transmissions when the difference between the current plant output value and the last sampled one crosses a given threshold. Although simulations that give insights on the applicability of this strategy scheme luciano.moreira@ufrgs.br, leonardo.groff@ufrgs.br, jmgomes@ece.ufrgs.br S. Tarbouriech is with LAAS-CNRS, Université de Toulouse, CNRS, Toulouse, France. e-mail: tarbour@laas.fr are presented, those papers do not give explicit guidance on how to choose the threshold values neither prove the stability of the resulting closed-loop systems. In [START_REF] Gomes Da | Eventtriggered PI control design[END_REF], the authors present a design method for event-triggered PI controllers and LTI plants. Based on the Lyapunov Theory, formal proofs of stability of the closed-loop system under the proposed sampling strategy are provided. The proposed method allows to design all the parameters of the controller and an eventtrigger condition to attain a linear quadratic performance criterion. However, the trigger function used is somewhat complex to calculate, as it uses a matrix of dimension 3(n + 1). In [START_REF] Tiberi | On event-based PI control of first-order processes[END_REF] and [START_REF] Beschi | Event-based PI controller with exponential thresholds[END_REF], stability analysis of event-triggered PI controllers acting on first-order stable plants are presented; the measurement error is used in the trigger criterion without normalizing it with respect to the state. In this case, tracking of constant references with zero steady state error is not achieved.

Furthermore, control input saturation is an ubiquitous phenomenon in real control systems. Thus, it is natural to investigate the use of event-triggered techniques with plants subject to control input saturation. In this case, the closed-loop system becomes nonlinear and for exponentially unstable open-loop systems only regional stabilization is possible to achieve [START_REF] Sussmann | A general result on the stabilization of linear systems using bounded controls[END_REF]. In this context, considering statefeedback control laws, in [START_REF] Seuret | Eventtriggered control with LQ optimality guarantees for saturated linear systems[END_REF] algorithms based on linearquadratic criteria are proposed to design periodic, eventtriggered and self-triggered controllers. Lyapunov and hybrid system techniques are used along with generalized sector conditions to ensure exponential stability of the origin and to provide estimates of the region of attraction. Considering a discrete-time framework, saturating state feedback control laws are also addressed in [START_REF] Wu | Event-triggered control for linear systems subject to actuator saturation[END_REF]. Regarding PI controllers we can cite [START_REF] Lehmann | Event-triggered PI control subject to actuator saturation[END_REF], which proposes to design an event-triggered controller without taking the saturation into account and then investigates how the saturation impacts the performance of the closed-loop system. The authors show, by means of examples, that the use of anti-windup techniques can reduce the negative effects of saturation. Since the saturation is not taken into account in the design of the trigger function, there is no a priori guarantee that the designed system will still be stable when the saturation effectively occurs. Moreover, no systematic procedure to determine suitable values for the trigger function are presented. In [START_REF] Lehmann | Event-triggered PI control: Saturating actuators and anti-windup compensation[END_REF] and [START_REF] Kiener | Actuator saturation and anti-windup compensation in event-triggered control[END_REF], stability issues under control saturation are addressed considering PI and generic dynamic output feedback controllers. Although the proposed conditions ensure that the trajectories are bounded in an ellipsoidal set, the convergence to the origin (i.e. asymptotic stability) is not guaranteed. It should be pointed out that the problem setup in that paper assumes that the output of the controller is continuously applied to the plant (i. e. no sampling and zero order hold are considered), which presupposes that controller and plant are in the same node in a networked implementation.

The present paper addresses the design of an event-trigger strategy for PI controlled continuous-time linear plants subject to input saturation. Differently from [START_REF] Lehmann | Event-triggered PI control: Saturating actuators and anti-windup compensation[END_REF] and [START_REF] Kiener | Actuator saturation and anti-windup compensation in event-triggered control[END_REF], we suppose that plant and controller are in different nodes and that the value of the control signal is kept constant between two sampling instants (i. e. between two successive events). The considered trigger function takes into account a weighted (through the use of generic positive definite matrices) relative distance between the last sampled state and the current continuous one. Based on Lyapunov theory, LMI conditions to ensure the asymptotic stability of the closedloop system (under the event trigger strategy) for a given set of admissible initial states are proposed. Since the weighting matrices of the trigger function appear explicitly in the LMIs, a convex optimization problem aiming at selecting them in order to reduce the sampling activity (i. e. the number of trigger events) is proposed. A numerical example illustrates the application of the method.

Notation: R represents the set of real numbers. For v ∈ R, sat(v) is the classical symmetric saturation function with limits ±u0, with u0 > 0 ∈ R. A deadzone non-linearity is defined as

φ(v) sat(v)-v; thereof, we can state that sat(v) = v +φ(v).
A denotes the transpose of matrix A. He{A} A + A . The symbol * stands for symmetric blocks within a matrix. tr(A) denotes the trace of matrix A. diag(X, Y ) denotes the block-diagonal matrix composed by the blocks X and Y . E(P ) = {ξ ∈ R q ; ξ P ξ ≤ 1} denotes an ellipsoid defined from a matrix P = P > 0 ∈ R q×q .

II. PROBLEM STATEMENT

Consider a continuous-time single-input single-output linear plant defined by the following equations:

ẋp(t) = Apxp(t) + Bpu(t) y(t) = Cpxp(t) (1)
where x p (t) ∈ R n is the state vector; u(t) ∈ R is the input, limited in amplitude such that -u 0 ≤ u(t) ≤ u 0 , with u 0 > 0; y(t) ∈ R is the controlled output; A p , B p and C p are real-valued constant matrices of appropriate dimensions. We assume that the plant is observable and controllable.

The controller is a continuous-time PI controller, defined by the following state space representation:

ẋc(t) = -y(t) ν(t) = kixc(t) -kpy(t) (2)
where x c (t) ∈ R is the controller state; ν(t) ∈ R is the controller output and k p , k i ∈ R are the proportional and integral gains, respectively. We consider a networked control implementation where plant and controller are in separate nodes and are connected through a general purpose network forming the closed-loop system depicted in Figure 1.

At instants determined by an event-trigger generator, a sample of the plant output is sent to the controller node. At the same time, the current value of ν(t) is sent to the plant input and to the event generator. Between two trigger instants, the controller and plant inputs are held at the constant sampled values by means of zero-order holders. Therefore, the closed-loop system can be represented as follows:

             ẋp(t) = Apxp(t) + Bpu(t) y(t) = Cpxp(t) ẋc(t) = -y(t k ) ∀t ∈ [t k , t k+1 ) ν(t) = kixc(t) -kpy(t k ) ∀t ∈ [t k , t k+1 ) u(t) = sat(ν(t k )) ∀t ∈ [t k , t k+1 ) (3)
where t k , k = 0, 1, 2, 3, ... are the triggering times. We consider t 0 = 0. Note that the equilibrium point is assumed to be the origin. If the system is subject to a non-zero constant reference, the equilibrium is not the origin anymore, but a variable translation can be done and the stability analysis will be the same (see details in [START_REF] Gomes Da | Eventtriggered PI control design[END_REF]). Due to the control input saturation, the overall behavior of the closed-loop system is nonlinear. In this case, defining the state vector x = [x p x c ] , the region of attraction for (3) can be defined as follows [START_REF] Tarbouriech | Stability and Stabilization of Linear Systems with Saturating Actuators[END_REF]:

Definition 1: The region of attraction (RA) of the origin for the system (3) is the set of all initial states x 0 ∈ R (n+1) for which x(0) = x 0 =⇒ x(t) → 0 as t → ∞.

In words, the RA is the set of all initial conditions whose trajectories converge to the origin. Nevertheless the exact characterization of the RA is, in general, a complex task ([16]- [START_REF] Genesio | On the estimation of asymptotic stability regions: State of the art and new proposals[END_REF]). Thus, it is useful to characterize subsets of the RA that have an analytical representation, such as ellipsoidal and polyhedral sets. These subsets can be used as estimates of the RA and are called regions of asymptotic stability (RAS) [START_REF] Tarbouriech | Stability and Stabilization of Linear Systems with Saturating Actuators[END_REF].

Considering system (3), we aim at designing an eventtriggered control strategy (i. e. that defines the trigger instants t k ) to reduce the number of messages exchanged between the nodes, so that we can save energy and communication bandwidth, while keeping the closed-loop system stable. Hence we can formally state the problem we want to address as follows:

Problem 1: Devise an event-triggered strategy for the closed-loop system (3) guaranteeing the regional asymptotic stability of the origin for initial conditions in a given subset X 0 of the RA of the closed-loop system, while reducing the number of data transmission events between the sensor/plant node and the controller node.

III. CONTINUOUS-TIME SYSTEM STABILITY

Before analyzing the event-triggered control strategy, we recall some stability conditions for the continuous-time system composed by the direct connection between (1) and ( 2), through a saturation function, i. e. u(t) = sat(ν(t)), which leads to the following system:

ẋp(t) = Apxp(t) + Bp sat(kixc(t) -kpCpxp(t)) ẋc(t) = -Cpxp(t) (4)
We assume that the gains k i and k p have been designed such that (4) is regionally stable in a set X 0 . This is guaranteed if k i and k p are such that there exist a scalar ς > 0,

matrices W = W > 0 ∈ R (n+1)×(n+1) , Z ∈ R 1×(n+1)
satisfying the following linear matrix inequalities (see [START_REF] Tarbouriech | Stability and Stabilization of Linear Systems with Saturating Actuators[END_REF] for details):

He{(A + BK) W } ςB -Z * -2ς < 0 W W K - Z * u 2 0 ≥ 0 (5)
and

X 0 ⊂ E( W -1 ), with A Ap 0 -Cp 0 ; B Bp 0 ; K -kpCp ki (6)
In this case, it follows that V (x) = x P x, with P = W -1 is such that V (x) < 0, ∀x ∈ E(P ), i. e. E(P ) is a contractive domain for the closed-loop system (4).

IV. EVENT-TRIGGER STRATEGY

In this section, we propose an event-trigger strategy and provide stability conditions by means of a quadratic Lyapunov function.

Defining δ(t) x(t k ) -x(t), with x(t) being the state of the closed-loop system (in our case, the plant and controller system combined), it is shown in [START_REF] Tabuada | Event-triggered real-time scheduling of stabilizing control tasks[END_REF] that one can use the triggering criterion presented below to ensure that an eventtriggered control system like (3) is stable:

if ||δ(t)|| = σ 0 ||x(t)|| then trigger end if
where ||•|| denotes the Euclidean norm and σ 0 is a scalar selected from an interval of values determined by the dynamics of the system.

In this paper, we extend this idea by using the following generalized criterion:

if δ (t)Q δ δ(t) > x (t)Q x x(t) then trigger end if
where Q δ and Q x are symmetric positive definite matrices of dimension (n + 1) × (n + 1). With this generalization, we add degrees of freedom and we expect to allow a larger reduction in the sampling activity. Notice that we can rewrite our event-trigger strategy as follows:

Algorithm 1 Event-trigger strategy if f (δ, x) δ (t)Q δ δ(t) -x (t)Q x x(t) > 0 then trigger end if
The term δ (t)Q δ δ(t) -x (t)Q x x(t) is a relative measure of the deviation between the last sampled state and the current state; Q δ and Q x act as weights on this measure. The relation between these matrices plays a role similar to the one of σ 0 in [START_REF] Tabuada | Event-triggered real-time scheduling of stabilizing control tasks[END_REF], in the sense that the "larger" Q x and the "smaller" Q δ are, the more we let the current state deviate from the last sampled one and the less sampling activity is expected. To illustrate this, notice that if we choose Q x = σI and Q δ = µI we basically retrieve the criterion in [START_REF] Tabuada | Event-triggered real-time scheduling of stabilizing control tasks[END_REF] with σ 0 = σ/µ and, as shown in that paper, the larger σ 0 the less sampling activity is expected.

Let A, B and K be given matrices defined as in ( 6), with K verifying (5), and define

A δ 0 0 -Cp 0
Now we derive conditions that ensure the asymptotic stability of the origin when the event-trigger strategy described in Algorithm 1 is used.

Theorem 1: If there exist a scalar ς > 0, matrices

W = W > 0 ∈ R (n+1)×(n+1) , Qx = Q x > 0 ∈ R (n+1)×(n+1) , Q δ = Q δ > 0 ∈ R (n+1)×(n+1) and Z, G 2 ∈ R 1×(n+1
) such that the following LMIs are satisfied:

   He{(A + BK)W } W (A δ + BK) ςB -Z * -Qx 0 0 * * -Q δ -G 2 * * * -2ς    < 0 (7)    W 0 W K -Z W * Q δ K -G 2 0 * * u 2 0 0 * * * Qx    > 0 (8)
then, E(W -1 ) = {x ∈ R n+1 ; x W -1 x ≤ 1} is a RAS for the system (3) under the sampling strategy given by Algorithm 1, with

Q x = Q-1 x . Proof: Considering δ p (t)
x p (t k ) -x p (t), δ c (t) x c (t k ) -x c (t) and sat(ν) = ν + φ(ν), note that between two trigger events, that is for t ∈ (t k , t k+1 ), we can re-write (3) as follows:

             ẋp(t) = Apxp(t) + Bpu(t) ẋc(t) = -Cpxp(t) -Cpδp(t) u(t) = -kpCp[xp(t) + δp(t)] + ki[xc(t) + δc(t)] + φ(ν(t k )) y(t) = Cpxp(t) (9)
Using now A, B and K as defined in (6) and considering

x x p x c , δ δ p δ c
and C C p 0 , we can rewrite [START_REF] Beschi | Event-based PI controller with exponential thresholds[END_REF] as follows, where we dropped the time dependence to simplify the notation:

ẋ = (A + BK)x + (A δ + BK)δ + Bφ(K(x + δ)) y = Cx (10)
Considering a quadratic Lyapunov function candidate V (x(t)) = x (t)P x(t), it follows that V (x) = x He{P (A + BK)}x + 2x P (A δ + BK)δ + 2x P Bφ [START_REF] Seuret | Eventtriggered control with LQ optimality guarantees for saturated linear systems[END_REF] Notice that the argument of φ, i. e. ν(t k ), can be written as

K(x + δ) = K K x δ K a x a ( 12
)
where K a K K and x a x δ .

Hence, provided that x a belongs to the region S 0 = {x a ∈ R 2(n+1) ; K a x a -G a x a ≤ u 0 }, the following generalized sector condition ( [START_REF] Tarbouriech | Stability and Stabilization of Linear Systems with Saturating Actuators[END_REF], [START_REF] Gomes Da | Antiwindup design with guaranteed regions of stability: an LMI-based approach[END_REF]) is verified with respect to the deadzone nonlinearity φ:

τ φ (K a x a )(φ(K a x a ) + G a x a ) ≤ 0 ( 13
)
with τ being a positive scalar and G a = G 1 G 2 a free matrix of appropriate dimensions. Assuming x a ∈ S 0 and applying ( 13), we can write

V (x) ≤ V (x) -2τ φ (K a x a ) φ(K a x a ) + G a x a (14)
Thus, from ( 11) and ( 12), ( 14) can be written as follows:

V (x) ≤ x δ φ M x δ φ (15)
with

M = He{P (A + BK)} P (A δ + BK) P B -τ G 1 * 0 -τ G 2 * * -2τ
From Algorithm 1, it follows that δ Q δ δ -x Q x x ≤ 0. Then, if the following matrix inequality is verified:

  He{P (A + BK)} + Qx P (A δ + BK) P B -τ G 1 * -Q δ -τ G 2 * * -2τ   < 0 (16)
from [START_REF] Kiener | Actuator saturation and anti-windup compensation in event-triggered control[END_REF], we can conclude that

V (x) < δ Q δ δ -x Q x x ≤ 0 for t ∈ (t k , t k+1
), provided x a ∈ S 0 . Now pre-and postmultiplying ( 16) by diag(W, I, ς) with W = P -1 , ς = τ -1 , considering the variable changes Z = G 1 W and then applying Schur's complement, we retrieve matrix inequality [START_REF] Gomes Da | Eventtriggered PI control design[END_REF], with Qx = Q -1

x . Thus, the satisfaction of (7) guarantees V (x) < 0 for t ∈ (t k , t k+1 ), provided x a ∈ S 0 .

At the instants t = t k , δ(t) is zero and the system reduces to the continuous-time (4). In this case, it can be verified that ( 16) implies [START_REF] Durand | Further results on event-based PID controller[END_REF] and it follows that V (x(t k )) < 0, provided x a (t k ) ∈ S 0 . Now we show that (8) guarantees that x a ∈ S 0 , ∀t ≥ 0, provided x(0) ∈ E(P ). Pre-and post-multiplying (8) by diag(P, I, 1, I), applying Schur's complement twice and recalling that Z = G 1 W , the following relation is verified

P -Qx 0 0 Q δ -[K -G1 K -G2] 1 u 2 0 [K -G1 K -G2] > 0 (17)
Pre-and post-multiplying ( 17) by x δ and x δ respectively, [START_REF] Khalil | Nonlinear systems[END_REF] implies that

x P x + δ Q δ δ -x Qxx -x a [K -G1 K -G2] 1 u 2 0 [K -G1 K -G2]xa > 0 (18)
Hence, if t ∈ (t k , t k+1 ), since δ Q δ δ -x Q x x ≤ 0, we conclude that x a (t) ∈ S 0 if x(t) ∈ E(P ). On the other hand, at t = t k , we have δ(t) = 0 and it also follows that x a (t k ) ∈ S 0 if x(t k ) ∈ E(P ). Thus, we can conclude that if x(0) ∈ E(P ), [START_REF] Gomes Da | Eventtriggered PI control design[END_REF] along with (8) effectively ensures that x a (t) ∈ S 0 and V (x) < 0, ∀t ≥ 0, which ensures that E(P ) is an invariant and contractive set with respect to the system (3), being included in its region of attraction.

Theorem 1 ensures the regional asymptotic stability of the closed-loop system. Actually, it can be applied to both stable or unstable plants. Nevertheless, if A p is Hurwitz, global stability can be achievable [START_REF] Sussmann | A general result on the stabilization of linear systems using bounded controls[END_REF]. A sufficient condition for the global stability of the closed-loop system under the event-trigger strategy can therefore be stated as a corollary to Theorem 1 as follows.

Corollary 1: If there exist a scalar ς > 0, matrices

W = W > 0 ∈ R (n+1)×(n+1) , Qx = Q x > 0 ∈ R (n+1)×(n+1) and Q δ = Q δ > 0 ∈ R (n+1)×(n+1) such that the following LMI is satisfied:    He{(A + BK)W } W (A δ + BK) ςB -W K * -Qx 0 0 * * -Q δ -K * * * -2ς    < 0 (19)
then, the origin of system (3) is globally asymptotically stable under the sampling strategy given by Algorithm 1, with Q x = Q-1

x . Proof: It follows the same lines as the proof of Theorem 1 but applying a global generalized sector condition, i. e., using G a = K a , which implies

G 1 = G 2 = K.
Remark 1: It is worth noticing that the possibility of Zeno solutions is eliminated taking into account that the eventtrigger function satisfies:

||δ(t)|| ≤ λmax(Qx) λmin(Q δ ) ||x(t)|| (20)
Hence, the same arguments used in [START_REF] Tabuada | Event-triggered real-time scheduling of stabilizing control tasks[END_REF] can be applied here to show that the inter-sampling times are lower bounded. Remark 2: Notice that the plant and controller states need to be available to implement the event trigger criterion defined by Algorithm 1. Considering that the controller and the event generator run in different nodes, the controller state can be transmitted to the event generator only at the instants t k . Then, assuming the controller sends its state at instants t k , x c (t) can be recovered, as in [START_REF] Gomes Da | Eventtriggered PI control design[END_REF], using:

xc(t) = xc(t k ) - t t k y(t k )dt = xc(t k ) -y(t k )(t -t k ) (21)
In numerous applications only part of the plant state is measured. In this case, since y(t) is assumed to be continuously available to the event generator, x p (t) can be recovered through a Luenberger observer:

xp (t) = A p xp + B p u(t) + L(C p xp -y(t)) ( 22
)
where xp is the estimated state. Remark 3: In [START_REF] Lehmann | Event-triggered PI control: Saturating actuators and anti-windup compensation[END_REF] and [START_REF] Kiener | Actuator saturation and anti-windup compensation in event-triggered control[END_REF] it is assumed that the controller output is continuously applied to the plant. In this scenario, the closed-loop system is given by:

             ẋp(t) = Apxp(t) + Bpu(t) y(t) = Cpxp(t) ẋc(t) = -y(t k ) u(t) = sat(ν(t)) ν(t) = kixc(t) -kpy(t k ) ∀t ∈ [t k , t k+1 ) (23)
Our approach can be easily adapted to cope with this case, i.e. similar conditions to ( 7) and ( 8) can be obtained from the same steps used in the proof of Theorem 1. Particularly in this case, the trigger function can be defined only in terms of the plant and controller outputs. However, the possibility of Zeno solutions occurrence has to be carefully studied.

V. OPTIMIZATION PROBLEMS

Consider a given region of admissible initial states X 0 . If X 0 ⊂ E(P ) and conditions of Theorem 1 are satisfied, we conclude that X 0 is also included in the region of attraction of the closed-loop system. To solve Problem 1, the idea is also to reduce the number of transmission events, i. e., reduce the number of sampling instants.

As observed in Section IV, in order to reduce the sampling activity, one should aim at finding Q x as "large" as possible and Q δ as "small" as possible, while ensuring that the closed-loop system under the event-trigger strategy given in Algorithm 1 is stable. Considering that X 0 is specified as an ellipsoid E(P 0 ) = {x ∈ R (n+1) ; x P 0 x ≤ 1}, this goal can be achieved from the following convex optimization problem:

min(tr(Q δ + Qx ))
subject to: [START_REF] Gomes Da | Eventtriggered PI control design[END_REF], [START_REF] Tiberi | On event-based PI control of first-order processes[END_REF],

W I I P 0 > 0 (24)
Note that the last constraint in (24) ensures that X 0 ⊂ E(P ). Also note that this optimization problem, although leading to a reduction in the number of events, does not guarantee that the minimum possible is achieved.

VI. NUMERICAL EXAMPLE

Consider the following unstable plant:

   ẋ(t) = 0 1 4 0 x(t) + 1 0 sat(u(t)) y(t) = 1 1 x(t) (25)
We choose controller gains k p = 18 and k i = 19 so that the system without saturation and with a continuoustime controller is stabilized with closed-loop poles in -10.2, -6.68 and -1.11.

We consider X 0 = E(P 0 ), with P 0 = diag(4, 4, 10 6 ). Then we apply the optimization problem (24) proposed in the Only 40 trigger events are needed in the time interval [0, 5] and the minimum inter-sampling time is 19 ms. For comparison purposes, the response considering a continuous-time implementation is also depicted in this figure. We can observe that there is no significant degradation on the system performance when compared to the continuous case. As a matter of comparison, if one uses a periodic sampled control law with a sampling period that achieves the same number of samples as the event-triggered, i. e. a sampling period around 100 ms, the trajectory for the same initial condition diverges. Figure 3 shows the projection of the set E(P ) obtained for the event-triggered controller along with the projections of some convergent and some divergent trajectories, in black and in magenta, respectively. Note that E(P ) contains X 0 , as required.

We consider now a more stringent specification for X 0 , by choosing P 0 = diag(1, 1, 10 6 ). Figure 4 shows the projection of the set E(P ) obtained. One can see that E(P ) now is closer to X 0 . Figure 5 the time interval [0, 5] and the minimum inter-sampling time is 17 ms; a slight worse performance than the less restrictive X 0 specification. One can also observe a slight degradation on the system performance when compared to the continuous case.

VII. CONCLUDING REMARKS

In this paper we proposed a systematic methodology to design event-triggered strategies for PI controlled plants subject to input saturation. Differently from previous work, we suppose that plant and controller are in different nodes in a network and that the value of the plant input is kept constant between two trigger instants, i.e. when the trigger condition is verified the plant output is transmitted to the controller and an updated control signal is transmitted to the plant. The method guarantees local asymptotic stability of the origin for a given set of initial conditions and can be easily extended to guarantee global stability for stable plants. Since the derived conditions are in an LMI form, a convex optimization problem is proposed to compute the trigger function parameters aiming at reducing the sampling activity while guaranteeing the stability of the closed-loop system.

The extension of the proposed approach to include antiwindup compensation, the co-design of the trigger function and controller parameters and incorporating the ideas from [START_REF] Aranda-Escolastico | A novel approach for periodic event-triggering based on general quadratic functions[END_REF] to handle periodic event-triggered control are subjects of ongoing work.

Fig. 2 .Fig. 3 .Figure 2

 232 Fig. 2. Simulation results -Comparison between continuous and eventtriggered systems

  Figure2shows results of a simulation with x(0) = [ √ 2/4 √ 2/4 0] . Only 40 trigger events are needed in the time interval [0, 5] and the minimum inter-sampling time is 19 ms. For comparison purposes, the response considering a continuous-time implementation is also depicted in this figure. We can observe that there is no significant degradation on the system performance when compared to the continuous case. As a matter of comparison, if one uses a periodic sampled control law with a sampling period that achieves the same number of samples as the event-triggered, i. e. a sampling period around 100 ms, the trajectory for the same initial condition diverges. Figure3shows the projection of the set E(P ) obtained for the event-triggered controller along with the projections of some convergent and some divergent trajectories, in black and in magenta, respectively. Note that E(P ) contains X 0 , as required.We consider now a more stringent specification for X 0 , by choosing P 0 = diag(1, 1, 10 6 ). Figure4shows the projection of the set E(P ) obtained. One can see that E(P ) now is closer to X 0 . Figure5shows results of a simulation with x 0 = [ √ 2/2 √ 2/2 0] . Now 48 trigger events are needed in

Fig. 4 .Fig. 5 .

 45 Fig. 4. RAS with event-triggered control -Large X 0


Stéphane Bonnevay

Jairo Cugliari

Victoria Granger

Predictive maintenance from event logs using wavelet-based features: an industrial application

published or not. The documents may come

Predictive maintenance from event logs using wavelet-based features: an industrial application

Introduction

Smart electric devices automatically monitor information about energy consumption or production, they are dened by the ability to connect to a network and to operate remotely. They report meaningful and appropriate information to relevant parties (consumers, energy distribution system operators or energy providers) and their systems. Modern electric smart devices produce enormous amount of data. The rst one is the inherently primary data associated to the devices' main activity and implemented features. Its exploration and use involve privacy issues which have been largely debated and are beyond the scope of this work. In addition to this, the second category of transmitted information is about events, a relatively new category of data, the value of which has yet not been assessed. Event is basically a notication that originates from a electrical device and contains the information regarding the object, action or process to which the event is related. Events are issued while monitoring dierent aspects of the system and give an overview about equipment communications, devices' secondary non-core functionalities, network intrusions or activity on the grid.

We believe that event logs could be processed and analysed to unveil useful information, in addition to devices' primary data. More precisely, we assume that these data can be useful to inform about the device's operative state and eventually to predict device failure. However, event logs concern a wide range of uses and the diculty comes from the volume and variety of logs received.

Log events are continuously recorded composing a data streamow related with high volumes, as being generated not only for irregular functional conditions, but also for normal operative states.

The main challenge is to analyse this data and extract useful knowledge from the unremitting ow of notications. The issue therefore is to identify appropriate events containing helpful information. Furthermore, it is essential to detect a shift or an alteration in the patterns of these specic events which could alert users about a fault occurrence.

In literature, patterns from event logs are dened in various ways, for example as partial orders of a process [START_REF] Sander | Discovering block-structured process models from event logs -a constructive approach[END_REF][START_REF] Sander | Discovery of frequent episodes in event logs[END_REF][START_REF] Diamantini | Behavioral process mining for unstructured processes[END_REF] , or considered as Petri nets [START_REF] Mannhardt | From low-level events to activities -a pattern-based approach[END_REF] . Also as repeated sequences that capture process models from event logs in order to improve their detection [START_REF] Jagadeesh | Abstractions in process mining: A taxonomy of patterns[END_REF] . From these denitions, authors develop some specic pattern detection approaches mainly based on unsupervised or supervised learning techniques. Unsupervised pattern detection approaches take an event log as input and generate patterns based on statistical properties [START_REF] Sander | Discovery of frequent episodes in event logs[END_REF][START_REF] Diamantini | Behavioral process mining for unstructured processes[END_REF][START_REF] Jagadeesh | Abstractions in process mining: A taxonomy of patterns[END_REF] . In unsupervised learning, clustering techniques are widely used [START_REF] Vaarandi | Logcluster -a data clustering and pattern mining algorithm for event logs[END_REF][START_REF] Adetokunbo | Clustering event logs using iterative partitioning[END_REF] . Supervised pattern detection approaches take patterns and logs as input and detect pattern instances as results [START_REF] Mannhardt | From low-level events to activities -a pattern-based approach[END_REF] . Combination of these two approaches into semi-supervised techniques have been also studied [START_REF] Lu | Semi-supervised log pattern detection and exploration using event concurrence and contextual information[END_REF] . From another point of view, visualization and interactive tools have been developed to help user observe and analyse both patterns and event sequences, as EventFlow [START_REF] Monroe | Temporal event sequence simplication[END_REF] .

Event logs are frequently composed of event codes and their associated text messages. In that case, the use of text parsing or natural language processing techniques is necessary [START_REF] Vaarandi | Logcluster -a data clustering and pattern mining algorithm for event logs[END_REF][START_REF] Xu | Using machine learning techniques in console log analysis[END_REF] .

Moreover, some specic works dealing with predictive maintenance based on event logs have also been tackled. Let us mention a general classication-based failure prediction method which has been tested on real ATM run-time event logs data [START_REF] Wang | Predictive maintenance based on event-log analysis: A case study[END_REF] , or event logs data extracted from medical equipments used to treat a multi-instance learning task [START_REF] Sipos | Log-based predictive maintenance[END_REF] . Also, a Cox proportional hazard model has been used to provide a prediction of system failures based on the time-to-failure data extracted from the event sequences [START_REF] Li | Failure event prediction using the cox proportional hazard model driven by frequent failure signatures[END_REF] .

In this work, we consider the event distribution over time as a function of time. Our rst objective is to extract characteristic features from the time series, which will then be presented to a learning algorithm. In order to make this step as automatic as possible, we decided to perform the Discrete Wavelet Transform (DWT) which is an appropriate tool for noise ltering, data reduction, and singularity detection, and thus it a good choice for time series and signal processing. The decomposition coecients obtained from the DWT are then used as input of a supervised learning algorithm. A variety of task can be successfully tackled using this approach [START_REF] Soltani | On the use of the wavelet decomposition for time series prediction[END_REF][START_REF] Santos | Discrete wavelet transform coupled with ann for daily discharge forecasting into tres marias reservoir[END_REF][START_REF] Jothimani | Discrete wavelet transform-based prediction of stock index: A study on national stock exchange fty index[END_REF][START_REF] Liu | Time series forecasting based on wavelet decomposition and feature extraction[END_REF] . In our case, we use a random forest both to predict and to measure variable importance in order to select the best features.

In this paper, we propose a supervised approach to predict faults from event log data using wavelets features. The goal is rst to use the Discrete Wavelet Transform to detect and characterize features of our electric event logs. Then, we use these features as an input of a random forest model to predict faults. Next section introduces the information we use from event logs and how we transform them into time series trajectories or time functions. To cope with the temporal dependence and functional structure of these objects, we introduce in Section 3 the wavelets transform. The section also includes an overview of random forest. Section 4 describes the experiences and presents the results. The work concludes with a discussion on both industrial and modelling aspects in Section 5.

From event to time functions

Our study is based on events monitored on electrical devices installed on ENEDIS network, the French Distribution System Operator. Each electrical device records and transmits real-time event data to a centralized information system. We extract and deal with 3 available attributes: the event code related to a time-stamp and the id of the source device. An example of our logs is displayed in Table 1. We dene an additional feature, a group code representing an hierarchical level of event codes. These values were agreed upon with domain experts into 13 groups. None of these notications have any level of criticality or priority. Events were aggregated to a daily basis. Figure 1 shows the A23 event distributions for two electrical devices from the beginning of the study to the last day of observations. The observation period starts on May 01 2013 and stops on November 02 2014 and the total number of events is about 1.25 millions recorded on 2623 devices. Devices were monitored over a considerable period of time and presented similar settings and technical specications during this period. The devices main activity is monitored throughout their lifespan. A fault occurrence is considered when the device fails to provide its main function.

Among all, 1858 devices were properly functional and had a functional status over the observation period, providing their primary function. All of the device were brought to service a priori to the beginning of observation period (see dev003, Figure 2) and were selected as being operative a posteriori to the observation period, over a signicant interval of time, to ensure their normal functioning.

A part of devices developed a fault before the end of the observation period, with the lost of their primary functions. These devices were brought to service either before or after the beginning of the observation time. The devices were withdrawn from the eld and a technical diagnosis conrmed failure on these equipments. Devices failing to provide their main activity for which technical diagnosis did not conrm the failure were not considered in the study. 765 faulty devices were considered in this study (see dev002 or dev001, Figure 2). present a fault occurrence. gap represents the number of days in advance the fault occurrence is recorded, and therefore predicted. Device dev003 does not present any fault occurrence. δ is the temporal period on which wavelet features decomposition is applied.

As stated above, both devices with positive and negative fault occurrences present event proles throughout their lifespan. The purpose of this study is to compare temporal event prole of faulty and working devices in order to identify useful events for predictive maintenance. Hence, the rst goal is to capture events frequencies and dynamics of both devices' health status. The second goal is to predict fault occurrence using these summarized temporal proles while identifying meaningful events. In operative conditions, we wish to detect a failure with a delay which needs to be suciently long to allow the attendance of alarms on devices. In this study we considered a predictive gap ranging from zero up to 15 days.

From the available data we only use the absolute frequency of events and the event code classication. We focus then on the number of logs eectively observed over a reasonable period of length δ using a given time resolution (e.g. hours, days) for each type of event. We then consider

(N (t 1 ), . . . , N (t δ )), (1)
where N (t j ) is the number of events at time t j . To x ideas, say that δ may span over two weeks and using a daily resolution the vector of counts would have length equal to 14. Figure 3 plots four cases of these trajectories. This vector constitutes the building block of our approach since we create instances of this vector for both normal and abnormal regimes (cf. Section 3). Actually, each instance is the tracking of a device along a period of length δ. Then the couple device × time should not be view as tracking over contemporaneous instants but as snapshots of the life time of the devices.

If we now considerer that K dierent type of events exists, then we have

(N k (t 1 ), . . . , N k (t δ )), k = 1, ..., K,
that is each device × time is a set of K counting vectors. From the mathematical point of view, we may look at vectors (1) as time series trajectories. And since there exists K of them, we have a multivariate time series where there may be some dependence structure between components of the vectors as well as time dependence within components.

One way to cope with time dependence is to see each trajectory as a discrete sampling, eventually with some noise, of the time function z k (t), t ∈ [0, δ], k = 1, . . . , K. Notice again that time should be consider as relative to period δ and not as an absolute quantity.

To x ideas, let us introduce a graphical representations of the some of the data up to this point.

We follow the construction detailed above considering only events from one code to construct a sample of trajectories containing both faulty and working devices. Then, we use a simple metric between trajectories based on the euclidean distance on standardized versions of the trajectories.

The associated distance matrix is then used as input of a multidimensional scaling in order to get the a simple planar representation of the observations, represented in Figure 4.

Here, each point is a trajectory and its coordinates are chosen to preserve, as well as possible, the distances between trajectories. Notice that since no information about the class is used this technique is essentially unsupervised. However we add a colour reference (grey: working devices, red: faulty devices) to the scatter plot in order to visualize eventual dierences. Even if the sample is very unbalanced, a clear distinction between both classes is appreciated. Distances between working devices are relatively small with reference to distances between faulty devices. Other conclusion we can draw is that a (eventually non linear) reduction of the dimension may suce to extract the useful information on the signals. Taking into account the time dependent structure of the functions is necessary to obtain an appropriate construction that yields on a dimension reduction.

Methods

We describe here the methods we use to construct our solution. They are related rst on how to represent the multivariate time series with a handy set of interpretable features. Then we build a 2-class discriminant classier where we assume that each class represents a logging regime. The rst one is the normal log regime where the working device has a working status. This regime, should be the most frequent one. The second regime, more rare by nature, represent a working device that is close to a failure status. The rst problem is solved using the wavelet transform while the classier we use is random forest. properties. That is, the transform will give information on locations connected to only a time span (not the global time) and scales connected to only some frequencies (and not all of them). This is in dierence with a time domain analysis that has no localization on frequencies or a frequency domain analysis that has no localization on time.

Moreover we use the Discrete Wavelet Transform (DWT) which is provides an orthonormal basis of the space, allowing us to encode all the available information on a signal without any loss of information [START_REF] Nason | Wavelet methods in statistics with R[END_REF] . In what follow we explain the necessary material to understand our approach.

Consider the signal z(t) which is an univariate function dened on the time domain T , for example T = [0, 1]. The DWT will provide two terms: a global approximation of the signal S(t)

and the ensemble of details D(t) well localized both in time and frequency.

If z ∈ L 2 ([0, 1]),
then the DWT provides us with a basis of the functional space. The basis is created by simple transformations of a scaling function φ(t) and a wavelet mother ψ(t) which are associated to the orthogonal multi resolution analysis of L 2 ([0, 1]). Indeed, we consider the family {φ j,k (x) = 2 -j φ(2 -j x -k)} j,k which is obtained by dilatations of a factor 2 j and by integer translations on the new scale. Similar operations are done to get the family {ψ j,k (x)} j,k . Then, a nite energy signal z can be expressed as

z(t) = 2 j 0 -1 k=0 c j0,k φ j0,k (t) Sj 0 (t) + J-1 j=0 2 j -1 k=0 d j,k ψ j,k (t) D(t) , (2)
where c j,k =< z, φ j,k >, d j,k =< z, φ j,k > are the scale coecients and wavelet coecients respectively. The scale j 0 separates the two terms. The rst one, gives a smooth approximation at resolution 2 j0 . The second one, keeps all the details of the curves on a hierarchical structure depending on scales and locations. The approximation coecients c j0,k retains the information of the local (at location k) mean level of the curve, while the detail coecients d j,k codes the information of discontinuities and other singularities.

With nite data {z(t i ), i = 1, . . . , N }, the signal z(t) can only be approximated by a truncation at some maximum scale level J = log 2 (N ), that is we approximate (2) by

z J (t) = c 0 φ 0,0 (t) + J-1 j=0 2 j -1 k=0 d j,k ψ j,k (t). (3)
Notice that we have also xed the approximation part at the coarsest resolution j 0 = 0 which means that only one scaling coecient is used to approximate this term. For convenience we choose the number of sampling points per curve, N , to be a power of 2. The maximum number of scales J is then an integer. With this, we are in conditions to use the highly ecient Mallat's pyramidal algorithm [START_REF] Mallat | A wavelet tour of signal processing: the sparse way[END_REF] to obtain both the scaling and wavelet coecients. If the sampling grid {i/N, i = 1, . . . , N } is not regular or N is not a power of 2, then one can choose a ner regular grid and use any interpolation scheme to meet our choices.

Haar wavelet leads to a easy and clear intuition on the wavelets coecients. The only scaling coecients we retain is proportional to mean level of the whole signal. The approximation term is then a constant function S 0 (t) = c 0,0 ψ(t) proportional to the mean function of the signal.

If we increase the resolution of the approximation to the next scale, then the approximation part will be a ladder function, that is a piecewise constant function with a jump in the middle point of the sampling grid. Aside the jump, the signal is approximated by the mean level of each side.

A similar reasoning applies to the next scales, at each time cutting into halves and approximating each half by a constant function equal to the mean level of the observations on the half.

The detail coecients are the dierence on the constant approximations between two juxtaposed halves. We interpret them as the change observed at some resolution (related to the scale j) and at some time (related to the location k).

In what follows we will need to reduce the number of coecients we use in order to keep the calculations into a reasonable time. With this, we are further truncating the approximation on

(3) into smaller values of J. Since ner approximations may capture only the signal's noise, the changes on these scales would reect random uctuations not necessarily connected to the structure of the signal. For this, one should only retain coarsest scales. and the detail coecients

d 0,0 , d 0,1 .
In what follows we set ψ to be

ψ(t) =      1 if 0 ≤ x < 1/2 -1 if 1/2 ≤ x < 1 0 otherwise. ( 4
)
which is known as the Haar wavelet. The corresponding scaling function is ψ(x) = 1 if 0 ≤ x ≤ 1 and 0 otherwise. the resolution level at which we look at the signal, for scales close to j = 0 the analysing functions are global, while at scale j = 5, the 32 resulting coecients gives very localized information. Note that this level of detail can be misleading if considered only at one individual scale. For instance the last coecient at scale 5 is large and negative because the last number of logs is lower than the precedent one. Moreover, noise is also more important at these high frequencies. One may rely on shrinkage methods to choose which of the estimated coecients are signicantly dierent from zero.

Our approach is slight dierent, we choose to work only with the scale coecient c 0,0 and the detail coecients d 0,0 , d 0,1 . With this, the number of coecients retained in what follows is kept into a reasonable size when multiplied by the number of event codes. Intuitively, these coecients allows one to reconstruct the trajectories with the approximation S 1 (t) which is exactly the mean level of the function, given by c 0,0 , and the detail coecients d 0,0 , d 0,1 . Notice that this reconstruction is the best linear approximation one can do with three coecients. In what follows we are using the estimated coecients as features of a random forest predictor.

Random forest

Very popular in statistical machine learning, random forests (RF) are an ensemble method [START_REF] Breiman | Random forests[END_REF] .

It builds up on specic versions of CART (Classication And Regression Trees) [START_REF] Breiman | Classication and regression trees[END_REF] , which is an algorithm that constructs binary tree-based predictors. With respect to individual predictors, the aggregate one aims to augment robustness, variance reduction and improve prediction performance.

For this, RF add two layers of randomness. First, each tree-based predictors is trained only on a dierent bootstrap sample from the data. Second, only a strictly subset of variables are randomly chosen as candidates at each split of the trees' construction. Note that the trees are constructed up to its maximal size and they are not pruned. While using a stopping criterion and pruning are usual in CART, these versions of tree-predictors sacrices generalization power by a better insample t at least on each bootstraped sample and introduces bias by considering only partial information from available variables. With this, individual trees tend to be less dependent between them which is useful under an aggregation scheme. RF is then the resulting predictor obtained by some aggregation rule of the individual prediction of the so described trees. Usual choices of the aggregation rule are majority vote for classication and mean average for regression.

We use two intrinsic features of random forest to help the interpretation of the results : a measure of variable importance and a notion of proximity between observations.

Variable importance measure.

Dierent approaches can be used to determine the importance of a feature for the construction of the forest [START_REF] Genuer | Variable selection using random forests[END_REF][START_REF] Gregorutti | Grouped variable importance with random forests and application to multiple functional data analysis[END_REF] . In this work, a variable is considered more important if it participates more to the decrease of some impurity notion (e.g. the Gini index).

Then, we can track over the individual trees where each variable participates on each node split and record the decrease on the Gini coecient. Then a plot like the one in Figure 7 where the variables are represented in lines sorted decreasingly on the mean Gini reduction. Most important variables on the construction of the classier are on top of the plot.

Observations proximity

Two observations are closer if they are classied within the same terminal node by more and more individuals trees. Then, the proximity is normalized to be between 0 and 1. If we call p ii the proximity between observation i and i , then we obtain a dissimilarity measure 1 -p ii . While the change is trivial, it allows us now to perform a multidimensional scaling on the proximity matrix associated to the proximity measurements. This yields on a natural representation of the individuals that analogously to discriminant analysis represents in a low dimensional space how the classier 'sees' the individuals.

Experiments

In all our experiments we use the open source R software. DWT is performed using wavethresh and randomForest is used to learn random forests. In the experiments to follow we use the default options of randomForest to construct the predictors, i.e. the number of trees ntree is set at 500 and the number of variables mtry chosen randomly at each split is roughly the square root of the total number of variables.

For each gap before fault, we create a dataset of positive and negative failure occurrences as shown in 2). From faulty devices, δ time points (albeit the gap period) before fault occurrence were considered to compute K event vectors. Among working devices, a period of length δ is drawn randomly per device to compute K event vectors per device. Notice that each device at some point of the time is described as a number of 39 features, that is 3 wavelets coecients per group of events' code, with a total of 13 event codes.

Predictive performance

We apply a random forest classier for each of 16 datasets composed of 39 wavelets coecients.

Two week event prole (for each device) is characterized by 3 coecients for each of the 13 groups of events. We compute both false negative rate (FNR) representing the percentage of faulty devices classied as working devices and false positive rate (FPR) as the percentage of working devices predicted as prone to failure. We also compute the global model error, summarizing the percentage of observations which are classied wrong and resuming model global accuracy.

The performance scores of random forest models are displayed in Figure 6, results are presented in relation to the predictive gap before failure occurrence. Global model accuracy ranges from 79%, when the predictive gap equals to 15 days, up to 89% when detecting fault the day of occurrence.

This performance, that at rst sight appears rather inaccurate in an industrial context, displays evidence of meaningful information in the event logs. Overall, the predicting error rate is higher for faulty devices and it is easier to decide on a working status on the basis of resumed event prole of a device, independently of the prediction gap (see Figure 6, the red curve corresponding to the FNR stays above the blue line representing the FPR). The error rate is lower when classifying working devices, as observations of negative fault occurrence dominate the learning error. The result is consistent with the fact that random forests tend to maximize the model global accuracy, keeping a low error rate on larger classes (working devices) while allowing the smaller classes have a larger error rate.

The smaller the temporal gap is, the more precise it is to predict both fault occurrence or devices' normal regime by event data, for example the FPR for working regimes being equal to 3.74% for 1 day-ahead prediction and 7.15% for a 10-day-ahead horizon, see Figure 6.

Variable importance

Figure 7 shows importance ranking of attributes in classication for a 0 days predictive gap, variable importance displays similar results for all of the 16 models for dierent values of the predictive gap (results not shown). 3 groups of events appear relevant when predicting fault occurrence : A, B and J. First and third wavelet components of B group appear to be the red ag for an abnormal regime leading to a failure. A dierent level of these events for a device and an alteration of the number of received events can be seen as an alarm for failure occurrence. Overall, we observe the same pattern for all of three groups of events: the faulty devices' average level of events is generally higher than working devices' event frequencies. Moreover, there is a substantial gap between the event regime 7 days before failure occurrence and the week before that. This is particularly interesting, as events are related to low level communication on the grid. We suppose that failure aects the ability of devices to interact with other devices on the network.

More helpful, Figure 7 shows that a considerable amount of information received and processed by the system are not relevant for revealing devices' operative status. Independently of their number or frequency, events of group C, G, K, D and F, seem to carry very little information about a possible failure of an equipment. This is to be expected as these events monitor dierent software activity of various devices of the grid. In a predictive maintenance framework, the monitoring and processing of these categories presents no interest, events have no correlation with the fault occurrence. As in Figure 4, we use a multidimensional scaling to represent observation proximity in Figure 8.

Recall that now the distances on plot are the ones implicitly learned by the classier so it is eectively using the information on the labels (coded in colours on the plot). Two important dierences are to be highlighted. First, the classes are now better clearly separated even if with some overlap. The class of faulty devices (smaller, in red) forms now a compact group that aligned along a straight pattern. Second, the class of normal operation, that is without fault, presents a two arm structure. This means that while connected by some elements that are close to both arms in the middle of the plan, the structure suggest that this class is actually formed by two subclasses which are homogeneous for each of them. From a technical point of view, this result also indicates that working devices present two distinctive event proles, which shift to a single highly abnormal regime when failure emerges. This outcome is of a particular interest, as experts do not have any a priori knowledge about this singularity. Additional investigations may reveal dierent manufacturer implementations or material congurations having no impact on devices primary functionalities. q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q qq q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q q -0.

Additional experiments

Events of category B, J and A were the most relevant to describe device operative state and to detect a device in a abnormal regime leading to a failure. Using exclusively events of these three groups, we performed an additional set of experiments by including non grouped events as features and applying same methodological approach as described above on individual events. We treated 17 individual code events, therefore 51 wavelets attributes were computed and introduced as features to random forests classier. All other parameters remained unchanged. Performances scores of 16 models based on 51 features perform similarly to the global approach (results are not shown) which is using all grouped events. Essentially, error rates of non grouped B, J and A events models are lower than error of models using all code events.

Discussion and conclusion

From the modeling point of view, the use of wavelets and random forests gave several benets.

First, the proposed approach is general in the sense that it is not specic for predictive maintenance. Actually, it may be used on dierent kind of anomaly detection from event logs such as intrusion detection, outage occurrence, etc., as long as one disposes with a way to construct the two class learning data set. Second, wavelets allows an important dimension reduction while keeping discriminatory power. With this, up-scaling the procedure is feasible since the processing needed to pass from functions to wavelet coecients may be done independently (and so using parallel or distributed computing schemes) for each device. Last, random forest gives interest insights through feature selection and observations proximity. The former benets from localized coecients that gives nice interpretation properties to the DWT. The latter can be used together with graphical displays to make emerge patterns in data that are otherwise dicult to unveil.

A natural question that may arise is about the particular choice of the functional basis (i.e.

wavelets) and the classier (i.e. random forest). One may naturally argue that other combination like for instance principal components and logistic regression would be equally reasonable. Our choices are guided for both interpretability and performance. Besides of having a low error level classier we look for tools that allow the practitioner to better understand the underlying problem.

The rst three principal components would extract a mean behaviour of the curves where what we look for is the specic behaviour of each frequency curve that best explains its evolution. Location properties of wavelets, discussed in Section 3, induce the nice interpretability we look for while compressing the information by a handy number of features. Random Forest also contribute to provide with insights on the tted model as it was discussed in Section 4.2 and 4.3.

In our case, when processing log events we found evidence of untapped information on both fault occurrence and the normal devices' regime when monitoring electrical devices information ow. When predicting the fault occurrence the FNR ranges from 18.72% when conrming the fault by analysing event prole the day of fault occurrence, and goes up to 46.38% to 15 days predictive gap. In regard to these results, there a number of points that we should comment on.

First, the increase of FNR inversely proportional to temporal gap implies that, in some extent, at least two weeks before failure occurrence a part of the devices have a similar event prole as working devices and their event regime undergoes a gradual daily alteration until failure. The degradation seems to accelerate 7 days before failure occurrence, the FNR equals to 40.99% and we gain several points of precision each day. We suppose that failure rstly aects non essential functionalities, from which the event logs are issued, and only secondarily it leads to the cession of the main activity. This progressive shift underlines the fact that a fault occurrence does not necessarily imply a full and immediate standstill of a device as it continues to provide their primary function. In regard to these elements, the use of these notications in a predictive maintenance tool is of a particular interest to track future devices fault.

Second, a part of faulty devices are misclassied and display similar log event prole as working devices until failure occurrence (FNR equals to 18.44% for a 1 day predictive gap). See also Figure 8, a part of red observations (faulty devices) are situated among grey observations (working devices).

It is likely that the category of tracked failure is not similar to the previously described case, which aects primary and secondary functionalities dierently. For these devices, functional features related to the main activity should probably be measured as log event prole do not change priori to the failure.

One last point of a particular interest in the results are the early signs of breakdown aecting the devices more than two weeks in advance (FNR equals to 46.24% 2 weeks priori to failure). This result is supported by the high variable importance of the rst wavelet component for all three groups of events, even for a high prediction gap (see 4.2). A really moderate usury of hardware related to external factors or network overload could aect a part of equipment. To a dierent degree, we could also suppose that these devices show an abnormal event prole as soon as they are installed and a latent defect aects their non-core functionalities.

To sum up, classication results show that abnormal dynamics in specic events, can be considered, to a certain extent, forerunner of a future fault. For a long term preventive strategy, there is an obvious need to cross the proles of identied group of events with other sources of informations to increase model accuracy. Geographical situation the grid, power demand, voltage quality, or environmental factors could aect gradually devices leading potentially to a failure.

Primary data and the monitoring of information resulting of the implemented features could allow to enhance the predictive capacity of events. Information on other components of the grid could oer complementary perspectives on the network activity leading to devices usury. Even if the predictive performance does not allow to develop an operative tool, this model allows to identify a high risk population to failure. In a supervision context, the daily processing of ongoing events could allow for these devices to be prioritized and then acted upon with necessary actions.

Figure 1 :

 1 Figure 1: Example of A23 daily event distributions for two electrical devices (dev001 and dev002) from 2013-05-01 to 2014-11-02. The red line shows the end of the observation period.

Figure 2 :

 2 Figure 2: Examples of 3 devices throughout the observation period. Device dev001 and dev002 present a fault occurrence. gap represents the number of days in advance the fault occurrence is recorded, and therefore predicted. Device dev003 does not present any fault occurrence. δ is the temporal period on which wavelet features decomposition is applied.

Figure 3 :

 3 Figure 3: Examples of trajectories from event logs data. Tracking is done daily over 64 days. Cases (a) and (b) are from working devices; and cases (c) and (d) are from faulty ones.

Figure 4 :

 4 Figure 4: Multi dimensional scaling of trajectories from one event code. Each point represents a trajectory from a working device (in gray) or a faulty device (in red).

3 . 1

 31 Wavelets transformWavelets are a domain transform technique that allows one to represent time domain signals into a bivariate domain location-scale[START_REF] Mallat | A wavelet tour of signal processing: the sparse way[END_REF] . While location in the new domain is connected to the original time domain, scales can be associated to Fourier frequencies and both with good localization

Figure 5 :

 5 Figure 5: Tracking of one event over time (right) and its DWT (left).

Figure 6 :

 6 Figure 6: Predictions performance at various gaps, in days, to failure. Red curve shows classication results of failed devices, blue curve shows classication results of working devices and black curve global error.

Figure 7 :

 7 Figure 7: Random forest variable importance output for a 0 day temporal gap

2 Figure 8 :

 28 Figure 8: MDS from RF. Each point represents a trajectory from a working device (in gray) or a faulty device (in red).

Table 1 :

 1 Event logs data.

	timestamp	deviceId	eventCode	groupCode
	2014-01-24 17:49:44.537	001	A3	A
	2014-01-24 15:09:35.970	001	A23	A
	2014-01-25 03:55:56.872	002	A3	A
	2014-01-27 00:14:42.463	002	B8	B
	2014-01-27 08:10:25.470	002	A23	A
	...	...	...	...

Acknowledgements

We would like to acknowledge the ENEDIS company for this collaboration and we especially thank Pierre Achaichia, Paul Mersy and Thomas Pilaud from ENEDIS for rich discussions.