Code Monkey home page Code Monkey logo

xnor-net's Introduction

Implementation of XNOR-Net in mxnet and torch

Proof of concept XNOR-Net demo on MNIST dataset.

Data Preparation

Download the mnist dataset and unpack it to path_data.

Models

  • mnist_cnn: ordinary convolutional network
  • mnist_bwn: binary weight network
  • mnist_xnor: xnor-net

Usage

  • torch version
cd torch/xnornet_cpu/
th main.lua -dataDir <path_data> -modelName <mnist_xnor>
  • mxnet version
cd mxnet/
python main.py --network='mnist_cnn'

Accuracy

  • torch version
Model type Testing accuracy
mnist_cnn 98.81%
mnist_bwn 98.38%
mnist_xnor 96.64%
  • mxnet version
Model type Testing accuracy
mnist_cnn 99.02%
mnist_bwn 98.92%
mnist_xnor 98.26%

xnor-net's People

Contributors

jiaolong avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

xnor-net's Issues

some mistakes in bnn_layers.py

I think there are some mistakes in bnn_layers.py (mxnet version). In BinaryActivation, the forward and backward should contain the alpha. Do you think so? When I contain the alpha, I get 94.28% testing accuracy after 5 epochs.

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.