Browse Source

Update google_utils.py (#2017)

5.0
Glenn Jocher GitHub 3 years ago
parent
commit
77fd83225f
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      utils/google_utils.py

+ 2
- 2
utils/google_utils.py View File

@@ -26,8 +26,8 @@ def attempt_download(file, repo='ultralytics/yolov5'):
assets = [x['name'] for x in response['assets']] # release assets, i.e. ['yolov5s.pt', 'yolov5m.pt', ...]
tag = response['tag_name'] # i.e. 'v1.0'
except: # fallback plan
assets = ['yolov5.pt', 'yolov5.pt', 'yolov5l.pt', 'yolov5x.pt']
tag = subprocess.check_output('git tag', shell=True).decode('utf-8').split('\n')[-2]
assets = ['yolov5s.pt', 'yolov5m.pt', 'yolov5l.pt', 'yolov5x.pt']
tag = subprocess.check_output('git tag', shell=True).decode().split()[-1]

name = file.name
if name in assets:

Loading…
Cancel
Save