# A One-Class-Based Supervision System to Detect Unexpected Events in Wastewater Treatment Plants
## 2 Materials and Methods  
### Dataset Description  
A WWTP constitutes a collection of facilities, typically situated within a population center, with its primary purpose being the reduction in wastewater pollution to acceptable levels before discharge into the aquatic environment. Depending on their size and the specific pollutants targeted for treatment, WWTPs consist of various treatment lines and processes. Generally, two main operational lines are recognized: the water line, which is dedicated to wastewater purification, and the sludge line, which focuses on managing solids (sludges) generated during the treatment processes. This study was conducted on a medium-sized wastewater treatment plant located in a Mediterranean climate setting, serving a population of approximately 15,000 individuals. Figure 1 illustrates the operational scheme of the WWTP utilized in this investigation, covering the primary wastewater treatments from the intake of raw wastewater into the WWTP to the release of the treated effluent into the aquatic environment. The water line of this WWTP primarily includes pretreatment, secondary treatment, and tertiary treatment stages. The initial phase of the water treatment process in the WWTP involves the introduction of raw wastewater into the water line, where pretreatment occurs. The primary objective of  
Figure 1: Scheme of the operation of the WWTP under study. pretreatment is the elimination of coarse and fine solids through the screening stage, as well as the removal of greases and oils via the grit and grease removal system. Following pretreatment, the resulting wastewater undergoes secondary treatment to eliminate dissolved and suspended organic matter that persists after the initial pretreatment. The WWTP in question employs activated sludge technology and prolonged aeration for this process, providing oxygen to aerobic microorganisms responsible for breaking down organic matter, as referenced in [26]. Subsequently, secondary settling takes place to separate solid waste or sludge formed during preceding biological processes. The water treatment line concludes with tertiary treatment, aiming for a more extensive removal of specific contaminants, such as phosphorus, which may still be present in the water post secondary settling. In the examined WWTP, physicochemical treatments including coagulation-flocculation, lamellar settling, and filtration are implemented, as documented in [27]. The tertiary treatment process culminates with a disinfection step, involving the exposure of treated water to ultraviolet rays and the addition of sodium hypochlorite to eliminate pathogenic microorganisms. After traversing all the processes in the water line, the treated water is discharged into a water body. Concerning the sludge line, a portion of the sludge generated during wastewater treatment is collected from the bottom of the secondary settling tanks of the WWTP, and subsequently recirculated to the biological reactor to become part of the biological concentrate. Simultaneously, any excess sludge is directed to the sludge line for treatment. This sludge often contains a significant water content, prompting its passage through a gravity-thickening process to increase the concentration of solids, facilitating handling and further processing. Following thickening, centrifugal dewatering is employed to further reduce the water content. The sludge is then temporarily stored at the WWTP until its final transfer for various applications, such as agricultural fertilizers. In the scope of this research, a dataset comprising 23 monitored variables within the WWTP was examined. The samples constituting the dataset were collected over nine months, with a recording frequency of one value per day. Table 1 summarizes the description of each variable and the tags used for each one, indicating the key variables in bold font.