Skip to content

Commit 61ab003

Browse files
committed
Normalize Windows paths
1 parent 32af80d commit 61ab003

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

speciesnet/utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,9 @@ def _enforce_location(
344344
for folder in folders:
345345
base_dir = Path(folder)
346346
for ext in IMG_EXTENSIONS:
347-
filepaths.extend(base_dir.glob(f"**/*.{ext}"))
347+
filepaths.extend(
348+
[path.as_posix() for path in base_dir.glob(f"**/*.{ext}")]
349+
)
348350
filepaths = sorted(filepaths)
349351

350352
if filepaths_txt is not None:

0 commit comments

Comments
 (0)