Amazon SageMaker - Pricing



Amazon SageMaker pricing is based on a pay-as-you-go model, which means you only need to pay for the resources you use. The pricing depends on the different components of the machine learning workflow.

Understanding Amazon SageMaker Pricing

The major pricing components of Amazon SageMaker are highlighted below −

Notebook Instances

When you use Amazon SageMaker's integrated Jupyter notebooks to develop machine learning models, you are charged based on the instance type and usage time.

Each instance type has a different hourly rate, depending on the CPU, memory, and GPU resources it provides. You can choose from a range of instance types as per your needs.

Training Jobs

For training ML models, Amazon SageMaker takes charges according to the computing resources and the duration of the training process. For example, if you use GPU-based instances for faster training, the cost will be higher.

On the other hand, if you use CPU-based instances, the cost will be lesser. The cost also varies based on the region you are using and the type of model (ML, DL, or Generative AI) you are training.

SagaMaker charges you for both the training instance and any other services that are consumed during the training job. These services include data transfer and S3 storage.

Hosting/Inference Endpoints

Amazon SageMaker also charge you for hosting. Hosting starts once your model is trained and deployed to a Amazon SageMaker endpoint. The fees of hosting depend on the instance type used for deployment and the number of active endpoints.

Like training jobs, higher-performing instances such as GPUs will be costly. The billing is calculated on an hourly basis for each endpoint.

S3 Storage and Data Transfer

Amazon SageMaker is dependent on Amazon S3 for storing datasets. You will be charged for data storage in S3, as well as any data transfers between S3 and Amazon SageMaker. These costs depend on the size of the data being used and the amount of data transferred in and out of the cloud.

Cost Optimization Tips for Amazon SageMaker

Here are some ways with the help of which you can manage and reduce costs when using Amazon SageMaker −

Use Spot Instances for Training Jobs

One of the most effective ways to reduce the Amazon SageMaker training costs is by using Spot Instances. Spot Instances allow you to use unused Amazon EC2 capacity at lower prices.

Select the Right Instance Type

Selecting the right instance type help you reduce the cost. So, choose only those instance types that match the workload for your development, training, and hosting needs.

For example, if you are working on a small experiment, a CPU-based instance is enough. You need not to use an expensive GPU instance for this.

Use Amazon SageMaker Managed Spot Training

You can enable Managed Spot Training, when setting up a training job in Amazon SageMaker. This feature automatically uses Spot Instances to reduce the cost of training jobs by up to 70%.

Monitor and Adjust Usage

You can also use Amazon CloudWatch and AWS Budgets to monitor your Amazon SageMaker usage and costs. You can also set alerts in them. You can also review your usage frequently to terminate unused endpoints.

Utilize Free Tier and AWS Credits

If you are a beginner with Amazon SageMaker, AWS provides a Free Tier that includes 250 hours of free t2.medium notebook instances and 50 hours of m4.xlarge instance usage for training jobs.

Advertisements