In this Code Pattern, we’ll use German Credit data to train, create, and deploy a machine learning model using Watson Machine Learning on IBM Cloud Pak for Data. We’ll create a data mart for this model with Watson OpenScale and configure OpenScale to monitor that deployment. Next, we’ll inject seven days’ worth of historical records and measurements for viewing in the OpenScale Insights dashboard.
The dataset used for this pattern contains information regarding credit applications from a variety of users. We can use a deep neural network to create a machine learning model using Watson Machine Learning and then deploy this model for use in predicting future risk of default. Because of the sensitive nature of credit scoring, this is an ideal use case for the on-premise solution offered by IBM Cloud Pak for Data.
The deployed ML model can now be monitored by Watson OpenScale. Continued use will generate data which allows administrators to ensure the quality of the model, and offer explanations as to what features of the dataset are most influential in creating the Risk scoring. Bias detection will be configured to allow further insight into the fairness of the model predictions. All of this information is available in the OpenScale dashboard and in great detail.
After completing this code pattern, you’ll understand how to:
- Create and deploy a machine learning model using the Watson Machine Learning service on IBM Cloud Pak for Data.
- Setup Watson OpenScale Data Mart.
- Bind Watson Machine Learning to the Watson OpenScale Data Mart.
- Add subscriptions to the Data Mart.
- Enable payload logging and performance monitor for subscribed assets.
- Enable quality (accuracy) monitor.
- Enable fairness monitor.
- Score the German credit model using the Watson Machine Learning.
- Insert historic payloads, fairness metrics, and quality metrics into the Data Mart.
- Use Data Mart to access tables data via subscription.
- The developer creates a Jupyter Notebook on IBM Cloud Pak for Data.
- OpenScale on IBM Cloud Pak for Data is connected to a DB2 database, which is used to store Watson OpenScale data.
- The notebook is connected to Watson Machine Learning and a model is trained and deployed.
- Watson OpenScale is used by the notebook to log payload and monitor performance, quality, and fairness.
- OpenScale will monitor the Watson Machine Learning model for performance, fairness, quality, and explainability.
Ready to put this code pattern to use? Complete details on how to get started running are in the README. The steps show you how to:
- Clone the repository.
- Configure OpenScale in a Jupyter Notebook.
- Utilize the dashboard for OpenScale.
This code pattern showed you how to train, create, and deploy a machine learning model using Watson Machine Learning on IBM Cloud Pak for Data. The code pattern is part of the Getting started with IBM Cloud Pak for Data learning path series.
The pattern is also part of the Getting started with Watson OpenScale learning path. To continue with this learning path, see Using OpenScale with any model, anywhere.