Skip to content

Commit

Permalink
update readme to refer to new pretrained models
Browse files Browse the repository at this point in the history
  • Loading branch information
lugiavn committed Apr 5, 2021
1 parent c27ca39 commit c58daa0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,8 @@ Our pretrained models can be downloaded below. You can find our best single mode
- [MITStates Model](https://storage.googleapis.com/image_retrieval_css/pretrained_models/checkpoint_mitstates.pth): 0.132


These saved weights might not be working correctly any more with new version, please refer to https://github.com/google/tirg/issues/12


## Notes:
All log files will be saved at `./runs/<timestamp><comment>`.
Expand Down
6 changes: 0 additions & 6 deletions test_retrieval.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,12 +97,6 @@ def test(opt, model, testset):
all_imgs[i, :] /= np.linalg.norm(all_imgs[i, :])

# match test queries to target images, get nearest neighbors
# sims = all_queries.dot(all_imgs.T)
#sims = []
#if test_queries:
# for i, t in enumerate(test_queries):
# sims[i, t['source_img_id']] = -10e10 # remove query image
#nn_result = [np.argsort(-sims[i, :])[:110] for i in range(sims.shape[0])]
nn_result = []
for i in tqdm(range(all_queries.shape[0])):
sims = all_queries[i:(i+1), :].dot(all_imgs.T)
Expand Down

0 comments on commit c58daa0

Please sign in to comment.