This solution template provides an architectural framework to build proof-of-concept (POC) solutions for Predictive Maintenance (PdM). It shows how to put together an end to end PdM solution. In-depth content on the why and how of the data science and the software design are provided. A key motivation behind this template is to enable developers to quickly reuse or customize it for new customer scenarios.
The key phases of an end to end modeling pipeline are shown: data ingestion, staging, preparation; feature engineering, model training and validation; model operationalization and output of results. Real-time and stationary data ingestion is supported. Modeling experiments can be run both on a hosting DSVM, or on a scalable Azure service. Online and batch scoring are demonstrated. An easy to use dashboard provides a friendly demo experience, hiding the complexity behind provisioning clusters and other resources.
The AI sections of the template follow the principles and practice described in the popular Azure AI Guide for Predictive Maintenance (previously called Cortana Intelligence Predictive Maintenance Playbook for aerospace and other industries). Two PdM use cases are provided with the template:
- (Use Case UC1) Predict failure condition of a machine - based on real-time sensor-based data.
- (Use Case UC2) Predict that a machine will fail within a future time period - based on historical stationary data.
The goal is to demonstrate the use of multiple solutions in the same template. Based on these examples, practitioners can reuse the template for their own customer scenario and data.
The code for the solution template is available in GitHub. Contribution of new PdM solutions built using the template is highly encouraged. Similarly, good quality code that extends the template's architecture for useful scenarios is also welcomed. See the Contributing section.
Start with ... | If you are ... |
---|---|
Business case for PdM section in the Azure AI Guide for Predictive Maintenance | a business decision maker (BDM) looking to reduce the downtime and improve utilization of critical equipment |
Data Science for PdM section in the Azure AI Guide for Predictive Maintenance | a technical decision maker (TDM), architect, or developer, looking to understand the data science behind PdM technologies. |
This solution template, starting with Prerequisites | a software architect or developer looking to quickly implement a cloud-based POC solution for Predictive Maintenance with Azure AI. |
Solution Templates and Samples for PdM in the Azure AI Guide for Predictive Maintenance | a software architect or developer surveying other technical contributions for predictive maintenance from across Microsoft. |
You will need an Azure subscription and sufficient quota for the Azure services listed below.
Name of the service | Type | Purpose in this solution template |
---|---|---|
Azure App Service | App Service | the solution template is deployed as an App service |
Azure App Services Plan | App Service plan | same as above |
Azure IoT Hub Services | IoT Hub | management of, and data ingestion from, sensor devices |
Azure Blobs & Tables | Storage account | Staging of real-time and stationary data |
Azure Data Science VM | Virtual machine | Workstation/space for the AI Developer |
Azure Machine Learning Service | Machine Learning Model Management | Enable AI Developer to manage models |
Azure Kubernetes Cluster (for O16N) | Microsoft.MachineLearningCompute/ operationalizationClusters | To operationalize models from Azure ML |
Azure Service Bus | Service Bus | To buffer messages for online scoring |
The following skills can be helpful to understand the different parts of the template, and post-deployment customizations:
- Most of the code is in Python. The data generator setup is in Python. PySpark is used for data management. PySpark MLlib and Scikit-learn packages for Python are used for modeling operations.
- Model management and deployment are done via Azure ML v2.0 CLI
- For understanding the various components of the solution template:
- The manifest of components and their provisioning sequence is specified in XML.
- Each component is configured declaratively in JSON (see ARM templates).
- Data and modeling operations are performed on Spark clusters either in the local DSVM or on other Azure clustering services such as Azure HDInsight.
- Knowledge of Azure Kubernetes Service (AKS) and Docker containers is helpful.
- The Admin dashboard is implemented in Flask.
NOTE: If this solution template has been deployed, click here and refresh the browser to see the latest deployment status.
Click on the Deploy button to start a new deployment of the solution template. The deployment completes within an hour if all Azure resources are available in the chosen region. Under peak loads, it may take additional time to complete.
See this step by step deployment walkthrough for details.
In its default configuration and quiescent state, the cost of running the template is less than $50 per day. Actual costs may vary depending on the usage and load on the services.
The solution template and its operations are described in the following sections.
- Solution Template Architecture
- Model train and test - self-documented, and by use case
- Model operationalization - self-documented, and by use case
Usage data is collected to help improve Microsoft products and services. See the privacy statement to learn more.
This project welcomes contributions and suggestions. The contributor is required to agree to a Contributor License Agreement (CLA). The contributor first declares the right to grant Microsoft the rights to use the contribution. Next, the contributor grants Microsoft the right to use the contribution. For details, visit https://cla.microsoft.com.
For each Git pull request, a CLA-bot automatically determines whether the contributor needs to provide a CLA. The steps in the pull request are specified appropriately. Follow the instructions provided by the bot to use the CLA.
This project has adopted the Microsoft Open Source Code of Conduct. More information is available at Code of Conduct FAQ. Contact opencode@microsoft.com with any additional questions or comments.