aiauto-client 0.1.20__tar.gz → 0.1.22__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.
- {aiauto_client-0.1.20/src/aiauto_client.egg-info → aiauto_client-0.1.22}/PKG-INFO +1 -1
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/pyproject.toml +1 -1
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto/core.py +22 -6
- {aiauto_client-0.1.20 → aiauto_client-0.1.22/src/aiauto_client.egg-info}/PKG-INFO +1 -1
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/MANIFEST.in +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/README.md +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/examples/example_simple.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/examples/example_torch_multiple_objective.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/examples/example_torch_single_objective.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/setup.cfg +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto/__init__.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto/_config.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto/constants.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto/http_client.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto/serializer.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto_client.egg-info/SOURCES.txt +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto_client.egg-info/dependency_links.txt +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto_client.egg-info/requires.txt +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto_client.egg-info/top_level.txt +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/tests/test_pruners.py +0 -0
- {aiauto_client-0.1.20 → aiauto_client-0.1.22}/tests/test_samplers.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: aiauto-client
|
3
|
-
Version: 0.1.
|
3
|
+
Version: 0.1.22
|
4
4
|
Summary: AI Auto HPO (Hyperparameter Optimization) Client Library
|
5
5
|
Author-email: AIAuto Team <ainode@zeroone.ai>
|
6
6
|
Project-URL: Homepage, https://dashboard.common.aiauto.pangyo.ainode.ai
|
@@ -1,4 +1,5 @@
|
|
1
1
|
from os import makedirs
|
2
|
+
import os
|
2
3
|
import tempfile
|
3
4
|
from typing import Union, Optional, List, Dict, Callable
|
4
5
|
import optuna
|
@@ -44,9 +45,8 @@ class AIAutoController:
|
|
44
45
|
"Please delete and reissue your token from the web dashboard at https://dashboard.common.aiauto.pangyo.ainode.ai"
|
45
46
|
) from e
|
46
47
|
|
47
|
-
# artifact storage
|
48
|
-
|
49
|
-
self.artifact_store = optuna.artifacts.FileSystemArtifactStore('./artifacts')
|
48
|
+
# artifact storage: lazily resolved at call time based on runtime environment
|
49
|
+
self._artifact_store = None
|
50
50
|
self.tmp_dir = tempfile.mkdtemp(prefix=f'ai_auto_tmp_')
|
51
51
|
|
52
52
|
def get_storage(self):
|
@@ -57,7 +57,18 @@ class AIAutoController:
|
|
57
57
|
optuna.artifacts.Boto3ArtifactStore,
|
58
58
|
optuna.artifacts.GCSArtifactStore,
|
59
59
|
]:
|
60
|
-
|
60
|
+
# Lazy init: prefer container-mounted PVC at /artifacts (runner env),
|
61
|
+
# fallback to local ./artifacts for client/local usage.
|
62
|
+
if self._artifact_store is None:
|
63
|
+
if os.path.isdir('/artifacts'):
|
64
|
+
path = '/artifacts'
|
65
|
+
else:
|
66
|
+
path = './artifacts'
|
67
|
+
if not os.path.isdir(path):
|
68
|
+
makedirs(path, exist_ok=True)
|
69
|
+
self._artifact_store = optuna.artifacts.FileSystemArtifactStore(path)
|
70
|
+
|
71
|
+
return self._artifact_store
|
61
72
|
|
62
73
|
def get_artifact_tmp_dir(self):
|
63
74
|
return self.tmp_dir
|
@@ -153,10 +164,15 @@ class CallbackTopNArtifact:
|
|
153
164
|
if artifact_id:
|
154
165
|
try:
|
155
166
|
self.artifact_store.remove(artifact_id)
|
156
|
-
# user_attr에서도 제거
|
157
|
-
study._storage.set_trial_user_attr(old_trial._trial_id, self.check_attr_name, None)
|
158
167
|
except Exception as e:
|
159
168
|
print(f"Warning: Failed to remove artifact {artifact_id}: {e}")
|
169
|
+
finally:
|
170
|
+
try:
|
171
|
+
# 일부 스토리지(GrpcStorageProxy)는 None 값을 무시하거나 직렬화하지 않을 수 있음.
|
172
|
+
# UI에서 링크를 숨기기 위해 빈 문자열로 설정(빈 문자열은 falsy로 처리됨).
|
173
|
+
study._storage.set_trial_user_attr(old_trial._trial_id, self.check_attr_name, "")
|
174
|
+
except Exception as e2:
|
175
|
+
print(f"Warning: Failed to clear user_attr {self.check_attr_name} for trial {old_trial.number}: {e2}")
|
160
176
|
|
161
177
|
|
162
178
|
class StudyWrapper:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: aiauto-client
|
3
|
-
Version: 0.1.
|
3
|
+
Version: 0.1.22
|
4
4
|
Summary: AI Auto HPO (Hyperparameter Optimization) Client Library
|
5
5
|
Author-email: AIAuto Team <ainode@zeroone.ai>
|
6
6
|
Project-URL: Homepage, https://dashboard.common.aiauto.pangyo.ainode.ai
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{aiauto_client-0.1.20 → aiauto_client-0.1.22}/src/aiauto_client.egg-info/dependency_links.txt
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|