Machine learning
Ranking
🧩 What is it?
The classification is a type of supervised Machine Learning algorithm that predicts to which category or group a new data point belongs, based on previous examples. It works similarly to how a person classifies emails as “spam” or “not spam” after learning what unwanted emails typically look like.
In simple terms, a classification model learns by observing a set of data that are already labeled (for example, states of a machine such as operating, failing, or under maintenance). From there, it is capable of automatically assigning a category to new, unseen data, based on the characteristics it already knows.
🔧 How does it work?
During the training phase, the algorithm analyzes a historical dataset containing input variables (also called features or attributes) and an output variable or label (label), which represents the known category. These input variables can be numerical (for example, temperature, speed, vibration) or categorical (for example, type of shift, day of the week).
During training, the model seeks statistical patterns or rules that relate combinations of features to a specific category. For example, it may detect that when the temperature exceeds a certain threshold and vibration is high, the most likely category is “failure.” This relationship is not explicitly established by the user, but rather inferred automatically by the algorithm from the data.
There are various classification algorithms, each with its own way of learning, for example:
Decision Trees: create tree-like rules that segment data by their values.
Neural Networks: learn complex representations through layers of interconnected nodes.
K-Nearest Neighbors (KNN): assigns the most common category among the nearest neighbors of a new data point.
Naive Bayes: is based on probabilities and assumes independence between features.
Once trained, the model can receive new data —for example, real-time readings from sensors— and predict the corresponding category without human intervention.
🧠 When is it used?
Classification is applied in cases where the desired outcome is always a predefined category. Some examples may include:
Detecting anomalies in sensors by classifying the state as “normal” or “critical.”
Predicting operational states of machinery (e.g. “active,” “inactive,” “in review”).
Classifying energy consumption by building type or efficiency level (e.g. “high,” “medium,” “low”).
Assigning an incident to the corresponding type (“electrical,” “HVAC,” “structural”).
📦 Practical example: Classification of a machine's state
Imagine that in a factory there are sensors connected to a machine that measure temperature, vibration, and noise level. With this historical data, each situation has been labeled as one of three possible states:
🟢 “Works well”
🟡 “Needs review”
🔴 “Failure”
During training, the model learns that when the temperature is low, the vibration is stable, and the noise is normal, the state is usually “Works well.” But if the temperature and vibration increase, and the noise becomes unstable, it is likely in a “Failure” state.
Once trained, the model can receive the current data from those sensors and automatically predict the state of the machine. For example:
If today it has 78°C, vibration 0.35, and noise 75 dB → the model predicts 🔴 “Failure”
If tomorrow it has 68°C, vibration 0.20, and noise 60 dB → it predicts 🟢 “Works well”