Co-authors: Christine Ouyang and Igor Khapov
While artificial intelligence (AI)-assisted quality inspection significantly improves inspection cycle time and inspection accuracy, management and support for hundreds of thousands of cameras, robotic arms, and robots can be a challenge. A discussion on the implementation and deployment of AI-assisted quality inspection in an actual manufacturing production environment would naturally lead to an edge solution that efficiently and securely deploys trained models to edge, manages the lifecycle for the models and edge devices, and archives edge data. As Rob High, CTO, IBMÂ® Edge Computing described, “Edge computing brings AI and Analytics workloads closer to where data is created and actions are taken — reducing latency, decreasing network demands, increasing the privacy of personal and sensitive information, and improving operational resilience. IDC estimates that we will see the number of intelligent edge devices in the market grow to 150 Billion by 2025.”
For more details, refer to IBM Edge Computing.
The technology stack described in this blog explains how to efficiently scale model run times and simplify inference process for quality inspection in manufacturing. The same approach can be applied to different use cases with minimal changes.
Use case in IBM system hardware manufacturing
In 2018, IBM Systems supply chain successfully adopted an on-premises PowerAI Vision for quality inspection in IBM system hardware manufacturing for mainframe, IBM Power Systemsâ„˘, and IBM storage systems. Models trained by PowerAI Vision have been used for production-level quality inspection, resulting in improvements in both efficiency and quality assurance, and:
- Reduced manual eyeballing inspection time from 10 min to 1 min per product
- Reduced field issues and improved customer satisfaction
- The project presented in this blog started in late 2018 in order to tackle the following challenges in automation and scaling: Scalability in model deployment within the plant, across plants in different geographies, or inter-company deployment (for example supplier quality management)
- Large-scale model life cycle management
- Large-scale edge device life cycle management (including device set up, monitor, and recovery)
- Edge data archive
- GPU usage and segregation between model training and inferencing for better resource utilization
- Separation of the responsibilities among personas for quality inspector, modeling engineer, and edge manager
The system context diagram in Figure 1 illustrates the intended functions of the final solution. This blog, the first of the series, focuses on the work completed for the use case goal of deploy a trained model to edge. We plan to share other use case models in the upcoming blogs.
Figure 1. System context diagram of quality inspection system
Why PowerAI Vision?
PowerAI Vision was used for model training because of PowerAIâ€™s significant speed advantage with model training. It has integrated Representational State Transfer APIs (REST APIs) to automate train, retrain, and model exporting. It makes computer vision with deep learning more accessible to business users by including an intuitive toolset for labelling, training, and deploying deep learning vision models, without coding or deep learning expertise. It includes the most popular deep learning frameworks and their dependencies. It is built for easy and rapid deployment which translates into increased productivity. By combining PowerAI Vision software with IBM Power Systems, enterprises can rapidly deploy a fully optimized and supported platform with blazing performance. You can find more information on PowerAI Vision at IBM Knowledge Center.
Why IBM Edge Computing for Devices
The IBM Edge Computing service was used to manage distributed nodes, deliver, update, and remove model for quality inspection. IBM Edge Computing for Devices provides users with a new architecture for node management. It is designed specifically to minimize the risks that are inherent in the deployment of either a global or local fleet of edge nodes. Users can also use IBM Edge Computing for Devices to manage the service software lifecycle on edge nodes fully autonomously. More specifically, IBM Edge Computing for Devices supports model management through Sync Service. It facilitates the storage, delivery, and security of models and metadata packages.
You can find more information on IBM Edge Computing for Devices at IBM Knowledge Center.
The reference architecture can be used as a guideline for designing an edge solution.
Figure 2. IBM Edge Computing reference architecture
Model management system proof of concept architecture
This proof of concept (POC) architecture was created with the ability to deploy in the cloud or on site.
All components can be scaled to support multiple edge nodes with different types of models. In the current POC, we used Fast R-CNN models to show the object detection functionality. Figure 3 illustrates the architecture we used to build the model management system POC.
Figure 3. Proof of concept architecture
The architecture consists of the following three main parts:
- PowerAI Vision for model training
- Cloud or on-premises application stack for central control and management
- NVIDIA Jetson TX2 as an edge node for quality inspection
The main process flow for model training that yields the best automated inspection is:
- Modeling engineer uses PowerAI Vision to train the object detection model
- Modeling engineer initiates model export functionality in the main dashboard (after authorization process)
- Dashboard invokes model exporting service with storage specified as a cache for models
- Model exporting service communicates with REST API from PowerAI Vision to download the model
- Model exporting service stores model to the edge IBM Edge Computing for Devices object storage from Model Management Service (MMS)
- Modeling engineer initiates model deployment to specified edge nodes using main dashboard
- Main dashboard communicates with the edge connector which is responsible for working with the Edge Computing Horizon exchange REST API
- Edge connector initiates deployment of patterns using IBM Edge Computing for Devices exchange REST API
- IBM Edge Computing for Devices agent receives configuration from IBM Edge Computing for Devices exchange to deploy a new container with specific model
- IBM Edge Computing for Devices agent initiates Docker container start up with our IBM Edge Computing service
- IBM Edge Computing for Devices service downloads model content from the IBM Edge Computing for Devices Object storage
- Docker downloads the required Docker image which represents runtime for model
- Docker starts model with Rest API
- Quality inspector uses the edge dashboard to analyze photos of the product
- In the Edge dashboard, user initiates quality inspection using REST API of deployed model and the results is displayed thereby automating the inspection process
In this blog, we introduced the background and business challenges in implementing AI-assisted quality inspection in manufacturing environment. We also described the overall architecture of a POC implemented using the Edge Computing platform. We shared how to use the Model Management Service to enable the function of extracting the model from PowerAI Vision and deploying the model to edge.
In our future blogs, we plan to explain how to configure NVIDIA Jetson TX2 and how to work with Edge Fabric CLI and REST APIs. We might also share the work on model lifecycle management, edge device management, edge data achieve, and security.