LoggedArtifactAsset
LoggedArtifactAsset¶
LoggedArtifactAsset(remote, logical_path, size, link, metadata, asset_type, id, artifact_version_id, artifact_id, source_experiment_key): represent assets logged to an Artifact
LoggedArtifactAsset.artifact_id¶
Artifact id, str
LoggedArtifactAsset.artifact_version_id¶
Artifact version id, str
LoggedArtifactAsset.asset_type¶
Asset type, str
LoggedArtifactAsset.id¶
Asset unique id, str
LoggedArtifactAsset.link¶
Asset remote link if the asset is remote, str or None
LoggedArtifactAsset.logical_path¶
Asset relative logical_path, str or None
LoggedArtifactAsset.metadata¶
Asset metadata, dict
LoggedArtifactAsset.remote¶
Is the asset a remote asset or not, boolean
LoggedArtifactAsset.size¶
Asset size if the asset is a non-remote asset, int
LoggedArtifactAsset.source_experiment_key¶
The experiment key of the experiment that logged this asset, str
LoggedArtifactAsset.__init__
¶
python
__init__(self, remote, logical_path, size, link, metadata, asset_type, id,
artifact_version_id, artifact_id, source_experiment_key, verify_tls,
rest_api_client=None, download_timeout=None,
logged_artifact_repr=None, logged_artifact_str=None,
experiment_key=None)
Initialize self. See help(type(self)) for accurate signature.
LoggedArtifactAsset.download¶
python
download(self, local_path=None, logical_path=None, overwrite_strategy=False)
Download the asset to a given full path or directory
Returns: ArtifactAsset object
Args:
-
local_path: the root folder to which to download. if None, will download to a tmp path if str, will be either a root local path or a full local path
-
logical_path: the path relative to the root local_path to use if None and local_path==None then no relative path is used, file would just be a tmp path on local disk if None and local_path!=None then the local_path will be treated as a root path, and the asset's logical_path will be appended to the root path to form a full local path if "" or False then local_path will be used as a full path (local_path can also be None)
-
overwrite_strategy: can be False, "FAIL", "PRESERVE" or "OVERWRITE" and follows the same semantics for overwrite strategy as artifact.download()