AWS sagemaker documentation change
Summary
Updated documentation to replace 'estimator' references with 'ModelTrainer', added SDK v3/v2 code examples for checkpoint configuration, and clarified Debugger workaround.
Security assessment
Changes focus on SDK version updates and checkpoint configuration syntax. No security vulnerabilities, patches, or security features are mentioned. Updates are operational improvements.
Diff
diff --git a/sagemaker/latest/dg/distributed-troubleshooting-data-parallel.md b/sagemaker/latest/dg/distributed-troubleshooting-data-parallel.md index 7e17e46dc..74e1e17f2 100644 --- a//sagemaker/latest/dg/distributed-troubleshooting-data-parallel.md +++ b//sagemaker/latest/dg/distributed-troubleshooting-data-parallel.md @@ -41 +41,23 @@ This is due to an internal error between Debugger and checkpoints, which occurs - * If you enable all three features, SageMaker Python SDK automatically turns off Debugger by passing `debugger_hook_config=False`, which is equivalent to the following framework `estimator` example. + * If you enable all three features, SageMaker Python SDK automatically turns off Debugger by passing `debugger_hook_config=False`, which is equivalent to the following framework `ModelTrainer` example. + +SageMaker Python SDK v3 + + + bucket=Session().default_bucket() + base_job_name="sagemaker-checkpoint-test" + checkpoint_in_bucket="checkpoints" + + # The S3 URI to store the checkpoints + checkpoint_s3_bucket="s3://{}/{}/{}".format(bucket, base_job_name, checkpoint_in_bucket) + + model_trainer = ModelTrainer( + ... + + distribution={"smdistributed": {"dataparallel": { "enabled": True }}}, + checkpoint_s3_uri=checkpoint_s3_bucket, + checkpoint_local_path="/opt/ml/checkpoints", + debugger_hook_config=False + ) + +SageMaker Python SDK v2 (Legacy) + @@ -59 +81 @@ This is due to an internal error between Debugger and checkpoints, which occurs - * If you want to keep using both SageMaker AI distributed data parallel and SageMaker Debugger, a workaround is manually adding checkpointing functions to your training script instead of specifying the `checkpoint_s3_uri` and `checkpoint_local_path` parameters from the estimator. For more information about setting up manual checkpointing in a training script, see [Saving Checkpoints](./distributed-troubleshooting-model-parallel.html#distributed-ts-model-parallel-checkpoints). + * If you want to keep using both SageMaker AI distributed data parallel and SageMaker Debugger, a workaround is manually adding checkpointing functions to your training script instead of specifying the `checkpoint_s3_uri` and `checkpoint_local_path` parameters from the ModelTrainer. For more information about setting up manual checkpointing in a training script, see [Saving Checkpoints](./distributed-troubleshooting-model-parallel.html#distributed-ts-model-parallel-checkpoints).