A Case Driven Study of the Use of Time Series Classification for Flexibility in Industry 4.0

Julien Polge, Jérémy Robert, Yves Le Traon

TL;DR

This paper explores how Machine Learning (ML), specifically Time Series Classification (TSC), can enhance the flexibility of industrial automation systems, moving beyond rigid, traditional Programmable Logic Controllers (PLCs). By applying the WEASEL algorithm to a simulated factory environment, they demonstrate that ML can enable production lines to adapt to changing product varieties without manual reprogramming, a key challenge in Industry 4.0.

What Problem Does This Paper Address?

Industry 4.0 envisions highly flexible manufacturing systems that can adapt to diverse customer demands and evolving production needs. However, many existing European manufacturing plants still rely on the Computer-Integrated Manufacturing (CIM) model, which uses static and rigid programs within Programmable Logic Controllers (PLCs). These PLCs control production lines based on fixed logic, making it difficult and time-consuming to change the types of products being manufactured or adjust production parameters. Any modification requires manual intervention, extensive testing, and can lead to significant downtime. This rigidity hinders the agility required for modern manufacturing, where customization and rapid adaptation are crucial for competitiveness. The paper aims to bridge this gap by investigating how ML-based automation can replace this static approach, offering a more dynamic and flexible control mechanism.

Methods

The core of the paper's methodology revolves around applying a Time Series Classification (TSC) algorithm, specifically WEASEL (Word ExtrAction for the time Series cLassification), to a simulated industrial use case.

Here's a breakdown of their approach:

  • WEASEL Algorithm: This algorithm was chosen for its ability to handle variable-length time series, its robustness to noise, its scalability, and its relatively fast training and prediction times. It works by decomposing time series into normalized sliding windows, approximating them using Fourier transforms, and then using statistical tests (ANOVA F-test) to select discriminative Fourier coefficients. These coefficients are converted into "words" using information gain binning, forming a Bag-of-Patterns. Finally, a Chi-Squared test reduces the feature space, and logistic regression is used for classification.
  • Preprocessing: Recognizing that WEASEL's default z-normalization might not be optimal for their specific data (where amplitude differences are key), the authors investigated two main scenarios:
  • Out-of-the-box WEASEL: Using the algorithm with its default z-normalization.
  • No-preprocessing WEASEL: Disabling z-normalization to train on raw data.
  • Custom Preprocessing: Developing a novel preprocessing method that involves computing the mean of a time series, subtracting it from each element, and then taking the absolute value. This aims to create a consistent reference for time series within the same class while preserving amplitude differences.
  • ML-based Automation Architecture: They designed a system where a PLC controller communicates with a dedicated ML agent (running WEASEL) via an HTTP server. The PLC collects sensor data, generates time series, sends them to the ML agent for classification, and then uses the predicted class to control actuators for sorting. This allows for "on-the-fly" decision-making.
  • Experimental Setup: The experiments were conducted on a scale model of a factory using FischerTechnik components and real industrial controllers. This provided a safe environment to test the ML approach without disrupting actual production.

Datasets

The study utilized a custom dataset generated from the FischerTechnik factory simulation.

  • Data Collection: Time series data was collected from a sorting line station, specifically from a color sensor. For each part (initially three colors: blue, white, red, and later extended to orange, green, and purple), time series of varying lengths (350-500 samples) were recorded.
  • Dataset Size: For training, datasets were created with 100 time series per color, ranging from 300 (3 colors) to 600 (6 colors) total time series.
  • Testing: Test sets were also created with balanced classes, each containing 150 time series.
  • Labeling: The time series were manually labeled with their corresponding color class.

Key Insights and Ideas

  • ML for Flexibility: The fundamental idea is that ML-driven automation can replace rigid PLC logic, enabling production lines to adapt to new product types or variations without extensive manual reprogramming. This is a crucial step towards achieving true Industry 4.0 flexibility.
  • Preprocessing is Key: The default z-normalization in WEASEL was found to be suboptimal when amplitude differences are the primary distinguishing feature between classes. The authors' custom preprocessing method, which focuses on mean-centering and absolute values, significantly improved classification accuracy.
  • Single Model Potential: A single, comprehensive ML model trained on a wide variety of parts can effectively classify a subset of those parts, even if some are not present in the training data. This reduces the need for frequent model retraining or switching when product variety changes.
  • Human Expertise Still Crucial: While ML automates decision-making, significant human expertise is still required for industrial process understanding (for labeling and interpreting results) and for ML model tuning (e.g., selecting appropriate preprocessing methods).

Key Results

The study demonstrated the feasibility and effectiveness of using WEASEL for flexible industrial automation:

  • Accuracy:
    • For three colors, the static program achieved 100% accuracy, while WEASEL models with custom preprocessing also reached 100%.
  • As the number of colors increased to four, five, and six, the custom-preprocessed WEASEL models (e.g., Model2", Model3", Model4") consistently outperformed the default z-normalized models, achieving accuracies in the high 90s for five and six colors.
  • Retraining models with misclassified samples further improved accuracy, reaching 100% in some cases.
  • Model Versatility: A single model trained on six colors (Model4") could accurately classify parts from subsets of those colors (three, four, or five colors), demonstrating its adaptability.
  • Performance: While not explicitly detailed with numbers, the paper states that online tests confirmed parts were sorted on time, indicating that the prediction time of the ML models was suitable for real-time industrial applications.

Limitations and Future Work

  • Limitations:
    • Human Expertise: The study highlights that satisfactory results are achieved "only at the expense of the human expertise." This includes labeling data, understanding the industrial process, and tuning ML models.
  • Preprocessing Impact: The custom preprocessing method, while effective, increased training time exponentially with the number of training samples.
  • Sensor Limitations: The narrow range of the color sensor values limited the number of distinct colors that could be reliably differentiated, even with ML.
  • Generalizability: The study was conducted on a scale model; applying these methods to real, complex manufacturing processes might present larger challenges.
  • Future Work:
    • Automating Retraining: Developing automated processes for retraining models when new data or misclassifications occur.
  • Prediction Time Analysis: Further investigating the impact of model size on prediction time, especially for large, comprehensive models.
  • Production Speed Adaptation: Exploring how ML-based methods can handle changes in production speed.
  • Security Mechanisms: Building a more robust and trusted framework by incorporating security measures.

Summary updated

Abstract

With the Industry 4.0 paradigm comes the convergence of the Internet Technologies and Operational Technologies, and concepts, such as Industrial Internet of Things (IIoT), cloud manufacturing, Cyber-Physical Systems (CPS), and so on. These concepts bring industries into the big data era and allow for them to have access to potentially useful information in order to optimise the Overall Equipment Effectiveness (OEE); however, most European industries still rely on the Computer-Integrated Manufacturing (CIM) model, where the production systems run as independent systems (i.e., without any communication with the upper levels). Those production systems are controlled by a Programmable Logic Controller, in which a static and rigid program is implemented. This program is static and rigid in a sense that the programmed routines cannot evolve over the time unless a human modifies it. However, to go further in terms of flexibility, we are convinced that it requires moving away from the aforementioned old-fashioned and rigid automation to a ML-based automation, i.e., where the control itself is based on the decisions that were taken by ML algorithms. In order to verify this, we applied a time series classification method on a scale model of a factory using real industrial controllers, and widened the variety of parts the production line has to treat. This study shows that satisfactory results can be obtained only at the expense of the human expertise (i.e., in the industrial process and in the ML process).
BibTeX
@inproceedings{polge2020case,
  author = {Julien Polge and Jérémy Robert and Yves Le Traon},
  title = {{A Case Driven Study of the Use of Time Series Classification for Flexibility in Industry 4.0}},
  booktitle = {Sensors},
  year = {2020},
  url = {https://openreview.net/forum?id=H8qNaG6hmg9},
}
Figure