From f14e954247604818ef73ad4f2f9c4216b86f3165 Mon Sep 17 00:00:00 2001 From: YunLiu <55491388+KumoLiu@users.noreply.github.com> Date: Tue, 10 Sep 2024 16:32:42 +0800 Subject: [PATCH] fix #8075 Signed-off-by: YunLiu <55491388+KumoLiu@users.noreply.github.com> --- monai/bundle/scripts.py | 1 + 1 file changed, 1 insertion(+) diff --git a/monai/bundle/scripts.py b/monai/bundle/scripts.py index f1d1286e4b..f31ad0e814 100644 --- a/monai/bundle/scripts.py +++ b/monai/bundle/scripts.py @@ -255,6 +255,7 @@ def _download_from_ngc_private( else: raise ValueError("NGC API requires requests package. Please install it.") + os.makedirs(download_path, exist_ok=True) zip_path = download_path / f"{filename}_v{version}.zip" with open(zip_path, "wb") as f: f.write(response.content)