Repolode
aws

aws/sagemaker-python-sdk

Python SDK for training and deploying machine learning models on Amazon SageMaker, with frameworks, built-in algorithms and BYO containers.

Stars
2,270
Forks
1,317
Open issues
237
Last commit
yesterday

What is it?

The SageMaker Python SDK is an open source library for training and deploying machine learning models on Amazon SageMaker. It lets developers run training jobs and host models from Python code, using deep learning frameworks such as PyTorch and MXNet, Amazon's built-in algorithms, or custom algorithms packaged in SageMaker-compatible Docker containers.

Version 3.x centers on unified classes: ModelTrainer for training and ModelBuilder for deployment and inference, replacing the framework-specific Estimator and Model classes from 2.x. The 3.x line is split into separate PyPI packages for core, training, serving and MLOps. Model fine-tuning trainers (SFT, DPO, RLAIF, RLVR) are also included in 3.1 and later.

The SDK supports Unix/Linux and macOS on Python 3.10 through 3.12. Using it requires an AWS account and an IAM role with SageMaker permissions.

Key features

  • 01Train models with PyTorch, MXNet and other frameworks on SageMaker.
  • 02Use Amazon built-in algorithms or bring your own Docker container.
  • 03Deploy trained models to real-time endpoints with ModelBuilder.
  • 04Fine-tune foundation models using LoRA or full fine-tuning.
  • 05Install modular packages for core, training, serving and MLOps.

Use cases

  • Running distributed training jobs on managed AWS GPU instances from Python.
  • Deploying a trained model as a real-time inference endpoint.
  • Fine-tuning a large language model on custom data in AWS.
  • Building MLOps pipelines with model registry and processing jobs.

Quick start

  1. 1

    Install the SDK from PyPI with pip

    pip install sagemaker

Things to know

  • Targets Amazon SageMaker, so it needs an AWS account and IAM permissions.
  • Supports only Unix/Linux and Mac according to the README.
  • Version 3.x drops the Estimator, Model and Predictor classes from version 2.

Topics

FAQ

What is sagemaker-python-sdk?
Python SDK for training and deploying machine learning models on Amazon SageMaker, with frameworks, built-in algorithms and BYO containers. The SageMaker Python SDK is an open source library for training and deploying machine learning models on Amazon SageMaker. It lets developers run training jobs and host models from Python code, using deep learning frameworks such as PyTorch and MXNet, Amazon's built-in algorithms, or custom algorithms packaged in SageMaker-compatible Docker containers.
Is sagemaker-python-sdk free to use? What license does it have?
sagemaker-python-sdk is open source under the Apache-2.0 license. Check the license terms before using it in commercial products.
Is sagemaker-python-sdk still maintained?
Actively maintained. The last commit to sagemaker-python-sdk was on Oct 23, 2026.
What can I use sagemaker-python-sdk for?
Running distributed training jobs on managed AWS GPU instances from Python. Deploying a trained model as a real-time inference endpoint. Fine-tuning a large language model on custom data in AWS. Building MLOps pipelines with model registry and processing jobs.
How do I install sagemaker-python-sdk?
Install the SDK from PyPI with pip: pip install sagemaker
Where can I get sagemaker-python-sdk?
The source code and installation instructions are on GitHub: https://github.com/aws/sagemaker-python-sdk

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects