No description, website, or topics provided.
Switch branches/tags
Nothing to show
Clone or download
Latest commit 07daee5 Sep 14, 2015
Failed to load latest commit information.
data Update format Aug 24, 2015
models Update Aug 24, 2015
LICENSE Update Aug 24, 2015 Fixing address typo. Sep 14, 2015 Update Aug 24, 2015 Update Aug 24, 2015 Update Aug 24, 2015 Flatten output score before return. Aug 24, 2015 Update Aug 24, 2015 Update Aug 24, 2015


Matchnet is a deep learning approach for patch-based local image matching, which jointly learns feature representation and matching function from data. More details about this approach can be found in our CVPR'15 paper.

This repository contains reference source code for evaluating MatchNet models on Phototour Patch dataset.

Below is a step-by-step guide for downloading the dataset, generate patch database and running evaluation with Matchnet models. We assume Caffe is installed (preferably with GPU support) and Pycaffe (Caffe's python interface) is also installed and added to PYTHONPATH.

Clone the repository.

git clone
cd matchnet

Downlowd the Phototour patch dataset.

cd data/phototour

curl -O
unzip -q -d liberty

curl -O
unzip -q -d notredame

curl -O
unzip -q -d yosemite

cd ../..

Generate leveldb database for each dataset. The databases are saved under data/leveldb.


Download pretrained Matchnet models. (Here we only download the model trained on liberty. For more models see models/

cd models

curl -O
curl -O

cd ..

Evalute the liberty model on notredame's test set. (Remove the quoted argument to use CPU.)

./ liberty notredame "--use_gpu --gpu_id=0"

When the script is done, the last line should be the following:

Error rate at 95% recall: 4.48%

License and Citation

Matchnet source code is released under BSD license. The reference models are released for unrestriced use.

Please cite our paper if Matchnet helps your research:

  Author = {Han, Xufeng and Leung, Thomas and Jia, Yangqing and Sukthankar, Rahul and Berg, Alexander. C.},
  Booktitle = {CVPR},
  Title = {MatchNet: Unifying Feature and Metric Learning for Patch-Based Matching},
  Year = {2015}