Registry / devops / sagemaker-containers

sagemaker-containers

JSON →
library2.8.6.post2pypypi✓ verified 89d ago

Open source library for creating containers to run on Amazon SageMaker. Version 2.8.6.post2. This library is deprecated and no longer actively maintained; users should migrate to the SageMaker Training Toolkit and Inference Toolkit.

pip install sagemaker-containers
INSTALL
IMPORT
SIG · SAGEMAKER-CONTAINE
S
sagemaker-containers
devopspythonv2.8.6.post2
Install
—
Import
—
Disk
—
Pass rate
0/ 10
Env Coverage0 / 10
glibc
3.9–3.13
musl
3.9–3.13
Install & Compatibility
Where this runs
tested against v? · pip install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.10–3.95 runs
build_error
glibc
py 3.10–3.95 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

sagemaker_containers
✓ import sagemaker_containers
Standard import path.
Module
✓ from sagemaker_containers import _modules
✗ import sagemaker_containers._modules
Private module, but commonly accessed via underscore prefix.

Initialize a SageMaker container environment and print the current host.

import sagemaker_containers # Example: create a training environment from sagemaker_containers.beta import framework env = framework.training_env() print(env.current_host, env.hosts) # Note: This library is deprecated. Prefer sagemaker-training-toolkit for training containers.
Debug
Known issues
deprecatedThis library is deprecated. Use sagemaker-training-toolkit or sagemaker-inference-toolkit instead.
fix
Replace imports: 'sagemaker_containers' -> 'sagemaker_training' for training, or 'sagemaker_inference' for inference.
affects: >=2.8.6.post0
gotchaThe beta subpackage (sagemaker_containers.beta) is not stable and may change.
fix
Avoid relying on beta subpackages; use the stable sagemaker_training toolkit.
affects: all
gotchaPython 2 support was dropped in later versions. Version 2.8.2 mentioned creating __init__ for Python 2 protobuf import, but newer releases do not support Python 2.
fix
Use Python 3.6+ for versions after 2.8.2.
affects: >2.8.2
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'sagemaker_containers'
Package not installed or environment misconfigured (e.g., running outside SageMaker).
fix
Run 'pip install sagemaker-containers' inside the container.
AttributeError: module 'sagemaker_containers' has no attribute 'beta'
The beta subpackage was removed or renamed in newer releases of the replacement toolkit.
fix
Use 'from sagemaker_training import environment' instead.
ImportError: cannot import name 'training_env' from 'sagemaker_containers.beta.framework'
Typo or incorrect subpackage path.
fix
Correct import: 'from sagemaker_containers.beta import framework' then use 'framework.training_env()'.
Upgrade
Version history
2.8.6.post2latest on PyPI · released Jun 22, 2020
Audit
Dependencies

No dependency data recorded yet.

Agent activity
25 hits · last 30 days
node
22
Resources
sagemaker-containers — pip install sagemaker-containers · libregistry