Fix NCNN export on Windows (#11719)
Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
parent
b617e131bd
commit
537c50e45f
3 changed files with 10 additions and 9 deletions
|
|
@ -528,7 +528,7 @@ def check_is_path_safe(basedir, path):
|
|||
base_dir_resolved = Path(basedir).resolve()
|
||||
path_resolved = Path(path).resolve()
|
||||
|
||||
return path_resolved.is_file() and path_resolved.parts[: len(base_dir_resolved.parts)] == base_dir_resolved.parts
|
||||
return path_resolved.exists() and path_resolved.parts[: len(base_dir_resolved.parts)] == base_dir_resolved.parts
|
||||
|
||||
|
||||
def check_imshow(warn=False):
|
||||
|
|
|
|||
|
|
@ -418,7 +418,7 @@ def attempt_download_asset(file, repo="ultralytics/assets", release="v8.2.0", **
|
|||
|
||||
Example:
|
||||
```python
|
||||
file_path = attempt_download_asset('yolov5s.pt', repo='ultralytics/assets', release='latest')
|
||||
file_path = attempt_download_asset('yolov8n.pt', repo='ultralytics/assets', release='latest')
|
||||
```
|
||||
"""
|
||||
from ultralytics.utils import SETTINGS # scoped for circular import
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue