Top AI Repos — open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
CNN Image Retrieval in PyTorch: Training and evaluating CNNs for Image Retrieval in PyTorch
| Date | Stars |
|---|---|
| 2026-07-24 | 1494 |
| 2026-07-25 | 1494 |
| 2026-07-28 | 1494 |
| 2026-07-30 | 1494 |
| 2026-08-06 | 1494 |
Today
— stars today
This week
— stars this week
This month
— stars this month
Momentum
0.0
growth rate 0.00%/day
## CNN Image Retrieval in PyTorch: Training and evaluating CNNs for Image Retrieval in PyTorch
This is a Python toolbox that implements the training and testing of the approach described in our papers:
**Fine-tuning CNN Image Retrieval with No Human Annotation**,
Radenović F., Tolias G., Chum O.,
TPAMI 2018 [[arXiv](https://arxiv.org/abs/1711.02512)]
**CNN Image Retrieval Learns from BoW: Unsupervised Fine-Tuning with Hard Examples**,
Radenović F., Tolias G., Chum O.,
ECCV 2016 [[arXiv](http://arxiv.org/abs/1604.02426)]
<img src="http://cmp.felk.cvut.cz/cnnimageretrieval/img/cnnimageretrieval_network_medium.png" width=\textwidth/>
---
### What is it?
This code implements:
1. Training (fine-tuning) CNN for image retrieval
1. Learning supervised whitening, as post-processing, for global image descriptors
1. Testing CNN image retrieval on Oxford and Paris datasets
---
### Prerequisites
In order to run this toolbox you will need:
1. Python3 (tested with Python 3.7.0 on Debian 8.1)
1. PyTorch deep learning framework (tested with version 1.0.0)
1. All the rest (data + networks) is automatically downloaded with our scripts
---
### Usage
Navigate (```cd```) to the root of the toolbox ```[YOUR_CIRTORCH_ROOT]```.
You can install package with `pip3 install .` if you need.
Make sure to have desired PyTorch and torchvision packages installed.
<details>
<summary><b>Training</b></summary><br/>
Example training script is located in ```YOUR_CIRTORCH_ROOT/cirtorch/examples/train.py```
```
python3 -m cirtorch.examples.train [-h] [--training-dataset DATASET] [--no-val]
[--test-datasets DATASETS] [--test-whiten DATASET]
[--test-freq N] [--arch ARCH] [--pool POOL]
[--local-whitening] [--regional] [--whitening]
[--not-pretrained] [--loss LOSS] [--loss-margin LM]
[--image-size N] [--neg-num N] [--query-size N]
[--pool-size N] [--gpu-id N] [--workers N] [--epochs N]
[--batch-size N] [--optimizer OPTIMIZER] [--lr LR]
[--momentum M] [--weight-decay W] [--print-freq N]
[--resume FILENAME]
EXPORT_DIR
```
For detailed explanation of the options run:
```
python3 -m cirtorch.examples.train -h
```
> **Note**: Data and networks used for training and testing are automatically downloaded when using the example script.
</details>
<details>
<summary><b>Testing</b></summary><br/>
Example testing script is located in ```YOUR_CIRTORCH_ROOT/cirtorch/examples/test.py```
```
python3 -m cirtorch.examples.test [-h] (--network-path NETWORK | --network-offtheshelf NETWORK)
[--datasets DATASETS] [--image-size N]
[--multiscale MULTISCALE] [--whitening WHITENING] [--gpu-id N]
```
For detailed explanation of the options run:
```
python3 -m cirtorch.examples.test -h
```
> **Note**: Data used for testing are automatically downloaded when using the example script.
</details>
---
### Papers implementation
<details>
<summary><b>Training</b></summary><br/>
For example, to train our best network described in the TPAMI 2018 paper run the following command.
After each epoch, the fine-tuned network will be tested on the revisited Oxford and Paris benchmarks:
```
python3 -m cirtorch.examples.train YOUR_EXPORT_DIR --gpu-id '0' --training-dataset 'retrieval-SfM-120k'
--test-datasets 'roxford5k,rparis6k' --arch 'resnet101' --pool 'gem' --loss 'contrastive'
--loss-margin 0.85 --optimizer 'adam' --lr 5e-7 --neg-num 5 --query-size=2000
--pool-size=22000 --batch-size 5 --image-size 362
```
Networks can be evaluated with learned whitening after each epoch (whitening is estimated at the end of the epoch). To achieve this run the following command.
Note that this will significantly slow down the entire training procedure, and you can evaluatExcerpt of 16,967 characters
Read on GitHub62
2
2
Konstantin Slavnov · qalti.com · United States
1
Would you bet a product on this? Bounded 0–100 and slow moving.
matched fp:616f1d696481409e, topic:pytorch, readme:deep learning framework