ultralytics 8.2.52 fix CenterCrop transforms for PIL Image inputs (#14308)
Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com> Co-authored-by: UltralyticsAssistant <web@ultralytics.com> Co-authored-by: Lucas Buligon Antunes <lukasbuligonantunes@gmail.com>
This commit is contained in:
parent
755dcd6ca0
commit
997f2c92cd
20 changed files with 38 additions and 30 deletions
|
|
@ -195,7 +195,7 @@ class RF100Benchmark:
|
|||
(shutil.rmtree("rf-100"), os.mkdir("rf-100")) if os.path.exists("rf-100") else os.mkdir("rf-100")
|
||||
os.chdir("rf-100")
|
||||
os.mkdir("ultralytics-benchmarks")
|
||||
safe_download("https://ultralytics.com/assets/datasets_links.txt")
|
||||
safe_download("https://github.com/ultralytics/yolov5/releases/download/v1.0/datasets_links.txt")
|
||||
|
||||
with open(ds_link_txt, "r") as file:
|
||||
for line in file:
|
||||
|
|
|
|||
|
|
@ -315,7 +315,7 @@ def check_font(font="Arial.ttf"):
|
|||
return matches[0]
|
||||
|
||||
# Download to USER_CONFIG_DIR if missing
|
||||
url = f"https://ultralytics.com/assets/{name}"
|
||||
url = f"https://github.com/ultralytics/yolov5/releases/download/v1.0/{name}"
|
||||
if downloads.is_url(url, check=True):
|
||||
downloads.safe_download(url=url, file=file)
|
||||
return file
|
||||
|
|
|
|||
|
|
@ -194,12 +194,14 @@ def unzip_file(file, path=None, exclude=(".DS_Store", "__MACOSX"), exist_ok=Fals
|
|||
return path # return unzip dir
|
||||
|
||||
|
||||
def check_disk_space(url="https://ultralytics.com/assets/coco128.zip", path=Path.cwd(), sf=1.5, hard=True):
|
||||
def check_disk_space(
|
||||
url="https://github.com/ultralytics/yolov5/releases/download/v1.0/coco8.zip", path=Path.cwd(), sf=1.5, hard=True
|
||||
):
|
||||
"""
|
||||
Check if there is sufficient disk space to download and store a file.
|
||||
|
||||
Args:
|
||||
url (str, optional): The URL to the file. Defaults to 'https://ultralytics.com/assets/coco128.zip'.
|
||||
url (str, optional): The URL to the file. Defaults to 'https://ultralytics.com/assets/coco8.zip'.
|
||||
path (str | Path, optional): The path or drive to check the available free space on.
|
||||
sf (float, optional): Safety factor, the multiplier for the required free space. Defaults to 2.0.
|
||||
hard (bool, optional): Whether to throw an error or not on insufficient disk space. Defaults to True.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue