aiauto-client 0.1.25__py3-none-any.whl → 0.1.27__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.
aiauto/core.py CHANGED
@@ -162,34 +162,14 @@ class CallbackTopNArtifact:
162
162
  for old_trial in finished_with_artifacts[self.n_keep:]:
163
163
  artifact_id = old_trial.user_attrs.get(self.check_attr_name)
164
164
  if artifact_id:
165
+ # 파일 삭제
165
166
  try:
166
167
  self.artifact_store.remove(artifact_id)
167
168
  except Exception as e:
168
169
  print(f"Warning: Failed to remove artifact {artifact_id}: {e}")
169
170
 
170
- # artifact_id를 user_attrs에서 완전히 제거
171
- # GrpcStorageProxy는 빈 문자열을 제대로 처리하지 못하므로
172
- # 전체 user_attrs를 다시 설정하는 방식 사용
173
- try:
174
- # 현재 user_attrs 복사
175
- new_attrs = dict(old_trial.user_attrs)
176
- # artifact_id 키 제거
177
- if self.check_attr_name in new_attrs:
178
- del new_attrs[self.check_attr_name]
179
-
180
- # 각 속성을 다시 설정 (artifact_id 제외)
181
- for key, value in new_attrs.items():
182
- study._storage.set_trial_user_attr(old_trial._trial_id, key, value)
183
-
184
- # artifact_id를 명시적으로 None으로 설정 시도
185
- # (일부 storage는 None을 "키 삭제"로 해석할 수 있음)
186
- try:
187
- study._storage.set_trial_user_attr(old_trial._trial_id, self.check_attr_name, None)
188
- except:
189
- pass # None이 지원되지 않으면 무시
190
-
191
- except Exception as e2:
192
- print(f"Warning: Failed to remove user_attr {self.check_attr_name} for trial {old_trial.number}: {e2}")
171
+ # artifact_removed 플래그 추가 (WAL 방식의 storage에서도 안전함)
172
+ study._storage.set_trial_user_attr(old_trial._trial_id, 'artifact_removed', True)
193
173
 
194
174
 
195
175
  class StudyWrapper:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: aiauto-client
3
- Version: 0.1.25
3
+ Version: 0.1.27
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,10 +1,10 @@
1
1
  aiauto/__init__.py,sha256=sF7sJaXg7-MqolSYLxsaXAir1dBzARhXLrHo7zLsupg,345
2
2
  aiauto/_config.py,sha256=hTFh2bH9m-HuX6QCpNtBC0j6rEB0S97hhPKjbEjv4Tg,89
3
3
  aiauto/constants.py,sha256=rBibGOQHHrdkwaai92-3I8-N0cu-B4CoCoQbG9-Cl8k,821
4
- aiauto/core.py,sha256=lVE3H3W7knnFbdwC2mRyL42TyEDyHK02crFaIuhkjgA,12007
4
+ aiauto/core.py,sha256=n5nJsvzsnnBgBtdyecHcYxSian4NbD4IBl-cmdDag-w,10864
5
5
  aiauto/http_client.py,sha256=v_nPdb-2tIeH1XrOYqzMGvFfXLKEDbQoSaQYPsB0Hik,2587
6
6
  aiauto/serializer.py,sha256=BJmeq6uCD9D2_6bXu_sMBQLSsXCUMIMM10iX923DTXE,2749
7
- aiauto_client-0.1.25.dist-info/METADATA,sha256=w0nyFqlPNrFXW7EIKZnEYPi6IWmEHdUcyq-S4c8kI90,25746
8
- aiauto_client-0.1.25.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
9
- aiauto_client-0.1.25.dist-info/top_level.txt,sha256=Sk2ctO9_Bf_tAPwq1x6Vfl6OuL29XzwMTO4F_KG6oJE,7
10
- aiauto_client-0.1.25.dist-info/RECORD,,
7
+ aiauto_client-0.1.27.dist-info/METADATA,sha256=tcd9TScT1WiEovn73ZKL8Vx0fqpzGrapbJeUnavbaNQ,25746
8
+ aiauto_client-0.1.27.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
9
+ aiauto_client-0.1.27.dist-info/top_level.txt,sha256=Sk2ctO9_Bf_tAPwq1x6Vfl6OuL29XzwMTO4F_KG6oJE,7
10
+ aiauto_client-0.1.27.dist-info/RECORD,,