5535b861bc9ca33dc06f92a143694040d837f3de,wandb/sdk_py27/wandb_artifacts.py,WBArtifactHandler,load_path,#WBArtifactHandler#Any#Any#Any#,1188
Before Change
artifact_id, artifact_file_path = WBArtifactHandler.parse_path(
manifest_entry.ref
)
artifact = PublicApi().artifact_from_id(util.hex_to_b64_id(artifact_id))
artifact_path = artifact.download()
link_target_path = os.path.join(artifact_path, artifact_file_path)
link_creation_path = os.path.join(
self._cache._cache_dir, "tmp", link_target_path
)
filesystem._safe_makedirs(os.path.dirname(link_creation_path))
After Change
// Parse the reference path and download the artifact if needed
artifact_id = util.host_from_path(manifest_entry.ref)
artifact_file_path = util.uri_from_path(manifest_entry.ref)
dep_artifact = PublicArtifact.from_id(
util.hex_to_b64_id(artifact_id), self.client
)
link_target_path = dep_artifact.get_path(artifact_file_path).download()
return link_target_path
def store_path(self, artifact, path, name=None, checksum=True, max_objects=None):
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 12
Instances
Project Name: wandb/client
Commit Name: 5535b861bc9ca33dc06f92a143694040d837f3de
Time: 2020-11-16
Author: tim.s.sweeney@gmail.com
File Name: wandb/sdk_py27/wandb_artifacts.py
Class Name: WBArtifactHandler
Method Name: load_path
Project Name: wandb/client
Commit Name: 5535b861bc9ca33dc06f92a143694040d837f3de
Time: 2020-11-16
Author: tim.s.sweeney@gmail.com
File Name: wandb/sdk/wandb_artifacts.py
Class Name: WBArtifactHandler
Method Name: load_path
Project Name: wandb/client
Commit Name: 5535b861bc9ca33dc06f92a143694040d837f3de
Time: 2020-11-16
Author: tim.s.sweeney@gmail.com
File Name: wandb/sdk/wandb_artifacts.py
Class Name: WBArtifactHandler
Method Name: store_path
Project Name: wandb/client
Commit Name: 5535b861bc9ca33dc06f92a143694040d837f3de
Time: 2020-11-16
Author: tim.s.sweeney@gmail.com
File Name: wandb/sdk_py27/wandb_artifacts.py
Class Name: WBArtifactHandler
Method Name: store_path