Skip to content

Commit 0813099

Browse files
Addressing review comments
1 parent d8bab8a commit 0813099

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

ads/model/datascience_model.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1802,8 +1802,6 @@ def _update_from_oci_dsc_model(
18021802
self.set_spec(self.CONST_ARTIFACT, file_name_info["filename"])
18031803
except:
18041804
pass
1805-
print("self: ", self)
1806-
print("self dsc_model: ", self.dsc_model)
18071805
return self.dsc_model
18081806

18091807
def to_dict(self) -> Dict:

ads/model/model_metadata.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -345,12 +345,9 @@ def _from_oci_metadata(cls, oci_metadata_item) -> "ModelMetadataItem":
345345
if isinstance(key_value_map["value"], str):
346346
try:
347347
key_value_map["value"] = json.loads(oci_metadata_item.get("value"))
348-
try:
349-
key_value_map["has_artifact"] = json.loads(
350-
oci_metadata_item.get("has_artifact")
351-
)
352-
except Exception:
353-
key_value_map["has_artifact"] = False
348+
key_value_map["has_artifact"] = bool(
349+
oci_metadata_item.get("has_artifact")
350+
)
354351
except Exception:
355352
pass
356353
return cls(**key_value_map)

0 commit comments

Comments
 (0)