Predicting heart rate failure made simpler

Machine learning, like other applications of Artificial Intelligence (AI), aims to allow computers to learn commands and perform automatically, minus any human intervention or assistance whatsoever. It is fast gaining momentum, and the healthcare industry is one such popular area of application.

Process summary

Creating a predictive model was a fairly complex process at one time; however with the rapid advances in machine learning, the same is no longer applicable. Using the Watson  Machine Learning Service not just significantly reduces the time taken to share information as API insights, but also provides critical measurement metrics.

Let’s understand in depth a code pattern that uses a Jupyter Notebook on the IBM Watson Studio to build one such model that can be deployed to enhance healthcare & anaesthetists services.

Process description

To gain an understanding of this application, the code pattern facilitates building a scoring model that can be used to effectively predict heart rate failure. Using predictive learning, this example walks an individual through the entire life cycle of the process, starting with the role of a data engineer. Python, Jupyter Notebooks and Cloud Object Storage will be used to import, explore and clean data. Following this, the individual would need to use Apache  Spark, and as a data scientist, understand how a pipeline is to be built for training. It is at this stage that a machine learning model will be evaluated basis the features required. Finally, as a developer, the individual would need to deploy this newly-minted predictive model as an API endpoint.

To summarise, here are the different roles involved in creating this predictive model:

Data engineer, wherein a person has to understand, acquire and finally prepare data for usage

Data scientist, wherein with the given database, the individual will evaluate the predictive model against a problem domain

A developer, wherein the individual will build the infrastructure required in order to support the model.

The use case for Watson Machine Learning service

Creating infrastructure to support a predictive model can be a complex process, and the introduction of Watson Machine Learning service can help simplify many of these infrastructure demands. This service can be used to save, deploy as well as monitor predictive models in tandem with IBM’s Data Science Platform.

Creating a predictive model

Given below is an understanding of how a predictive model can be created using IBM’s Watson Machine Learning service, IBM Watson Studio and IBM Cloud. This end-to-end example walks you through the numerous technologies used to:

  • Acquire, clean, and explore data
  • Build a predictive machine learning model
  • Make predictions
  • Host the model for consumption
  • Call the hosted model from a Node.js application

Once this predictive or scoring model has been created, the inputs that are entered can be scored in order to form a prediction on heart rate failure for an individual case.

On completion of this code pattern, you will understand how to:

  • Build a predictive model within a Jupyter Notebook
  • Deploy the model to IBM Watson Machine Learning service
  • Access the machine learning model through either APIs or a Node.js app

Process flow

This section will familiarise you with the process flow to be followed, in order to create a predictive model that can be used to determine heart rate failure.

Given below are the step-by-step instructions to be followed:

  1. The developer creates an IBM Watson Studio Workspace.
  2. IBM Watson Studio depends on an Apache Spark service.
  3. IBM Watson Studio uses Cloud Object storage to manage your data.
  4. This lab is built on a Jupyter Notebook, this is where the developer will import data, train, and evaluate their model.
  5. Import heart failure data.
  6. Trained models are deployed into production using IBM’s Watson Machine Learning Service.
  7. A Node.js web app is deployed on IBM Cloud and calls the predictive model.
  8. A user visits the web app, enters their information, and the predictive model returns a response.

Instructions to create a predictive model

Find the detailed steps for this pattern in the README.md. The steps below will show you how to:

  1. Deploy the testing application
  2. Create an instance of the Watson Machine Learning Service
  3. Create an instance of the Data Science Experience Service
  4. Create a project  in IBM Data Science  Experience  and bind it to  your Watson Machine

Learning service instance

  1. Save the credentials for your Watson Machine Learning Service
  2. Create a notebook in IBM Data Science Experience
  3. Run the notebook in IBM Data Science Experience
  4. Deploy the saved predictive model as a scoring service

Alternative applications of a predictive model

While the above illustration demonstrates the use of a scoring or predictive model in the healthcare industry, the applications are far more widespread.

Predictive models have been known to be used in business intelligence, for instance in order to carry out customer segmentation to improve the quality of marketing and targeting the right customer with the right product. Sales forecasting is another area of application, that allows an organisation to better plan its budgets. Risk assessment and market analysis are two other areas of application. This model is also being used extensively to capture data across social media platforms, to gain insights into user behavioural patterns.

In conclusion

While there are several predictive models available, selecting the right one for the line of business can be a challenge. It, therefore, becomes imperative to carefully evaluate the options available and opt for the one that best meets business requirements.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.