Coder Social home page Coder Social logo

guillaumebrl / yesweckn Goto Github PK

View Code? Open in Web Editor NEW

This project forked from cjones6/yesweckn

0.0 0.0 0.0 140 KB

Implementation of Convolutional Kernel Networks for the paper "Kernel-based Translations of Convolutional Networks"

License: GNU General Public License v3.0

Python 61.15% Shell 13.16% Jupyter Notebook 25.69%

yesweckn's Introduction

YesWeCKN

This code provides an implementation of convolutional kernel networks trained using the method developed in the following paper:

C. Jones, V. Roulet and Z. Harchaoui. Kernel-based Translations of Convolutional Networks. arXiv preprint arXiv:1903.08131, 2019.

If you use this code please cite the paper using the bibtex reference below.

@article{JRH2019,
  title={Kernel-based Translations of Convolutional Networks},
  author={Jones, Corinne and Roulet, Vincent and Harchaoui, Zaid},
  journal={arXiv preprint arXiv:1903.08131},
  year={2019}
}

Introduction

Convolutional kernel networks, first introduced by Mairal et al. (2014) and further developed by Mairal (2016) and Paulin et al. (2017), allow one to learn feature representations for images or signals in an unsupervised or in a supervised manner. In our paper we describe a systematic way to transform a ConvNet into a CKN. Moreover, we develop an end-to-end training algorithm for CKNs and demonstrate that CKNs can often achieve comparable performance to their ConvNet counterparts.

This code implements CKNs for images and other data observed on a grid and trains them using a stochastic gradient optimization method with an accurate gradient. The scripts in the experiments folder train the CKN counterparts to LeNet-1 and LeNet-5 on MNIST (LeCun et al., 1998), All-CNN-C on CIFAR-10 (Springenberg et al., 2015; Krizhevsky and Hinton, 2009), and AlexNet on a subset of ImageNet (Krizhevsky et al., 2012; Krizhevsky 2014). Each architecture is specified in the cfg folder.

Installation

This code is compatible with Python 3.7 and was written with PyTorch version 1.2.0.

The primary dependencies are:

The code can run on a CPU or GPU, although it is intended to be run on a GPU. It is currently set to run on a GPU. To run it on a CPU change the line device = torch.device('cuda:0') in the file src/default_params.py to device = torch.device('cpu')

This version of the code is not compatible with older versions of PyTorch. The code has only been tested on Linux operating systems.

Running the code

The scripts to reproduce the experiments are in the experiments folder. You will need to provide the path to the data folder as the argument data_path.

Contact

You can report issues and ask questions in the repository's issues page. If you choose to send an email instead, please direct it to Corinne Jones at [email protected] and include [yesweckn] in the subject line.

Authors

Corinne Jones
Vincent Roulet
Zaid Harchaoui

License

This code has a GPLv3 license.

Acknowledgements

This work was supported by NSF TRIPODS Award CCF-1740551, the program "Learning in Machines and Brains" of CIFAR, and faculty research awards.

yesweckn's People

Contributors

cjones6 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.