DEV Community

Yash Bansal
Yash Bansal

Posted on

Using AI With IoT Data: From Sensors to Operational Decisions

IoT systems excel in gathering information: a factory can have many sensors that measure temperature, vibration, pressure, equipment status, location, power consumption, and other parameters. However, obtaining the information is one matter, while extracting actionable intelligence out of it is another.

The interesting part is that AI can be applied to the IoT data processing stage.

A typical architecture is presented below:

Physical Assets

↓

Sensors / IoT Devices

↓

Connectivity

↓

Data Pipeline

↓

AI / ML

↓

Application

↓

Operational Decision

Where each part plays a vital role in the chain: the overall efficacy of the AI/ML model depends on the data preparation stage, while the application scenario and its requirements define the model’s purpose and design.

IoT Layer Covers Physical Assets and Sensors of Various Types

IoT connects physical objects and software systems. Therefore, depending on the use case, there are numerous sensors that gather the data for further processing:

Temperature

Vibration

Pressure

Location

Movement detection

Equipment status

Inventory changes

Environmental factors

While IoT sensor data may be comprehensive and informative, the raw data insights are rarely sufficient. For instance, a stream of temperature readings is barely informative for an operational person: they would rather know whether the temperature is within the acceptable range or not, whether there is an anomaly, and what to do about it.

AI Interprets IoT Data and Extracts Patterns

AI/ML can be applied to process the data and extract valuable patterns. Depending on the case, the task may range from simple: detecting whether there is an anomaly in a sensor output

to complex: predicting the inventory levels in a supply chain.

A machine learning model can be trained to perform one of the following tasks:

Anomaly detection

Predictive maintenance

Forecasting

Classification

Optimization

The main idea is that the model should be chosen according to the scenario and that any specific task should be designed to address certain questions.

IoT Data Ingestion Pipeline Can Be More Complex Than AI/ML Model

When designing an IoT solution, the data pipeline stage is frequently overlooked. While the ML model might be relatively simple, data preparation for it is often resource-intensive.

The data pipeline involves a series of continuous steps prior to data ingestion:

  1. Gathering the information from sensors

  2. Data validation

  3. Timestamping

  4. Data cleaning

  5. Data normalization

  6. Storage

  7. Feature engineering

  8. Ingestion into a database or data lake

  9. Applying AI/ML for model training and inference

It is especially important to design the pipeline correctly when working with heterogeneous data: e.g., when an IoT solution involves multiple types of sensors. For instance, modern manufacturing facilities often use RFID, BLE, UWB, machinery sensors, and enterprise resource management systems. Each category requires specialized data processing tools, and the overall pipeline may become exceptionally complex.

Another crucial decision is whether to process the data in the cloud or at the network edge. While the former option enjoys generality and ample resources, the latter might be superior in terms of latency and security.

AI and IoT Are Interesting When They Address an Operational Business Case

An AI/ML model is generally useful when it is able to perform an actionable task.

A possible scenario could be the following:

Sensor detects abnormal vibration

↓

The data undergoes processing

↓

Anomaly detected by the AI module

↓

The system sends out an alert

↓

Maintenance team examines the site

A similar model can be devised for various business cases, including inventory management. In this context, PharmaFlux AI explores how connected technologies can help the pharmaceutical manufacturing industry to optimize its operations: from general asset monitoring to inventory forecasting and critical process control (CPC). More about connected operations in pharma: pharmafluxai.com

The Goal of an AIoT Solution Should Be to Address a Particular Operational Need

When prototyping an AIoT solution, it is crucial to define the goal first. Frequently, AI/ML engineers attempt to build a model using the available data without defining the use case. However, the model’s application scenario defines the data needs, while the data determines the model design.

Therefore, instead of asking “how can I apply AI to these sensors?”, an engineer should rather approach the task from these directions:

What problem do we want to resolve?

What decisions do we want to automate?

What data do we need for that?

Which sensors can gather the data?

How often should the data be collected?

What infrastructure is needed for processing?

What kind of ML/AI model can be applied?

Who will use the output of the model?

What further actions should be taken?

This way, the model can be built around a realistic scenario with tangible results.

Final Notes

AI and IoT are two separate domains that complement each other. IoT sensors provide an opportunity to learn about the properties of a physical object, while artificial intelligence helps to process and analyze the data.

However, the ML model is only one part of a more significant system. The quality of data preparation, physical hardware, integrations with existing systems, edge/cloud infrastructure, and human factors define the model’s efficacy.

Furthermore, when designing an AIoT solution, it might be more important to ask not “how can we add AI to IoT?”, but “what can IoT data help us to achieve?”. The model itself can be relatively simple, while the true value comes from being able to operationalize insights and make better decisions.

Top comments (0)