autogluon.cloud 0.4.2__tar.gz → 0.6.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. autogluon_cloud-0.6.0/PKG-INFO +150 -0
  2. autogluon_cloud-0.6.0/README.md +93 -0
  3. autogluon_cloud-0.6.0/pyproject.toml +109 -0
  4. autogluon_cloud-0.6.0/setup.cfg +4 -0
  5. autogluon_cloud-0.6.0/setup.py +33 -0
  6. autogluon_cloud-0.6.0/src/autogluon/cloud/__init__.py +37 -0
  7. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/backend.py +56 -12
  8. autogluon_cloud-0.6.0/src/autogluon/cloud/backend/backend_factory.py +47 -0
  9. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/constant.py +3 -0
  10. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/ray_aws_backend.py +4 -9
  11. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/ray_backend.py +12 -17
  12. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/sagemaker_backend.py +296 -196
  13. autogluon_cloud-0.6.0/src/autogluon/cloud/backend/tabular_sagemaker_backend.py +67 -0
  14. autogluon_cloud-0.6.0/src/autogluon/cloud/backend/timeseries_sagemaker_backend.py +272 -0
  15. autogluon_cloud-0.6.0/src/autogluon/cloud/cli.py +258 -0
  16. autogluon_cloud-0.6.0/src/autogluon/cloud/cloud_setup.py +374 -0
  17. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/cluster_config_generator.py +3 -3
  18. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/cluster_manager.py +0 -7
  19. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/ray_aws_cluster_config_generator.py +24 -15
  20. autogluon_cloud-0.6.0/src/autogluon/cloud/cluster/ray_aws_cluster_manager.py +11 -0
  21. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/ray_cluster_manager.py +2 -9
  22. autogluon_cloud-0.6.0/src/autogluon/cloud/config.py +96 -0
  23. autogluon_cloud-0.6.0/src/autogluon/cloud/default_cluster_configs/ray_aws_default_cluster_config.yaml +47 -0
  24. autogluon_cloud-0.6.0/src/autogluon/cloud/endpoint/prediction_future.py +51 -0
  25. autogluon_cloud-0.6.0/src/autogluon/cloud/endpoint/tabular_endpoint.py +128 -0
  26. autogluon_cloud-0.6.0/src/autogluon/cloud/endpoint/timeseries_endpoint.py +112 -0
  27. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/job/sagemaker_job.py +10 -7
  28. autogluon_cloud-0.6.0/src/autogluon/cloud/model/__init__.py +10 -0
  29. autogluon_cloud-0.6.0/src/autogluon/cloud/model/foundation_model.py +854 -0
  30. autogluon_cloud-0.6.0/src/autogluon/cloud/model/registry.py +81 -0
  31. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/predictor/cloud_predictor.py +109 -105
  32. autogluon_cloud-0.6.0/src/autogluon/cloud/predictor/multimodal_cloud_predictor.py +40 -0
  33. autogluon_cloud-0.6.0/src/autogluon/cloud/predictor/tabular_cloud_predictor.py +258 -0
  34. autogluon_cloud-0.6.0/src/autogluon/cloud/predictor/timeseries_cloud_predictor.py +439 -0
  35. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/ray_scripts/train.py +5 -4
  36. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/sagemaker_scripts/multimodal_serve.py +11 -17
  37. autogluon_cloud-0.6.0/src/autogluon/cloud/scripts/sagemaker_scripts/serving_utils/__init__.py +0 -0
  38. autogluon_cloud-0.6.0/src/autogluon/cloud/scripts/sagemaker_scripts/serving_utils/timeseries.py +135 -0
  39. autogluon_cloud-0.6.0/src/autogluon/cloud/scripts/sagemaker_scripts/tabular_fm_serve.py +117 -0
  40. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/sagemaker_scripts/tabular_serve.py +8 -10
  41. autogluon_cloud-0.6.0/src/autogluon/cloud/scripts/sagemaker_scripts/timeseries_fm_serve.py +62 -0
  42. autogluon_cloud-0.6.0/src/autogluon/cloud/scripts/sagemaker_scripts/timeseries_serve.py +48 -0
  43. autogluon_cloud-0.6.0/src/autogluon/cloud/scripts/sagemaker_scripts/train.py +222 -0
  44. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/script_manager.py +3 -0
  45. autogluon_cloud-0.6.0/src/autogluon/cloud/templates/ag_cloud_ray_aws.yaml +128 -0
  46. autogluon_cloud-0.6.0/src/autogluon/cloud/templates/ag_cloud_sagemaker.yaml +132 -0
  47. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/__init__.py +1 -1
  48. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/ag_sagemaker.py +41 -19
  49. autogluon_cloud-0.6.0/src/autogluon/cloud/utils/autogluon_dlc.json +1515 -0
  50. autogluon_cloud-0.6.0/src/autogluon/cloud/utils/aws_utils.py +184 -0
  51. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/constants.py +0 -2
  52. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/deserializers.py +3 -3
  53. autogluon_cloud-0.6.0/src/autogluon/cloud/utils/dlc_utils.py +142 -0
  54. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/ec2.py +2 -2
  55. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/ray_aws_iam.py +0 -3
  56. autogluon_cloud-0.6.0/src/autogluon/cloud/utils/serializers.py +135 -0
  57. autogluon_cloud-0.6.0/src/autogluon/cloud/utils/tag_utils.py +27 -0
  58. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/utils.py +41 -5
  59. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/version.py +1 -1
  60. autogluon_cloud-0.6.0/src/autogluon.cloud.egg-info/PKG-INFO +150 -0
  61. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon.cloud.egg-info/SOURCES.txt +19 -4
  62. autogluon_cloud-0.6.0/src/autogluon.cloud.egg-info/entry_points.txt +2 -0
  63. autogluon_cloud-0.6.0/src/autogluon.cloud.egg-info/requires.txt +23 -0
  64. autogluon.cloud-0.4.2/PKG-INFO +0 -80
  65. autogluon.cloud-0.4.2/README.md +0 -41
  66. autogluon.cloud-0.4.2/pyproject.toml +0 -16
  67. autogluon.cloud-0.4.2/setup.cfg +0 -90
  68. autogluon.cloud-0.4.2/setup.py +0 -148
  69. autogluon.cloud-0.4.2/src/autogluon/__init__.py +0 -1
  70. autogluon.cloud-0.4.2/src/autogluon/cloud/__init__.py +0 -5
  71. autogluon.cloud-0.4.2/src/autogluon/cloud/backend/backend_factory.py +0 -29
  72. autogluon.cloud-0.4.2/src/autogluon/cloud/backend/tabular_sagemaker_backend.py +0 -6
  73. autogluon.cloud-0.4.2/src/autogluon/cloud/backend/timeseries_sagemaker_backend.py +0 -252
  74. autogluon.cloud-0.4.2/src/autogluon/cloud/cluster/ray_aws_cluster_manager.py +0 -76
  75. autogluon.cloud-0.4.2/src/autogluon/cloud/predictor/multimodal_cloud_predictor.py +0 -24
  76. autogluon.cloud-0.4.2/src/autogluon/cloud/predictor/tabular_cloud_predictor.py +0 -24
  77. autogluon.cloud-0.4.2/src/autogluon/cloud/predictor/timeseries_cloud_predictor.py +0 -328
  78. autogluon.cloud-0.4.2/src/autogluon/cloud/scripts/sagemaker_scripts/timeseries_serve.py +0 -97
  79. autogluon.cloud-0.4.2/src/autogluon/cloud/scripts/sagemaker_scripts/train.py +0 -173
  80. autogluon.cloud-0.4.2/src/autogluon/cloud/utils/aws_utils.py +0 -50
  81. autogluon.cloud-0.4.2/src/autogluon/cloud/utils/dlc_utils.py +0 -75
  82. autogluon.cloud-0.4.2/src/autogluon/cloud/utils/sagemaker_iam.py +0 -155
  83. autogluon.cloud-0.4.2/src/autogluon/cloud/utils/serializers.py +0 -156
  84. autogluon.cloud-0.4.2/src/autogluon.cloud.egg-info/PKG-INFO +0 -80
  85. autogluon.cloud-0.4.2/src/autogluon.cloud.egg-info/namespace_packages.txt +0 -1
  86. autogluon.cloud-0.4.2/src/autogluon.cloud.egg-info/requires.txt +0 -18
  87. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/LICENSE +0 -0
  88. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/NOTICE +0 -0
  89. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/__init__.py +0 -0
  90. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/backend/multimodal_sagemaker_backend.py +0 -0
  91. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/__init__.py +0 -0
  92. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/constants.py +0 -0
  93. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/cluster/ray_cluster_config_generator.py +0 -0
  94. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/data/__init__.py +0 -0
  95. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/data/format_converter.py +0 -0
  96. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/default_cluster_configs/__init__.py +0 -0
  97. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/endpoint/__init__.py +0 -0
  98. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/endpoint/endpoint.py +0 -0
  99. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/endpoint/sagemaker_endpoint.py +0 -0
  100. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/job/__init__.py +0 -0
  101. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/job/ray_job.py +0 -0
  102. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/job/remote_job.py +0 -0
  103. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/predictor/__init__.py +0 -0
  104. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/__init__.py +0 -0
  105. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/ray_scripts/__init__.py +0 -0
  106. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/scripts/sagemaker_scripts/__init__.py +0 -0
  107. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/iam.py +0 -0
  108. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/misc.py +0 -0
  109. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon/cloud/utils/s3_utils.py +0 -0
  110. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon.cloud.egg-info/dependency_links.txt +0 -0
  111. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon.cloud.egg-info/top_level.txt +0 -0
  112. {autogluon.cloud-0.4.2 → autogluon_cloud-0.6.0}/src/autogluon.cloud.egg-info/zip-safe +0 -0
@@ -0,0 +1,150 @@
1
+ Metadata-Version: 2.4
2
+ Name: autogluon.cloud
3
+ Version: 0.6.0
4
+ Summary: Train and deploy ML models in the cloud
5
+ Author: AutoGluon Community
6
+ License-Expression: Apache-2.0
7
+ Project-URL: Documentation, https://auto.gluon.ai/cloud
8
+ Project-URL: Bug Reports, https://github.com/autogluon/autogluon-cloud/issues
9
+ Project-URL: Source, https://github.com/autogluon/autogluon-cloud/
10
+ Project-URL: Contribute!, https://github.com/autogluon/autogluon-cloud/blob/master/CONTRIBUTING.md
11
+ Classifier: Development Status :: 4 - Beta
12
+ Classifier: Intended Audience :: Education
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: Intended Audience :: Science/Research
15
+ Classifier: Intended Audience :: Customer Service
16
+ Classifier: Intended Audience :: Financial and Insurance Industry
17
+ Classifier: Intended Audience :: Healthcare Industry
18
+ Classifier: Intended Audience :: Telecommunications Industry
19
+ Classifier: Operating System :: MacOS
20
+ Classifier: Operating System :: Microsoft :: Windows
21
+ Classifier: Operating System :: POSIX
22
+ Classifier: Operating System :: Unix
23
+ Classifier: Programming Language :: Python :: 3
24
+ Classifier: Programming Language :: Python :: 3.10
25
+ Classifier: Programming Language :: Python :: 3.11
26
+ Classifier: Programming Language :: Python :: 3.12
27
+ Classifier: Programming Language :: Python :: 3.13
28
+ Classifier: Topic :: Software Development
29
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
30
+ Classifier: Topic :: Scientific/Engineering :: Information Analysis
31
+ Classifier: Topic :: Scientific/Engineering :: Image Recognition
32
+ Requires-Python: <3.14,>=3.10
33
+ Description-Content-Type: text/markdown
34
+ License-File: LICENSE
35
+ License-File: NOTICE
36
+ Requires-Dist: autogluon.common<1.7,>=0.7
37
+ Requires-Dist: boto3<2,>=1.37.23
38
+ Requires-Dist: packaging<27,>=23.0
39
+ Requires-Dist: sagemaker<3,>=2.240.0
40
+ Requires-Dist: pyarrow<25,>=19.0.1
41
+ Requires-Dist: PyYAML~=6.0
42
+ Requires-Dist: Pillow<13,>=10.2
43
+ Requires-Dist: huggingface_hub<2,>=0.20
44
+ Requires-Dist: typing_extensions<5,>=4.0
45
+ Requires-Dist: click<9,>=8.0
46
+ Requires-Dist: rich<15,>=13.0
47
+ Provides-Extra: ray
48
+ Requires-Dist: ray[default]<2.59,>=2.10.0; extra == "ray"
49
+ Provides-Extra: all
50
+ Requires-Dist: autogluon<1.7,>=0.7; extra == "all"
51
+ Requires-Dist: autogluon.cloud[ray]; extra == "all"
52
+ Provides-Extra: tests
53
+ Requires-Dist: pytest; extra == "tests"
54
+ Requires-Dist: moto; extra == "tests"
55
+ Requires-Dist: autogluon.common>=0.7; extra == "tests"
56
+ Dynamic: license-file
57
+
58
+
59
+
60
+ <div align="center">
61
+ <img src="https://user-images.githubusercontent.com/16392542/77208906-224aa500-6aba-11ea-96bd-e81806074030.png" width="350">
62
+
63
+ ## Train and Deploy AutoGluon in the Cloud
64
+
65
+ [![PyPI](https://img.shields.io/pypi/v/autogluon.cloud.svg)](https://pypi.org/project/autogluon.cloud/)
66
+ [![Python Versions](https://img.shields.io/badge/python-3.10%20%7C%203.11%20%7C%203.12-blue)](https://pypi.org/project/autogluon.cloud/)
67
+ [![GitHub license](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](./LICENSE)
68
+ [![Continuous Integration](https://github.com/autogluon/autogluon-cloud/actions/workflows/continuous_integration.yml/badge.svg)](https://github.com/autogluon/autogluon-cloud/actions/workflows/continuous_integration.yml)
69
+
70
+ [AutoGluon-Cloud Documentation](https://auto.gluon.ai/cloud/stable/index.html) | [AutoGluon Documentation](https://auto.gluon.ai)
71
+
72
+ </div>
73
+
74
+ AutoGluon-Cloud lets you train and deploy state-of-the-art ML models in the cloud in a few lines of code. Run [AutoGluon](https://auto.gluon.ai/stable/index.html) on [Amazon SageMaker](https://aws.amazon.com/sagemaker/) without worrying about infrastructure, dependencies, or a heavy local ML environment. It supports two workflows:
75
+
76
+ - **[Train your own predictor](https://auto.gluon.ai/cloud/stable/tutorials/predictor-tabular.html)** — the same `fit → deploy → predict` workflow as local AutoGluon, with all the heavy lifting offloaded to SageMaker.
77
+ - **[Run pretrained foundation models](https://auto.gluon.ai/cloud/stable/tutorials/foundation-model-timeseries.html)** — deploy state-of-the-art pretrained models like [Chronos-2](https://huggingface.co/amazon/chronos-2) for zero-shot inference, with no training required.
78
+
79
+ ## 💾 Installation & setup
80
+
81
+ ```bash
82
+ pip install autogluon.cloud
83
+ ```
84
+
85
+ Then provision the IAM role and S3 bucket AutoGluon-Cloud needs to run on AWS:
86
+
87
+ ```python
88
+ from autogluon.cloud import bootstrap
89
+
90
+ bootstrap()
91
+ ```
92
+
93
+ See the [Setup tutorial](https://auto.gluon.ai/cloud/stable/tutorials/setup.html) for the full walkthrough, including how to register an existing role and bucket instead.
94
+
95
+ ## ⚙️ Train your own model
96
+
97
+ Train an AutoGluon predictor on your data and serve it from a SageMaker endpoint — same API as local AutoGluon, all heavy lifting on AWS. Full walkthrough: [tabular](https://auto.gluon.ai/cloud/stable/tutorials/predictor-tabular.html), [time series](https://auto.gluon.ai/cloud/stable/tutorials/predictor-timeseries.html).
98
+
99
+ ```python
100
+ from autogluon.cloud import TabularCloudPredictor
101
+
102
+ # `train_data` and `test_data` can be a local path, S3 URL, or pandas DataFrame
103
+ train_data = "https://autogluon.s3.amazonaws.com/datasets/Inc/train.csv"
104
+ test_data = "https://autogluon.s3.amazonaws.com/datasets/Inc/test.csv"
105
+
106
+ # Train
107
+ cloud_predictor = TabularCloudPredictor()
108
+ cloud_predictor.fit(
109
+ train_data=train_data,
110
+ predictor_init_args={"label": "class"}, # passed to TabularPredictor()
111
+ predictor_fit_args={"time_limit": 120}, # passed to TabularPredictor.fit()
112
+ )
113
+
114
+ # Real-time inference endpoint
115
+ cloud_predictor.deploy()
116
+ result = cloud_predictor.predict_real_time(test_data)
117
+ cloud_predictor.cleanup_deployment()
118
+
119
+ # Batch prediction
120
+ result = cloud_predictor.predict(test_data)
121
+ ```
122
+
123
+ ## 🚀 Run a pretrained foundation model
124
+
125
+ Skip training entirely — deploy a pretrained model like Chronos-2 to SageMaker and get zero-shot predictions out of the box. Full walkthrough: [time series](https://auto.gluon.ai/cloud/stable/tutorials/foundation-model-timeseries.html).
126
+
127
+ ```python
128
+ from autogluon.cloud import TimeSeriesFoundationModel
129
+
130
+ # `data` can be a local path, S3 URL, or pandas DataFrame
131
+ data = "https://autogluon.s3.amazonaws.com/datasets/timeseries/m4_hourly_tiny/train.csv"
132
+
133
+ model = TimeSeriesFoundationModel("chronos-2")
134
+
135
+ # Batch prediction — no training required
136
+ predictions = model.predict(
137
+ data=data,
138
+ target="target",
139
+ prediction_length=24,
140
+ )
141
+
142
+ # Real-time inference endpoint
143
+ endpoint = model.deploy()
144
+ predictions = endpoint.predict(
145
+ data=data,
146
+ target="target",
147
+ prediction_length=24,
148
+ )
149
+ endpoint.delete_endpoint()
150
+ ```
@@ -0,0 +1,93 @@
1
+
2
+
3
+ <div align="center">
4
+ <img src="https://user-images.githubusercontent.com/16392542/77208906-224aa500-6aba-11ea-96bd-e81806074030.png" width="350">
5
+
6
+ ## Train and Deploy AutoGluon in the Cloud
7
+
8
+ [![PyPI](https://img.shields.io/pypi/v/autogluon.cloud.svg)](https://pypi.org/project/autogluon.cloud/)
9
+ [![Python Versions](https://img.shields.io/badge/python-3.10%20%7C%203.11%20%7C%203.12-blue)](https://pypi.org/project/autogluon.cloud/)
10
+ [![GitHub license](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](./LICENSE)
11
+ [![Continuous Integration](https://github.com/autogluon/autogluon-cloud/actions/workflows/continuous_integration.yml/badge.svg)](https://github.com/autogluon/autogluon-cloud/actions/workflows/continuous_integration.yml)
12
+
13
+ [AutoGluon-Cloud Documentation](https://auto.gluon.ai/cloud/stable/index.html) | [AutoGluon Documentation](https://auto.gluon.ai)
14
+
15
+ </div>
16
+
17
+ AutoGluon-Cloud lets you train and deploy state-of-the-art ML models in the cloud in a few lines of code. Run [AutoGluon](https://auto.gluon.ai/stable/index.html) on [Amazon SageMaker](https://aws.amazon.com/sagemaker/) without worrying about infrastructure, dependencies, or a heavy local ML environment. It supports two workflows:
18
+
19
+ - **[Train your own predictor](https://auto.gluon.ai/cloud/stable/tutorials/predictor-tabular.html)** — the same `fit → deploy → predict` workflow as local AutoGluon, with all the heavy lifting offloaded to SageMaker.
20
+ - **[Run pretrained foundation models](https://auto.gluon.ai/cloud/stable/tutorials/foundation-model-timeseries.html)** — deploy state-of-the-art pretrained models like [Chronos-2](https://huggingface.co/amazon/chronos-2) for zero-shot inference, with no training required.
21
+
22
+ ## 💾 Installation & setup
23
+
24
+ ```bash
25
+ pip install autogluon.cloud
26
+ ```
27
+
28
+ Then provision the IAM role and S3 bucket AutoGluon-Cloud needs to run on AWS:
29
+
30
+ ```python
31
+ from autogluon.cloud import bootstrap
32
+
33
+ bootstrap()
34
+ ```
35
+
36
+ See the [Setup tutorial](https://auto.gluon.ai/cloud/stable/tutorials/setup.html) for the full walkthrough, including how to register an existing role and bucket instead.
37
+
38
+ ## ⚙️ Train your own model
39
+
40
+ Train an AutoGluon predictor on your data and serve it from a SageMaker endpoint — same API as local AutoGluon, all heavy lifting on AWS. Full walkthrough: [tabular](https://auto.gluon.ai/cloud/stable/tutorials/predictor-tabular.html), [time series](https://auto.gluon.ai/cloud/stable/tutorials/predictor-timeseries.html).
41
+
42
+ ```python
43
+ from autogluon.cloud import TabularCloudPredictor
44
+
45
+ # `train_data` and `test_data` can be a local path, S3 URL, or pandas DataFrame
46
+ train_data = "https://autogluon.s3.amazonaws.com/datasets/Inc/train.csv"
47
+ test_data = "https://autogluon.s3.amazonaws.com/datasets/Inc/test.csv"
48
+
49
+ # Train
50
+ cloud_predictor = TabularCloudPredictor()
51
+ cloud_predictor.fit(
52
+ train_data=train_data,
53
+ predictor_init_args={"label": "class"}, # passed to TabularPredictor()
54
+ predictor_fit_args={"time_limit": 120}, # passed to TabularPredictor.fit()
55
+ )
56
+
57
+ # Real-time inference endpoint
58
+ cloud_predictor.deploy()
59
+ result = cloud_predictor.predict_real_time(test_data)
60
+ cloud_predictor.cleanup_deployment()
61
+
62
+ # Batch prediction
63
+ result = cloud_predictor.predict(test_data)
64
+ ```
65
+
66
+ ## 🚀 Run a pretrained foundation model
67
+
68
+ Skip training entirely — deploy a pretrained model like Chronos-2 to SageMaker and get zero-shot predictions out of the box. Full walkthrough: [time series](https://auto.gluon.ai/cloud/stable/tutorials/foundation-model-timeseries.html).
69
+
70
+ ```python
71
+ from autogluon.cloud import TimeSeriesFoundationModel
72
+
73
+ # `data` can be a local path, S3 URL, or pandas DataFrame
74
+ data = "https://autogluon.s3.amazonaws.com/datasets/timeseries/m4_hourly_tiny/train.csv"
75
+
76
+ model = TimeSeriesFoundationModel("chronos-2")
77
+
78
+ # Batch prediction — no training required
79
+ predictions = model.predict(
80
+ data=data,
81
+ target="target",
82
+ prediction_length=24,
83
+ )
84
+
85
+ # Real-time inference endpoint
86
+ endpoint = model.deploy()
87
+ predictions = endpoint.predict(
88
+ data=data,
89
+ target="target",
90
+ prediction_length=24,
91
+ )
92
+ endpoint.delete_endpoint()
93
+ ```
@@ -0,0 +1,109 @@
1
+ [build-system]
2
+ requires = ["setuptools>=77", "wheel"] # >=77 for PEP 639 SPDX license expression support
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "autogluon.cloud"
7
+ description = "Train and deploy ML models in the cloud"
8
+ readme = "README.md"
9
+ requires-python = ">=3.10,<3.14"
10
+ license = "Apache-2.0"
11
+ license-files = ["LICENSE", "NOTICE"]
12
+ authors = [{ name = "AutoGluon Community" }]
13
+ classifiers = [
14
+ "Development Status :: 4 - Beta",
15
+ "Intended Audience :: Education",
16
+ "Intended Audience :: Developers",
17
+ "Intended Audience :: Science/Research",
18
+ "Intended Audience :: Customer Service",
19
+ "Intended Audience :: Financial and Insurance Industry",
20
+ "Intended Audience :: Healthcare Industry",
21
+ "Intended Audience :: Telecommunications Industry",
22
+ "Operating System :: MacOS",
23
+ "Operating System :: Microsoft :: Windows",
24
+ "Operating System :: POSIX",
25
+ "Operating System :: Unix",
26
+ "Programming Language :: Python :: 3",
27
+ "Programming Language :: Python :: 3.10",
28
+ "Programming Language :: Python :: 3.11",
29
+ "Programming Language :: Python :: 3.12",
30
+ "Programming Language :: Python :: 3.13",
31
+ "Topic :: Software Development",
32
+ "Topic :: Scientific/Engineering :: Artificial Intelligence",
33
+ "Topic :: Scientific/Engineering :: Information Analysis",
34
+ "Topic :: Scientific/Engineering :: Image Recognition",
35
+ ]
36
+ # version stays dynamic and is owned by setup.py (so the RELEASE=1 -> clean
37
+ # version, else .dev0 logic keeps working).
38
+ dynamic = ["version"]
39
+ dependencies = [
40
+ # common module provides utils with stable api across minor version
41
+ "autogluon.common>=0.7,<1.7",
42
+ # <2 because unlikely to introduce breaking changes in minor releases.
43
+ # TransformAmiVersion was added to the SageMaker service model in botocore 1.37.23.
44
+ "boto3>=1.37.23,<2",
45
+ "packaging>=23.0,<27",
46
+ # Supports forwarding inference_ami_version from Model.deploy.
47
+ "sagemaker>=2.240.0,<3",
48
+ "pyarrow>=19.0.1,<25", # lower bound to avoid https://github.com/apache/arrow/issues/45283
49
+ "PyYAML~=6.0",
50
+ "Pillow>=10.2,<13",
51
+ "huggingface_hub>=0.20,<2",
52
+ "typing_extensions>=4.0,<5",
53
+ # CLI dependencies (autogluon-cloud command)
54
+ "click>=8.0,<9",
55
+ "rich>=13.0,<15",
56
+ ]
57
+
58
+ [project.optional-dependencies]
59
+ ray = ["ray[default]>=2.10.0,<2.59"]
60
+ all = [ # To allow user to pass ag objects
61
+ "autogluon>=0.7,<1.7",
62
+ "autogluon.cloud[ray]",
63
+ ]
64
+ tests = [
65
+ "pytest",
66
+ "moto",
67
+ "autogluon.common>=0.7",
68
+ ]
69
+
70
+ [project.urls]
71
+ Documentation = "https://auto.gluon.ai/cloud"
72
+ "Bug Reports" = "https://github.com/autogluon/autogluon-cloud/issues"
73
+ Source = "https://github.com/autogluon/autogluon-cloud/"
74
+ "Contribute!" = "https://github.com/autogluon/autogluon-cloud/blob/master/CONTRIBUTING.md"
75
+
76
+ [project.scripts]
77
+ autogluon-cloud = "autogluon.cloud.cli:main"
78
+
79
+ [tool.setuptools]
80
+ zip-safe = true
81
+ include-package-data = true
82
+
83
+ [tool.setuptools.packages.find]
84
+ where = ["src"]
85
+ namespaces = true
86
+
87
+ [tool.setuptools.package-data]
88
+ "autogluon.cloud" = [
89
+ "default_cluster_configs/*.yaml",
90
+ "utils/autogluon_dlc.json",
91
+ "templates/*.yaml",
92
+ ]
93
+
94
+ [tool.ruff]
95
+ line-length = 119
96
+ target-version = "py310"
97
+
98
+ [tool.ruff.lint]
99
+ select = ["E", "F", "I", "W"]
100
+ ignore = ["E501"]
101
+ per-file-ignores = {"*/__init__.py" = ["F401"]}
102
+
103
+ [tool.ruff.lint.isort]
104
+ known-first-party = ["autogluon"]
105
+
106
+ [tool.pytest.ini_options]
107
+ testpaths = ["tests"]
108
+ addopts = "--strict-markers"
109
+ xfail_strict = true
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,33 @@
1
+ import os
2
+
3
+ from setuptools import setup
4
+
5
+ AUTOGLUON = "autogluon"
6
+ CLOUD = "cloud"
7
+
8
+
9
+ def create_version_file(*, version):
10
+ print("-- Building version " + version)
11
+ version_path = os.path.join("src", AUTOGLUON, CLOUD, "version.py")
12
+ with open(version_path, "w") as f:
13
+ f.write(f'"""This is the {AUTOGLUON}.{CLOUD} version file."""\n')
14
+ f.write("__version__ = '{}'\n".format(version))
15
+
16
+
17
+ def update_version(version):
18
+ """
19
+ To release a new stable version on PyPi, tag the release on github; the Github CI publishes it to PyPi
20
+ (see .github/workflows/pypi_release.yml, which sets RELEASE=1). Non-release builds get a `.dev0` suffix.
21
+ """
22
+ if not os.getenv("RELEASE"):
23
+ version += ".dev0"
24
+ return version
25
+
26
+
27
+ version = "0.6.0"
28
+ version = update_version(version)
29
+
30
+ if __name__ == "__main__":
31
+ create_version_file(version=version)
32
+ # Everything except the dynamic version lives in pyproject.toml.
33
+ setup(version=version)
@@ -0,0 +1,37 @@
1
+ import logging
2
+ import os
3
+
4
+ os.environ.setdefault("SAGEMAKER_SUPPRESS_V2_WARNING", "1")
5
+ import sagemaker
6
+ from packaging.version import Version
7
+
8
+ if Version(sagemaker.__version__) >= Version("3.0"):
9
+ raise ImportError(
10
+ f"SageMaker SDK >= 3.0 is currently not supported (found {sagemaker.__version__}). "
11
+ "Please downgrade: pip install -U 'sagemaker<3'"
12
+ )
13
+
14
+ from autogluon.common.utils.log_utils import _add_stream_handler
15
+
16
+ from .cloud_setup import bootstrap, register, status, teardown
17
+ from .endpoint.tabular_endpoint import TabularEndpoint
18
+ from .endpoint.timeseries_endpoint import TimeSeriesEndpoint
19
+ from .model.foundation_model import TabularFoundationModel, TimeSeriesFoundationModel
20
+ from .predictor import MultiModalCloudPredictor, TabularCloudPredictor, TimeSeriesCloudPredictor
21
+
22
+ _add_stream_handler()
23
+ logging.getLogger(__name__).setLevel(logging.INFO)
24
+
25
+ __all__ = [
26
+ "MultiModalCloudPredictor",
27
+ "TabularCloudPredictor",
28
+ "TabularEndpoint",
29
+ "TabularFoundationModel",
30
+ "TimeSeriesCloudPredictor",
31
+ "TimeSeriesEndpoint",
32
+ "TimeSeriesFoundationModel",
33
+ "bootstrap",
34
+ "register",
35
+ "status",
36
+ "teardown",
37
+ ]
@@ -1,6 +1,7 @@
1
1
  from __future__ import annotations
2
2
 
3
- import pickle
3
+ import json
4
+ import os
4
5
  from abc import ABC, abstractmethod
5
6
  from typing import Any, Dict, List, Optional, Union
6
7
 
@@ -9,6 +10,34 @@ import pandas as pd
9
10
  from ..endpoint.endpoint import Endpoint
10
11
 
11
12
 
13
+ def dumps_ag_args(config: Dict[str, Any]) -> str:
14
+ """Serialize the remote-training config to JSON, raising a user-facing error on failure.
15
+
16
+ The config carries the user's predictor init/fit arguments. Some objects (search spaces,
17
+ custom metric objects, classes/callables in ``hyperparameters``) are not JSON-serializable;
18
+ when that happens we pinpoint the offending argument so the error names what the user passed.
19
+ """
20
+ try:
21
+ return json.dumps(config)
22
+ except TypeError as e:
23
+ original_error = e
24
+ for group in ("predictor_init_args", "predictor_fit_args"):
25
+ for key, value in (config.get(group) or {}).items():
26
+ try:
27
+ json.dumps(value)
28
+ except TypeError as e:
29
+ raise TypeError(
30
+ f"The value passed for `{key}` is not JSON-serializable. This can happen with "
31
+ f"search spaces (Real/Categorical/Int), custom metric objects, or classes/callables "
32
+ f"in `hyperparameters`. Please pass these as plain values (e.g. metric names as strings). "
33
+ f"Original error: {e}"
34
+ ) from e
35
+ # Culprit is outside the known arg groups; re-raise the original error with generic guidance.
36
+ raise TypeError(
37
+ f"The provided arguments are not JSON-serializable. Original error: {original_error}"
38
+ ) from original_error
39
+
40
+
12
41
  class Backend(ABC):
13
42
  name = "backend"
14
43
 
@@ -18,22 +47,28 @@ class Backend(ABC):
18
47
  @property
19
48
  def cloud_output_path(self) -> str:
20
49
  if not self._cloud_output_path:
21
- raise ValueError(f"cloud_output_path is needed. Please pass it during init of {self.__class__.__name__}")
50
+ raise ValueError(
51
+ "No `cloud_output_path` was provided and no bucket is configured in "
52
+ "~/.autogluon/cloud.yaml. Either pass `cloud_output_path=` explicitly, or run "
53
+ "`autogluon.cloud.bootstrap()` / `register(bucket=...)` once to persist a bucket."
54
+ )
22
55
  return self._cloud_output_path
23
56
 
24
57
  def initialize(
25
- self, local_output_path: str, predictor_type: str, cloud_output_path: Optional[str] = None, **kwargs
58
+ self,
59
+ local_output_path: str,
60
+ predictor_type: str,
61
+ cloud_output_path: Optional[str] = None,
62
+ resource_prefix: Optional[str] = None,
63
+ **kwargs,
26
64
  ) -> None:
27
65
  """Initialize the backend."""
28
66
  self.local_output_path = local_output_path
29
67
  self._cloud_output_path = cloud_output_path
30
68
  self.predictor_type = predictor_type
69
+ self.resource_prefix = resource_prefix or f"ag-cloud-{predictor_type}"
31
70
  self.original_features = None
32
-
33
- @abstractmethod
34
- def generate_default_permission(self, **kwargs) -> Dict[str, str]:
35
- """Generate default permission file user could use to setup the corresponding entity, i.e. IAM Role in AWS"""
36
- raise NotImplementedError
71
+ self.endpoint: Optional[Endpoint] = None
37
72
 
38
73
  @abstractmethod
39
74
  def parse_backend_fit_kwargs(self, kwargs: Dict) -> Dict[str, Any]:
@@ -82,17 +117,19 @@ class Backend(ABC):
82
117
  def prepare_args(self, path: str, **kwargs):
83
118
  """
84
119
  prepare parameter args required to be passed to remote AG, i.e. init args and fit args
85
- The args will be saved as a pickle object
120
+ The args will be saved as a JSON file
86
121
 
87
122
  Parameters
88
123
  ----------
89
124
  path: str
90
- Path to save the pickle file
125
+ Path to save the JSON file
91
126
  """
92
127
  assert self.predictor_type is not None
93
128
  config = self._construct_ag_args(**kwargs)
94
- with open(path, "wb") as f:
95
- pickle.dump(config, f)
129
+ payload = dumps_ag_args(config)
130
+ os.makedirs(os.path.dirname(path), exist_ok=True)
131
+ with open(path, "w") as f:
132
+ f.write(payload)
96
133
 
97
134
  def _construct_ag_args(**kwargs):
98
135
  raise NotImplementedError
@@ -172,3 +209,10 @@ class Backend(ABC):
172
209
  def predict_proba(self, test_data: Union[str, pd.DataFrame], **kwargs) -> Union[pd.DataFrame, pd.Series]:
173
210
  """Batch inference probability"""
174
211
  raise NotImplementedError
212
+
213
+ def get_fit_predict_results(self) -> pd.DataFrame:
214
+ """
215
+ Retrieve predictions produced by a completed ``fit_predict`` job.
216
+
217
+ """
218
+ raise NotImplementedError(f"{self.__class__.__name__} does not support `fit_predict`.")
@@ -0,0 +1,47 @@
1
+ import logging
2
+
3
+ from .backend import Backend
4
+ from .constant import RAY_AWS, TABULAR_RAY_AWS
5
+ from .multimodal_sagemaker_backend import MultiModalSagemakerBackend
6
+ from .sagemaker_backend import SagemakerBackend
7
+ from .tabular_sagemaker_backend import TabularSagemakerBackend
8
+ from .timeseries_sagemaker_backend import TimeSeriesSagemakerBackend
9
+
10
+ logger = logging.getLogger(__name__)
11
+
12
+
13
+ class BackendFactory:
14
+ _SAGEMAKER_BACKENDS = {
15
+ SagemakerBackend.name: SagemakerBackend,
16
+ TabularSagemakerBackend.name: TabularSagemakerBackend,
17
+ MultiModalSagemakerBackend.name: MultiModalSagemakerBackend,
18
+ TimeSeriesSagemakerBackend.name: TimeSeriesSagemakerBackend,
19
+ }
20
+ _RAY_BACKEND_NAMES = {RAY_AWS, TABULAR_RAY_AWS}
21
+
22
+ @staticmethod
23
+ def get_backend_cls(backend: str) -> type[Backend]:
24
+ if backend in BackendFactory._SAGEMAKER_BACKENDS:
25
+ return BackendFactory._SAGEMAKER_BACKENDS[backend]
26
+ if backend in BackendFactory._RAY_BACKEND_NAMES:
27
+ logger.warning(
28
+ f"The '{backend}' backend is experimental and not fully supported. Use at your own risk; "
29
+ "for production workloads prefer the 'sagemaker' backend."
30
+ )
31
+ try:
32
+ from .ray_aws_backend import RayAWSBackend, TabularRayAWSBackend
33
+ except ImportError as e:
34
+ raise ImportError(
35
+ f"The '{backend}' backend requires ray. Install with: pip install 'autogluon.cloud[ray]'"
36
+ ) from e
37
+ return {
38
+ RayAWSBackend.name: RayAWSBackend,
39
+ TabularRayAWSBackend.name: TabularRayAWSBackend,
40
+ }[backend]
41
+ supported = sorted(BackendFactory._SAGEMAKER_BACKENDS.keys() | BackendFactory._RAY_BACKEND_NAMES)
42
+ raise ValueError(f"{backend} not supported. Supported backends: {supported}")
43
+
44
+ @staticmethod
45
+ def get_backend(backend: str, **init_args) -> Backend:
46
+ """Return the corresponding backend"""
47
+ return BackendFactory.get_backend_cls(backend)(**init_args)
@@ -5,3 +5,6 @@ TIMESERIES_SAGEMAKER = "timeseries_sagemaker"
5
5
  RAY = "ray"
6
6
  RAY_AWS = "ray_aws"
7
7
  TABULAR_RAY_AWS = "tabular_ray_aws"
8
+
9
+ # Backends the top-level setup API can provision via CloudFormation.
10
+ SUPPORTED_BACKENDS = (SAGEMAKER, RAY_AWS)
@@ -2,7 +2,7 @@ from __future__ import annotations
2
2
 
3
3
  import logging
4
4
  import time
5
- from typing import Dict, Optional
5
+ from typing import Optional
6
6
 
7
7
  import boto3
8
8
 
@@ -55,14 +55,9 @@ class RayAWSBackend(RayBackend):
55
55
  super().initialize(**kwargs)
56
56
  self._boto_session = boto3.session.Session()
57
57
  self.region = self._boto_session.region_name
58
- assert (
59
- self.region is not None
60
- ), "Please setup a region via `export AWS_DEFAULT_REGION=YOUR_REGION` in the terminal"
61
-
62
- @staticmethod
63
- def generate_default_permission(**kwargs) -> Dict[str, str]:
64
- """Generate default permission file user could use to setup the corresponding entity, i.e. IAM Role in AWS"""
65
- return RayAWSClusterManager.generate_default_permission(**kwargs)
58
+ assert self.region is not None, (
59
+ "Please setup a region via `export AWS_DEFAULT_REGION=YOUR_REGION` in the terminal"
60
+ )
66
61
 
67
62
  def _setup_role_and_permission(self):
68
63
  """