code: def download_onnx(
      sub_dir,
      model_file,
      force=False,
      root="~/.insightface",
      download_zip=False,
  ):
      _root = os.path.expanduser(root)
      model_root = osp.join(_root, sub_dir)
      new_model_file = osp.join(model_root, model_file)
      if osp.exists(new_model_file) and not force:
          return new_model_file
      if not osp.exists(model_root):
          os.makedirs(model_root)
      print("download_path:", new_model_file)
      if not download_zip:
          model_url = "%s/%s" % (BASE_REPO_URL, model_file)
          download_file(model_url, path=new_model_file, overwrite=True)
      else:
          model_url = "%s/%s.zip" % (BASE_REPO_URL, model_file)
          zip_file_path = new_model_file + ".zip"
          download_file(model_url, path=zip_file_path, overwrite=True)
          with zipfile.ZipFile(zip_file_path) as zf:
              zf.extractall(model_root)
          return new_model_file
  
imports: import os
  import os.path
  import zipfile
  from .download import download_file
label_desc: Use image node_id 3 for calling a global function with example usage: download_onnx(sub_dir, model_file, force, root, download_zip) and returns: new_model_file, new_model_file