From d377971faa628e7b6c507dc76f2deef0424d415b Mon Sep 17 00:00:00 2001 From: Oleksandr Shchur Date: Sat, 19 Sep 2026 15:55:51 +0000 Subject: [PATCH 1/3] Fix SageMaker SDK v2 documentation links --- .../cloud/backend/sagemaker_backend.py | 22 +++++++++---------- .../cloud/scripts/sagemaker_scripts/train.py | 2 +- src/autogluon/cloud/utils/ag_sagemaker.py | 8 +++---- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/autogluon/cloud/backend/sagemaker_backend.py b/src/autogluon/cloud/backend/sagemaker_backend.py index 0d16db2..a26d334 100644 --- a/src/autogluon/cloud/backend/sagemaker_backend.py +++ b/src/autogluon/cloud/backend/sagemaker_backend.py @@ -223,10 +223,10 @@ def fit( Use `get_fit_job_status` to get job status. autogluon_sagemaker_estimator_kwargs: dict, default = dict() Any extra arguments needed to initialize AutoGluonSagemakerEstimator - Please refer to https://sagemaker.readthedocs.io/en/stable/api/training/estimators.html#sagemaker.estimator.Framework for all options + Please refer to https://sagemaker.readthedocs.io/en/v2/api/training/estimators.html#sagemaker.estimator.Estimator for all options fit_kwargs: Any extra arguments needed to pass to fit. - Please refer to https://sagemaker.readthedocs.io/en/stable/api/training/estimators.html#sagemaker.estimator.Framework.fit for all options + Please refer to https://sagemaker.readthedocs.io/en/v2/api/training/estimators.html#sagemaker.estimator.Estimator.fit for all options extra_ag_args: Optional[Dict[str, Any]], default = None Additional entries to merge into ``ag_args.json``. Use this to ship caller-specific metadata to the train script (e.g. ``predict_after_fit``, ``save_predictor``, or ``id_column`` / @@ -400,7 +400,7 @@ def deploy( custom_image_uri: Optional[str], default = None, Custom image to use to deploy endpoint with. If not specified, with use official DLC image: - https://github.com/aws/deep-learning-containers/blob/master/available_images.md#autogluon-inference-containers + https://aws.github.io/deep-learning-containers/reference/available_images/ volume_size: int, default = None The size, in GB, of the ML storage volume attached to individual inference instance associated with the production variant. Currenly only Amazon EBS gp2 storage volumes are supported. @@ -409,10 +409,10 @@ def deploy( To be noticed, the function won't return immediately because there are some preparations needed prior deployment. model_kwargs: dict, default = dict() Any extra arguments needed to initialize Sagemaker Model - Please refer to https://sagemaker.readthedocs.io/en/stable/api/inference/model.html#model for all options + Please refer to https://sagemaker.readthedocs.io/en/v2/api/inference/model.html#model for all options deploy_kwargs: Any extra arguments needed to pass to deploy. - Please refer to https://sagemaker.readthedocs.io/en/stable/api/inference/model.html#sagemaker.model.Model.deploy for all options + Please refer to https://sagemaker.readthedocs.io/en/v2/api/inference/model.html#sagemaker.model.Model.deploy for all options fm_serve_config: Optional[Dict[str, Any]], default = None Configuration dict passed to the FM serve script via the AG_FM_SERVE_CONFIG env var. inference_mode: {"realtime", "serverless"}, default = "realtime" @@ -821,14 +821,14 @@ def predict( If `persist` is `False`, file would first be downloaded to this path and then removed. model_kwargs: dict, default = dict() Any extra arguments needed to initialize Sagemaker Model - Please refer to https://sagemaker.readthedocs.io/en/stable/api/inference/model.html#model for all options + Please refer to https://sagemaker.readthedocs.io/en/v2/api/inference/model.html#model for all options transformer_kwargs: dict Any extra arguments needed to pass to transformer. - Please refer to https://sagemaker.readthedocs.io/en/stable/api/inference/transformer.html#sagemaker.transformer.Transformer for all options. + Please refer to https://sagemaker.readthedocs.io/en/v2/api/inference/transformer.html#sagemaker.transformer.Transformer for all options. transform_kwargs: Any extra arguments needed to pass to transform. Please refer to - https://sagemaker.readthedocs.io/en/stable/api/inference/transformer.html#sagemaker.transformer.Transformer.transform for all options. + https://sagemaker.readthedocs.io/en/v2/api/inference/transformer.html#sagemaker.transformer.Transformer.transform for all options. Returns ------- @@ -926,14 +926,14 @@ def predict_proba( If `persist` is `False`, file would first be downloaded to this path and then removed. model_kwargs: dict, default = dict() Any extra arguments needed to initialize Sagemaker Model - Please refer to https://sagemaker.readthedocs.io/en/stable/api/inference/model.html#model for all options + Please refer to https://sagemaker.readthedocs.io/en/v2/api/inference/model.html#model for all options transformer_kwargs: dict Any extra arguments needed to pass to transformer. - Please refer to https://sagemaker.readthedocs.io/en/stable/api/inference/transformer.html#sagemaker.transformer.Transformer for all options. + Please refer to https://sagemaker.readthedocs.io/en/v2/api/inference/transformer.html#sagemaker.transformer.Transformer for all options. transform_kwargs: Any extra arguments needed to pass to transform. Please refer to - https://sagemaker.readthedocs.io/en/stable/api/inference/transformer.html#sagemaker.transformer.Transformer.transform for all options. + https://sagemaker.readthedocs.io/en/v2/api/inference/transformer.html#sagemaker.transformer.Transformer.transform for all options. Returns diff --git a/src/autogluon/cloud/scripts/sagemaker_scripts/train.py b/src/autogluon/cloud/scripts/sagemaker_scripts/train.py index 52473dc..f4efaac 100644 --- a/src/autogluon/cloud/scripts/sagemaker_scripts/train.py +++ b/src/autogluon/cloud/scripts/sagemaker_scripts/train.py @@ -81,7 +81,7 @@ def prepare_data(data_file, predictor_type, ag_args, static_features_df=None): print(f"Args: {args}") - # See SageMaker-specific environment variables: https://sagemaker.readthedocs.io/en/stable/overview.html#prepare-a-training-script + # See SageMaker-specific environment variables: https://sagemaker.readthedocs.io/en/v2/overview.html#prepare-a-training-script os.makedirs(args.output_data_dir, mode=0o777, exist_ok=True) ag_args_file = get_input_path(args.ag_args) diff --git a/src/autogluon/cloud/utils/ag_sagemaker.py b/src/autogluon/cloud/utils/ag_sagemaker.py index f2a76e4..8a247b7 100644 --- a/src/autogluon/cloud/utils/ag_sagemaker.py +++ b/src/autogluon/cloud/utils/ag_sagemaker.py @@ -31,7 +31,7 @@ def transform(self, **kwargs): return self._session.transform(**kwargs) -# Estimator documentation: https://sagemaker.readthedocs.io/en/stable/api/training/estimators.html#estimators +# Estimator documentation: https://sagemaker.readthedocs.io/en/v2/api/training/estimators.html#estimators class AutoGluonSagemakerEstimator(Estimator): def __init__( self, @@ -132,7 +132,7 @@ def _prepare_init_params_from_job_description(cls, job_details, model_channel_na return init_params -# Documentation for Model: https://sagemaker.readthedocs.io/en/stable/api/inference/model.html#model +# Documentation for Model: https://sagemaker.readthedocs.io/en/v2/api/inference/model.html#model class AutoGluonSagemakerInferenceModel(Model): def __init__( self, @@ -253,7 +253,7 @@ def prepare_container_def( ) -# Predictor documentation: https://sagemaker.readthedocs.io/en/stable/api/inference/predictors.html +# Predictor documentation: https://sagemaker.readthedocs.io/en/v2/api/inference/predictors.html class AutoGluonRealtimePredictor(Predictor): def __init__(self, *args, **kwargs): super().__init__(*args, serializer=AutoGluonSerializer(), deserializer=PandasDeserializer(), **kwargs) @@ -264,7 +264,7 @@ def __init__(self, *args, **kwargs): super().__init__(*args, serializer=MultiModalSerializer(), deserializer=PandasDeserializer(), **kwargs) -# Predictor documentation: https://sagemaker.readthedocs.io/en/stable/api/inference/predictors.html +# Predictor documentation: https://sagemaker.readthedocs.io/en/v2/api/inference/predictors.html # SageMaker can only take in csv format for batch transformation because files need to be easily splitable to be batch processed. class AutoGluonBatchPredictor(Predictor): def __init__(self, *args, **kwargs): From d5431c947a689681879a84d9794da54fbfb60a4b Mon Sep 17 00:00:00 2001 From: Oleksandr Shchur Date: Sat, 19 Sep 2026 15:59:27 +0000 Subject: [PATCH 2/3] Fix dlc link --- src/autogluon/cloud/backend/sagemaker_backend.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/autogluon/cloud/backend/sagemaker_backend.py b/src/autogluon/cloud/backend/sagemaker_backend.py index a26d334..fc11ddc 100644 --- a/src/autogluon/cloud/backend/sagemaker_backend.py +++ b/src/autogluon/cloud/backend/sagemaker_backend.py @@ -400,7 +400,7 @@ def deploy( custom_image_uri: Optional[str], default = None, Custom image to use to deploy endpoint with. If not specified, with use official DLC image: - https://aws.github.io/deep-learning-containers/reference/available_images/ + https://aws.github.io/deep-learning-containers/reference/available_images/#autogluon volume_size: int, default = None The size, in GB, of the ML storage volume attached to individual inference instance associated with the production variant. Currenly only Amazon EBS gp2 storage volumes are supported. From 857f6d53589199ec9025f3f2522679bad10058bd Mon Sep 17 00:00:00 2001 From: Oleksandr Shchur Date: Sat, 19 Sep 2026 16:02:31 +0000 Subject: [PATCH 3/3] Fix deprecation warning --- src/autogluon/cloud/predictor/multimodal_cloud_predictor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/autogluon/cloud/predictor/multimodal_cloud_predictor.py b/src/autogluon/cloud/predictor/multimodal_cloud_predictor.py index b8d0b1c..48976bc 100644 --- a/src/autogluon/cloud/predictor/multimodal_cloud_predictor.py +++ b/src/autogluon/cloud/predictor/multimodal_cloud_predictor.py @@ -20,7 +20,7 @@ class MultiModalCloudPredictor(CloudPredictor): def __init__(self, *args, **kwargs) -> None: warnings.warn( "AutoGluon Multimodal is on a deprecation path. " - "MultiModalCloudPredictor will be removed in autogluon.cloud v0.7.0.", + "MultiModalCloudPredictor will be removed in a future release.", FutureWarning, stacklevel=2, )