Vincentqyw / image-matching-webui

🤗 image matching toolbox webui
https://huggingface.co/spaces/Realcat/image-matching-webui
Apache License 2.0
796 stars 68 forks source link

GIM download link is dead #58

Closed eyildiz-ugoe closed 3 months ago

eyildiz-ugoe commented 3 months ago

🐛 Bug Report

[2024/08/20 13:21:03 hloc INFO] Testing GIM(dkm) ...
Access denied with the following error:

    Cannot retrieve the public link of the file. You may need to change
    the permission to 'Anyone with the link', or have had many accesses. 

You may still be able to access the file from the browser:

     https://drive.google.com/uc?id=1gk97V4IROnR1Nprq10W9NCFUv2mxXR_- 

[2024/08/20 13:21:03 hloc INFO] Downloaded GIM model succeeed!
Traceback (most recent call last):
  File "/home/username/image-matching-webui/test_app_cli.py", line 124, in <module>
    test_all(config)
  File "/home/username/image-matching-webui/test_app_cli.py", line 29, in test_all
    api = ImageMatchingAPI(conf=v, device=DEVICE)
  File "/home/username/image-matching-webui/ui/api.py", line 63, in __init__
    self._init_models()
  File "/home/username/image-matching-webui/ui/api.py", line 121, in _init_models
    self.matcher = get_model(self.match_conf)
  File "/home/username/image-matching-webui/ui/utils.py", line 175, in get_model
    model = Model(match_conf["model"]).eval().to(DEVICE)
  File "/home/username/image-matching-webui/hloc/utils/base_model.py", line 17, in __init__
    self._init(conf)
  File "/home/username/image-matching-webui/hloc/matchers/gim.py", line 53, in _init
    state_dict = torch.load(str(model_path), map_location="cpu")
  File "/home/username/anaconda3/envs/imw/lib/python3.10/site-packages/torch/serialization.py", line 998, in load
    with _open_file_like(f, 'rb') as opened_file:
  File "/home/username/anaconda3/envs/imw/lib/python3.10/site-packages/torch/serialization.py", line 445, in _open_file_like
    return _open_file(name_or_buffer, mode)
  File "/home/username/anaconda3/envs/imw/lib/python3.10/site-packages/torch/serialization.py", line 426, in __init__
    super().__init__(open(name, mode))
FileNotFoundError: [Errno 2] No such file or directory: '/home/username/image-matching-webui/hloc/matchers/../../third_party/gim/weights/gim_dkm_100h.ckpt'

That link is dead, you gotta download the weights from here: https://drive.google.com/file/d/1gk97V4IROnR1Nprq10W9NCFUv2mxXR_-/view

eyildiz-ugoe commented 3 months ago

COTR weights are also missing, get them here: https://www.cs.ubc.ca/research/kmyi_data/files/2021/cotr/default.zip

Vincentqyw commented 3 months ago

Fixed. https://github.com/Vincentqyw/image-matching-webui/pull/60