Code Monkey home page Code Monkey logo

bingan's Introduction

binGAN

This code implement the binGAN method, that was presented in Zieba M., Semberecki P. El-Gaaly T., Trzcinski T.. "BinGAN: Learning Compact Binary Descriptors with a Regularized GAN." arxiv

Please watch our video here

The training code requires Lasagne. Using GPU is highly advised.

Docker setup

Go into the Github repository directory.

To build Docker image, perform commands:

docker build --build-arg USER_UID=$(id -u) --build-arg USER_GID=$(id -g) -t lasagne_img .

To run docker container instance with GPU support:

nvidia-docker run -it --name lasagne_gpu --user lasagne -v $(pwd):/home/lasagne/host/binGAN lasagne_img bash

The docker container already has the git repository, however you can mount you own host directory by adding -v option, for example /home/user/binGAN:/home/lasagne/host/binGAN to have results/datasets saved independently to container.

Running the code

The procedure of training binGan is run with train_model.py script.

There are two datasets for two tasks in which binGAN is evaluated:

  • Brown dataset (image matching)
  • Cifar10 (image retrieval)

Selecting the proper dataset is performed in settings.py, by setting proper value of dataset_type parameter. In this file it is possible also to set various type of training hyperparameters described in details in the paper.

Brown dataset, which is composed of three subsets: yosemite, notredame and liberty. It is crucial to specify, which training and validation set by setting proper values to parameters: data_name and test_data.

It is crucial to set proper value of binary features (num_features), while switching between datasets.

The quality of image matching on Brown dataset is evaluated by script test_brown.py

The quality of image retrieval on Cifar10 dataset is evaluated by script test_cifar10.py

bingan's People

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.