autogluon.common 1.2.1b20250116__py3-none-any.whl → 1.2.1b20250130__py3-none-any.whl

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.
@@ -213,7 +213,7 @@ def download_s3_folder(
213
213
  if os.path.isdir(local_path) and not dry_run:
214
214
  if error_if_exists:
215
215
  raise ValueError(
216
- f"Directory {local_path} already exists. Please pass in a different `local_path` or set `error_if_exsits` to `False`"
216
+ f"Directory {local_path} already exists. Please pass in a different `local_path` or set `error_if_exists` to `False`"
217
217
  )
218
218
  if delete_if_exists:
219
219
  logger.warning(
@@ -2,7 +2,7 @@ import logging
2
2
  import os
3
3
  import platform
4
4
  import sys
5
- from datetime import datetime
5
+ from datetime import datetime, timezone
6
6
  from hashlib import md5
7
7
  from pathlib import Path
8
8
  from typing import Any, Dict, Optional
@@ -23,18 +23,23 @@ LITE_MODE: bool = __lite__ is not None and __lite__
23
23
 
24
24
 
25
25
  def setup_outputdir(path, warn_if_exist=True, create_dir=True, path_suffix=None):
26
+ is_s3_path = False
26
27
  if path:
27
28
  assert isinstance(path, (str, Path)), (
28
29
  f"Only str and pathlib.Path types are supported for path, got {path} of type {type(path)}."
29
30
  )
31
+
32
+ is_s3_path = str(path).lower().startswith("s3://")
33
+
30
34
  if path_suffix is None:
31
35
  path_suffix = ""
32
- if path_suffix and path_suffix[-1] == os.path.sep:
36
+ if path_suffix and path_suffix[-1] == os.path.sep if not is_s3_path else "/":
33
37
  path_suffix = path_suffix[:-1]
38
+
34
39
  if path is not None:
35
40
  path = f"{path}{path_suffix}"
36
- if path is None:
37
- utcnow = datetime.utcnow()
41
+ else:
42
+ utcnow = datetime.now(timezone.utc)
38
43
  timestamp = utcnow.strftime("%Y%m%d_%H%M%S")
39
44
  path = os.path.join("AutogluonModels", f"ag-{timestamp}{path_suffix}")
40
45
  for i in range(1, 1000):
@@ -51,7 +56,8 @@ def setup_outputdir(path, warn_if_exist=True, create_dir=True, path_suffix=None)
51
56
  else:
52
57
  raise RuntimeError("more than 1000 jobs launched in the same second")
53
58
  logger.log(25, f'No path specified. Models will be saved in: "{path}"')
54
- elif warn_if_exist:
59
+
60
+ if warn_if_exist and not is_s3_path:
55
61
  try:
56
62
  if create_dir:
57
63
  os.makedirs(path, exist_ok=False)
@@ -61,8 +67,9 @@ def setup_outputdir(path, warn_if_exist=True, create_dir=True, path_suffix=None)
61
67
  logger.warning(
62
68
  f'Warning: path already exists! This predictor may overwrite an existing predictor! path="{path}"'
63
69
  )
64
- path = os.path.expanduser(path) # replace ~ with absolute path if it exists
65
- path = os.path.abspath(path)
70
+ if not is_s3_path:
71
+ path = os.path.expanduser(path) # replace ~ with absolute path if it exists
72
+ path = os.path.abspath(path)
66
73
  return path
67
74
 
68
75
 
@@ -1,4 +1,4 @@
1
1
  """This is the autogluon version file."""
2
2
 
3
- __version__ = "1.2.1b20250116"
3
+ __version__ = "1.2.1b20250130"
4
4
  __lite__ = False
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: autogluon.common
3
- Version: 1.2.1b20250116
3
+ Version: 1.2.1b20250130
4
4
  Summary: Fast and Accurate ML in 3 Lines of Code
5
5
  Home-page: https://github.com/autogluon/autogluon
6
6
  Author: AutoGluon Community
@@ -34,6 +34,8 @@ Classifier: Topic :: Scientific/Engineering :: Information Analysis
34
34
  Classifier: Topic :: Scientific/Engineering :: Image Recognition
35
35
  Requires-Python: >=3.9, <3.13
36
36
  Description-Content-Type: text/markdown
37
+ License-File: ../LICENSE
38
+ License-File: ../NOTICE
37
39
  Requires-Dist: numpy<2.1.4,>=1.25.0
38
40
  Requires-Dist: pandas<2.3.0,>=2.0.0
39
41
  Requires-Dist: boto3<2,>=1.10
@@ -42,8 +44,8 @@ Requires-Dist: tqdm<5,>=4.38
42
44
  Provides-Extra: tests
43
45
  Requires-Dist: pytest; extra == "tests"
44
46
  Requires-Dist: pytest-mypy; extra == "tests"
45
- Requires-Dist: types-requests; extra == "tests"
46
47
  Requires-Dist: types-setuptools; extra == "tests"
48
+ Requires-Dist: types-requests; extra == "tests"
47
49
 
48
50
 
49
51
 
@@ -1,8 +1,8 @@
1
- autogluon.common-1.2.1b20250116-py3.8-nspkg.pth,sha256=cQGwpuGPqg1GXscIwt-7PmME1OnSpD-7ixkikJ31WAY,554
1
+ autogluon.common-1.2.1b20250130-py3.9-nspkg.pth,sha256=cQGwpuGPqg1GXscIwt-7PmME1OnSpD-7ixkikJ31WAY,554
2
2
  autogluon/common/__init__.py,sha256=Q0tQ4UOtUEhPpj83k_xzQ9bmtoTSvfg_3WgPi1QopJk,352
3
3
  autogluon/common/dataset.py,sha256=slfU8CxGFNJ86_2wKkT_zPMPr-iPB-sz7klz0YqJECo,1580
4
4
  autogluon/common/space.py,sha256=oRSG-uFmsLACT42mT2vRp3NSuV8MaQz6X4sYwcZruxs,5457
5
- autogluon/common/version.py,sha256=qtf1yrCzRdeJXfqZGb9YWrrjOFhl2omGSnhF5i131QY,91
5
+ autogluon/common/version.py,sha256=onZWyUgu5fGg96se5Au1iUkaP0LXAhrwgAuo6bELN9c,91
6
6
  autogluon/common/features/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
7
  autogluon/common/features/feature_metadata.py,sha256=GDvZXyaNkDeuNv8omO4K7tkCPmMdpJzD5rH_hKtZD9E,25783
8
8
  autogluon/common/features/infer_types.py,sha256=MkfVDoY__0Rr__zsDSKszmvYMq5RQRmbNboTG_tm64o,6492
@@ -38,16 +38,16 @@ autogluon/common/utils/nvutil.py,sha256=tVyCdUDoM7RSkO1Ek01NVRFL8bbFnQBryezYpN-B
38
38
  autogluon/common/utils/pandas_utils.py,sha256=sirUUQkKZsmMwmXWEUZJ1n3ZYFQWqwz4iu-tAhZdv68,2432
39
39
  autogluon/common/utils/path_converter.py,sha256=OO0Jr5vhcqrEvZrNqem5tmgC6FZA3_O8sPylQUKUgKs,2441
40
40
  autogluon/common/utils/resource_utils.py,sha256=ZP6KGh8HliacadptvftL8x4dm_cw0Hwm27BNpN_dTnI,8352
41
- autogluon/common/utils/s3_utils.py,sha256=EuGwxw8aTodhMNp3Ie63_0f7gWm8TcZTGrKf1272OP0,17142
41
+ autogluon/common/utils/s3_utils.py,sha256=Tj2VyUGUc7Vrx5KkCGKapvFQyaVvWpJNpjssfXg2Sl4,17142
42
42
  autogluon/common/utils/simulation_utils.py,sha256=iEZcRWzP8xLQ8racIfOGC5V_A0W_xNgxPkGuBfX6hh8,3573
43
43
  autogluon/common/utils/system_info.py,sha256=9BkFcdq1co0EMnZkk_AYdhxSEP3RqcU6uIp-iYx9bdc,4479
44
44
  autogluon/common/utils/try_import.py,sha256=FVHRwyeUCyJyUEm3GevcTjOeatpIt38AxGSJLaDSvZo,7499
45
- autogluon/common/utils/utils.py,sha256=aTsYfoREV-tDXyZZHJooXD-JL22vjEl_G-nBuDbwVqM,7412
46
- autogluon.common-1.2.1b20250116.dist-info/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142
47
- autogluon.common-1.2.1b20250116.dist-info/METADATA,sha256=Pp3PK4h51qu4ws6tiCEfXjSxlTiVb1MFeCe89M8uv3Q,11587
48
- autogluon.common-1.2.1b20250116.dist-info/NOTICE,sha256=7nPQuj8Kp-uXsU0S5so3-2dNU5EctS5hDXvvzzehd7E,114
49
- autogluon.common-1.2.1b20250116.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
50
- autogluon.common-1.2.1b20250116.dist-info/namespace_packages.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
51
- autogluon.common-1.2.1b20250116.dist-info/top_level.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
52
- autogluon.common-1.2.1b20250116.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
53
- autogluon.common-1.2.1b20250116.dist-info/RECORD,,
45
+ autogluon/common/utils/utils.py,sha256=dxb-OAXBLLw6mPtj0mr4WZbLEJlin8wChZ4hH5LhQ8U,7581
46
+ autogluon.common-1.2.1b20250130.dist-info/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142
47
+ autogluon.common-1.2.1b20250130.dist-info/METADATA,sha256=_mG8Cb26x72skFXDkOOnJNeVewNmR8i1Y8g5niQbguo,11636
48
+ autogluon.common-1.2.1b20250130.dist-info/NOTICE,sha256=7nPQuj8Kp-uXsU0S5so3-2dNU5EctS5hDXvvzzehd7E,114
49
+ autogluon.common-1.2.1b20250130.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
50
+ autogluon.common-1.2.1b20250130.dist-info/namespace_packages.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
51
+ autogluon.common-1.2.1b20250130.dist-info/top_level.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
52
+ autogluon.common-1.2.1b20250130.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
53
+ autogluon.common-1.2.1b20250130.dist-info/RECORD,,