From aede71080ee82bc50ed7dd65f8399186d0c5281b Mon Sep 17 00:00:00 2001 From: Wang Xin Date: Wed, 5 Mar 2025 02:25:49 +0000 Subject: [PATCH] expand user path --- ppdet/utils/download.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ppdet/utils/download.py b/ppdet/utils/download.py index a7909b83394..31c0622604e 100644 --- a/ppdet/utils/download.py +++ b/ppdet/utils/download.py @@ -255,7 +255,7 @@ def map_path(url, root_dir, path_depth=1): zip_formats = ['.zip', '.tar', '.gz'] for zip_format in zip_formats: fpath = fpath.replace(zip_format, '') - return osp.join(root_dir, fpath) + return osp.join(osp.expanduser(root_dir), fpath) def get_path(url, root_dir, md5sum=None, check_exist=True):