C-Achard commited on
Commit
2bb2cc3
Β·
verified Β·
1 Parent(s): e09c536

Skip torch.hub GitHub API validation (fixes #10)

Browse files
Files changed (1) hide show
  1. detection_utils.py +1 -1
detection_utils.py CHANGED
@@ -34,7 +34,7 @@ def predict_md(im,
34
  MD_model = torch.hub.load('ultralytics/yolov5', # repo_or_dir
35
  'custom', #model
36
  megadetector_model, # args for callable model
37
- force_reload=True,
38
  device=md_device,
39
  trust_repo=True
40
  )
 
34
  MD_model = torch.hub.load('ultralytics/yolov5', # repo_or_dir
35
  'custom', #model
36
  megadetector_model, # args for callable model
37
+ skip_validation=True, # avoid GitHub API rate limit (403)
38
  device=md_device,
39
  trust_repo=True
40
  )