Latest software technology brings the world of machine learning and artificial intelligence to the masses

Nick Stone, Field Application Engineer at Anglia, introduces STMicroelectronics’ NanoEdge™ AI Studio product that enables developers to create an optimal ML library for their STM32 microcontroller-based projects, using a minimal amount of data in just a few steps only.

Imagine the transformation if the next system you design could autonomously learn its environment, predict anomalies, understand and report causes of failure. This is already becoming a reality with thousands of pumps, motors and household appliances! In the quest for smarter equipment and infrastructure, the integration of machine learning (ML) and artificial intelligence (AI) is now being used to help build the reliability, innovation and capabilities of equipment. Machine learning gives software applications the ability to predict outcomes more accurately without being explicitly programmed to do so using data and is a type of artificial intelligence.

The evolution of smart devices
As technology has entered the era of connected IoT, many more powerful features have been enabled by the intelligent and powerful processing power available in the cloud, including ML and AI implementations.

As these powerful new features have been realized, they are now entirely dependent on the efficient operation of equipment, for example smart home devices, we know how frustrating it can be to not be able to turn on a light by voice activation . due to no internet connection. For many applications, this is only a minor inconvenience, but for mission-critical equipment, connectivity or latency issues can be a big deal, hence the need to bring back some of that smart processing, including ML and AI, on the equipment itself, through intermediate gateways or at the edge devices that do not rely on cloud connectivity, has increased.

Implementing machine learning and artificial intelligence
Before going any further, it is worth making the distinction between ML and AI. A full implementation of AI allows a machine to perform tasks that would normally require human intelligence. ML is a form of artificial intelligence that processes tasks by learning from reference or collected data and then makes predictions or acts based on that data.

While ML and AI have now found their way into everyday parlance, implementing them at the technical level in a real-world application is a challenge for embedded developers, even those with some prior ML experience. ‘IA. The investment, complexity, and required development time can often be barriers to AI adoption. Fortunately, STMicroelectronics recognized that developers need a new generation of tools to enable mass implementation of ML and AI in applications and launched NanoEdge™ AI Studio, a new machine learning tool that brings easily a true innovation to end users allowing the integration of state-of-the-art ML and AI algorithms directly into the host system’s microcontroller.

One of the main advantages of NanoEdge™ AI Studio is that it does not require any specific data science skills. Any software developer using the Studio can create optimal ML libraries and start integrating smart features into source code from its friendly environment without any AI skills. The Studio can generate four types of libraries: anomaly detection, outlier detection, classification, and regression libraries.

A Anomaly Detection (AD) The library can be generated using a minimal amount of sample data that shows normal and abnormal behaviors to train the system for example. Once created, the library can be loaded into the target systems microcontroller to train and interpret directly on the device. The library learns the behavior of devices from locally acquired data and dynamically adapts to the behavior of each device. Once trained, Library Inference compares data coming from devices over time with locally created patterns, allowing it to accurately identify and report anomalies.

Detection of outliers (1 C) can be used to detect any anomalies with the one-class classification method. This is particularly useful when no example of abnormal behavior can be provided. In this case, the normal expected signal is imported into the Studio, and then developers can easily create an optimized outlier detection ML library.

A Classification (NC) The library is used to classify a collection of data, each representing different types of equipment faults (such as bearing problems, cavitation problems, or others), or distinct types of events in the environment of the equipment. The developer imports the reference signals for each type of defect into the Studio and, in just a few steps, he can create a classification ML library that brings all this knowledge together in a single library. When this library is then run on the microcontroller, the classifier analyzes the live data and reports the percentage of similarity against the static reference knowledge. The classification library is an extremely powerful tool, in an intelligent industrial environment, it can not only provide rapid fault detection, but also can give an indication of the type of fault detected, thus reducing the time for diagnosis and repair.

And finally, the Regression (E) The algorithm can be used to extrapolate data and predict future data patterns. In this case, the developer imports reference signals and target values ​​into the Studio desktop tool and can generate an intelligent library in just a few steps to, for example, improve energy management or predict remaining life. equipment.

These ML libraries are powerful tools in their own right and can also be combined and chained: detection of anomalies or outliers to detect a problem on the equipment, classification to identify the source of the problem and regression to extrapolate the information and provide real insight into the situation. maintenance team. Typically, designs start with one library and then move on to using multiple libraries adding more value and capability on subsequent builds, see Figure 1.

Fig.1 – Add more value

All of this learning and inference is done right inside the microcontroller using the NanoEdge™ AI self-learning library, which streamlines the AI ​​process and dramatically reduces development effort, cost, and lead time. marketing.

For an example of a typical use case in industrial equipment, ML can provide the key to avoiding failures by helping to predict when and where failure might occur. It helps optimize preventive maintenance and service schedules so they can be done when they are needed and properly targeted to the equipment or subsystem that needs it the most.

Giving meaning to sensors
Of course, to implement ML in an application, the equipment will need appropriate sensors to detect the required environmental conditions. These input sensor signals can range from vibration to pressure, sound, magnetic, and time-of-flight, to name a few. Using STMicroelectronics’ wide range of MEMS and sensor technologies, which includes smart sensors with embedded ML, developers can cover a full range of applications from low-power devices for IoT and battery-operated applications to high-end for precise navigation and positioning, Industry 4.0, augmented virtual reality components and consumer devices. The NanoEdge™ AI Studio gives developers maximum flexibility by allowing multiple sensor inputs to be combined, either in a single library or using multiple libraries simultaneously.

Begin
To enable wider adoption of ML technology, STMicroelectronics has released a demo version of NanoEdge™ AI Studio which is available completely free for three months for developers to experience. The PC-based push-button development studio is compatible with Windows® or Linux® Ubuntu® operating systems and supports multiple STM32 Nucleo boards and QR code Description automatically generatedDiscovery kits such as the STEVAL-STWINKT1B SensorTile Wireless Industrial Node Development Kit, this kit also supports the built-in data logging function in NanoEdge™ AI Studio. The software can be downloaded for free by registering on STMicroelectronics website, click or scan the QR code to register and download now.

After the initial investigation using the demo version of NanoEdge™ AI Studio is complete, users have the option of purchasing an annual single-user development license or a team development license that works with all STM32 microcontrollers. To help build prototypes or proofs of concept faster, with limited risk and investment and maximum chance of success, developers can also purchase an Edge AI Sprint Package, this is a bundle that includes training sessions, a NanoEdge™ AI Studio license and technical support.

Libraries generated with NanoEdge™ AI Studio production licenses can run on any STM32 microcontroller during development and are subject to production license terms.

Design assistance
Anglia offers support for customer designs with free evaluation kits, demo boards and STMicroelectronics product samples through the EZYsample service which is available to all registered customers of an Anglia Live account.

Anglia’s engineering team is also available to support designers with their extensive experience in machine learning and artificial intelligence commonly used in condition monitoring (CbM) and predictive maintenance based designs ( PdM) and can offer advice and support at the component, software and system level. This expertise is available to help customers with all aspects of their product design, providing hands-on assistance and access to additional comprehensive STMicroelectronics resources, including video tutorials, technical application notes, and reference designs. .

Visit www.anglia-live.com to view the full range of STMicroelectronics products available from Anglia.