Pārlūkot izejas kodu

Explicitly convert artifact path to posix_path (#3067)

* Explicitly convert artifact path to posix_path

* Remove redudant str() casting
modifyDataloader
Ayush Chaurasia GitHub pirms 3 gadiem
vecāks
revīzija
d2a17289c9
Šim parakstam datu bāzē netika atrasta zināma atslēga GPG atslēgas ID: 4AEE18F83AFDEB23
1 mainītis faili ar 2 papildinājumiem un 1 dzēšanām
  1. +2
    -1
      utils/wandb_logging/wandb_utils.py

+ 2
- 1
utils/wandb_logging/wandb_utils.py Parādīt failu

@@ -158,7 +158,8 @@ class WandbLogger():

def download_dataset_artifact(self, path, alias):
if isinstance(path, str) and path.startswith(WANDB_ARTIFACT_PREFIX):
dataset_artifact = wandb.use_artifact(remove_prefix(path, WANDB_ARTIFACT_PREFIX) + ":" + alias)
artifact_path = Path(remove_prefix(path, WANDB_ARTIFACT_PREFIX) + ":" + alias)
dataset_artifact = wandb.use_artifact(artifact_path.as_posix())
assert dataset_artifact is not None, "'Error: W&B dataset artifact doesn\'t exist'"
datadir = dataset_artifact.download()
return datadir, dataset_artifact

Notiek ielāde…
Atcelt
Saglabāt