class_docstr: Handles loading and storing Artifact reference-type files.
class_docstr_tok: ["Handles","loading","and","storing","Artifact","reference-type","files","."]
docstr: Load the file in the specified artifact given its corresponding entry.
  
  Download the referenced artifact; create and return a new symlink to the caller.
  
  Arguments:
      manifest_entry (ArtifactManifestEntry): The index entry to load
  
  Returns:
      (os.PathLike): A path to the file represented by `index_entry`
docstr_tok: ["Load","the","file","in","the","specified","artifact","given","its","corresponding","entry",".","Download","the","referenced","artifact",";","create","and","return","a","new","symlink","to","the","caller",".","Arguments",":","manifest_entry","(","ArtifactManifestEntry",")",":","The","index","entry","to","load","Returns",":","(","os.PathLike",")",":","A","path","to","the","file","represented","by","`","index_entry","`"]
code: def load_path(
      self,
      manifest_entry: ArtifactManifestEntry,
      local: bool = False,
  ) -> Union[URIStr, FilePathStr]:
      """Load the file in the specified artifact given its corresponding entry.
  
      Download the referenced artifact; create and return a new symlink to the caller.
  
      Arguments:
          manifest_entry (ArtifactManifestEntry): The index entry to load
  
      Returns:
          (os.PathLike): A path to the file represented by `index_entry`
      """
      # We don't check for cache hits here. Since we have 0 for size (since this
      # is a cross-artifact reference which and we've made the choice to store 0
      # in the size field), we can't confirm if the file is complete. So we just
      # rely on the dep_artifact entry's download() method to do its own cache
      # check.
  
      # 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 = wandb.Artifact._from_id(
          hex_to_b64_id(artifact_id), self.client.client
      )
      assert dep_artifact is not None
      link_target_path: Union[URIStr, FilePathStr]
      if local:
          link_target_path = dep_artifact.get_entry(
              artifact_file_path
          ).download()
      else:
          link_target_path = dep_artifact.get_entry(
              artifact_file_path
          ).ref_target()
  
      return link_target_path
  
file_path: wandb/wandb/sdk/artifacts/storage_handlers/wb_artifact_handler.py
imports: import os
  from typing import TYPE_CHECKING, Optional, Sequence, Union
  from urllib.parse import urlparse
  import wandb
  from wandb import util
  from wandb.apis import PublicApi
  from wandb.sdk.artifacts.artifact_file_cache import get_artifact_file_cache
  from wandb.sdk.artifacts.artifact_manifest_entry import ArtifactManifestEntry
  from wandb.sdk.artifacts.storage_handler import StorageHandler
  from wandb.sdk.lib.hashutil import B64MD5, b64_to_hex_id, hex_to_b64_id
  from wandb.sdk.lib.paths import FilePathStr, StrPath, URIStr
label_desc: Use image node_id 4 for calling the WBArtifactHandler obj's underlying member method code with example usage: obj.load_path(manifest_entry, local) and returns: link_target_path