Authors:
            
                    Daniele Antonucci
                    
                        
                                1
                            
                                ; 
                            
                                2
                            
                    
                    ; 
                
                    Davide Bonanni
                    
                        
                                3
                            
                    
                    ; 
                
                    Domenico Palumberi
                    
                        
                                3
                            
                    
                    ; 
                
                    Luca Consolini
                    
                        
                                4
                            
                    
                     and
                
                    Gianluigi Ferrari
                    
                        
                                4
                            
                    
                    
                
        
        
            Affiliations:
            
                    
                        
                                1
                            
                    
                    Department of Electrical and Information Engineering , Politecnico of Bari, Via Re David 200, 70125 Bari, Italy
                
                    ; 
                
                    
                        
                                2
                            
                    
                    Department of Information Engineering and Architecture, University of Parma, Via delle Scienze 181/a, Italy
                
                    ; 
                
                    
                        
                                3
                            
                    
                    GlaxoSmithKline s.p.a., Strada Provinciale Asolana, 90, San Polo Torrile, Parma, Italy
                
                    ; 
                
                    
                        
                                4
                            
                    
                    Department of Information Engineering and Architecture, Università di Parma, Via delle Scienze 181/a, Parma, Italy
                
        
        
        
        
        
             Keyword(s):
            Anomaly Detection, Predictive Maintenance, Machine Learning, Artificial Intelligence, AutoEncoder, Time-Series Forecasting, Hyperparameter Optimization, Fault Detection.
        
        
            
                
                
            
        
        
            
                Abstract: 
                Monitoring industrial processes and understanding deviations is critical in ensuring product quality, process efficiency, and early detection of anomalies. Traditional methods for dimensionality reduction and anomaly detection, such as Principal Component Analysis (PCA) or Partial Least Squares (PLS), often struggle to capture the complex and dynamic nature of batch data. In this study, we propose a novel approach that combines an AutoEncoder (AE), based on Long Short-Term Memory (LSTM) layers, with a rolling threshold for anomaly evaluation. Unlike conventional threshold methods that rely on global statistical parameters, the applied threshold leverages rolling median and rolling Median Absolute Deviation (MAD) to adaptively detect deviations, making it more resilient to outliers and distribution shifts. The LSTM-AE demonstrates superior performance in anomaly detection with respect to PCA and more recent model approaches, specifically for the reference dataset, obtained from a Glax
                oSmithKline (GSK) production plant. Additionally, an LSTM regression model is employed to forecast future data points, which are then fed into the LSTM-AE to enable a predictive approach. This framework leverages the temporal dependencies captured by LSTM layers and reconstruction efficiency of the AE, facilitating a predictive anomaly detection in real-world applications.
                (More)