Machine Learning on AWS Platform

Machine Learning on Cloud ? Sounds interesting ? Trust me it is.

Sabyasachi Seal
4 min readJul 2, 2022

In this blog, I will teach you how to make ML models on AWS with the help of Amazon SageMaker.

But wait. What is it ???

In Amazon’s words,

Amazon SageMaker is a fully managed service that provides every developer and data scientist with the ability to build, train, and deploy machine learning (ML) models quickly.

Simply put, its a gift to all Data Scientists and ML Engineers who manually build, train and deploy ML models. Every time.

Why do we need it ?

As I said before, after conceptualizing an ML Model, the whole process of implementing it is very tedious and time consuming.

Data Scientists and ML Engineers have to maintain huge amounts of data to train models, then choose the best algorithm and if this wasnt enough, they also have to train the whole thing with a part of the data. To put more pain to the already painful process, they also have to deploy the model into production.

This is where Amazon SageMaker comes in.

SageMaker reduces the complexity of this whole procss by making the building and deployment of ML Models an effortless process.

But How? Does it mean we make bad ML Models ?

Well, a Data Scientish/ ML Engineer selects the algorithm just as before, he also gets to choose the right frameworks for the task he/she is trying to accomplish.

SageMaker takes care of the rest. It will manage the underlying infrastructure, training the model, and also deploying it.

So in short, as a ML Engineer or Data Scientist, all we gotta do is select the correct algorithm and provide SageMaker with the right frameworks. Rest is SageMaker’s magic.

I hope you get a rough idea what is SageMaker now. Lets dive deeper into it.

First, You will need a AWS Account.

Don’t have one, setup one for free.

Go to [AWS Signup Page] and make yourself an account. Remember, you don’t have to pay anything directly upfront.

Make sure you setup the AWS Free Tier as shown in the picture below.

What is AWS Free Tier you ask ?

The AWS Free Tier provides customers the ability to explore and try out AWS services free of charge up to specified limits for each service. The Free Tier is comprised of three different types of offerings, a 12-month Free Tier, an Always Free offer, and short term trials.

If so, congrats, you have completed the first step, if not, check out [this video].

Now we are ready to setup Amazon SageMaker.

Lets say hi to SageMaker

Open AWS Management Console and Under Service, Select Amazon Sagemaker.

Lets make a Amazon SageMaker Notebook.

After Signing in, select your preffered region.

In the left side, choose NoteBook Instances and then choose Create Notebook Instance.

Now give the NoteBook instance a name. Name it something appropriate.

All notebooks run on an instance. You can select the type of instance based on your ML requirements.

For this instance, select the ml.m2.medium.

Permissions and Encryption section: AM role ->Create a new role -> Any S3 bucket ->choose Create role.

Keep the rest of the settings at deault. Do not change if you don’t know what your doing.

Now Choose Create notebook Instance. This takes a bit of time. Move onto the next steps when the steps changes to InService.

Lets initialize a Jupyter Notebook.

The things you can do on Jupyter can take you to Saturn.

Open Jupyter.

Now you need a language. While in Jupyter, select NEW and choose conda_python3 in the right pane.

Now you have a notebook ready. Go ahead. Do whatever you want in the notebook. SageMaker takes care of all the underlying infrastructure.

Wanna talk? | LinkedIn | Twitter | GitHub | Mail |

Thanks a lot if you read till here. I’ll keep writing, if you keep reading.

--

--