Open gombru opened 8 years ago
Hi, here I found the implemenation of XNOR-Net in Caffe: https://github.com/loswensiana/BWN-XNOR-caffe. I am currently trying that, can you share your results on cifar10 after you tried it.
Thank you, I will!
Hi, were you able to get it to work on Caffe?
I haven't had the chance to try it :(
thanks :)
Hi, did someone find out how to compile this caffe version? The new defined layers (BinActive etc..) which version of cuDNN and CUDA require? Thanks
I tried the caffe verison mentioned above on cifar10. Well the accuracy achieved is ~75% same as original cifar10 trained on simple convolution using Caffe. But I am quite disappointed with the prediction time of single image. prediction time of Image on original architecture of cifar10 - ~38ms prediction time of Image on BWN-convolution architecture of cifar10 - ~77ms
I expected the prediction time of BWN-convolution to be less than the convolutional network but it didn't achieve that. :(
I am having a similar experience as @siftr:
Prediction time for original caffe architecture: 39sec/10K-images Prediction time for trained xnor-net model: 49sec/10K-images.
If there is something I'm missing here, I would appreciate any advice, as I was hoping for a big speed-up based on the paper.
Why is this caffe implementation different from what I was familiar with? For example, I had a squeezenet.prototxt. It was something like this.
input: "data" input_shape { dim: 1 dim: 3 dim: 227 dim: 227 } layer { name: "conv1" type: "Convolution" bottom: "data" top: "conv1" convolution_param { num_output: 64 kernel_size: 3 stride: 2 } } layer { name: "relu_conv1" type: "ReLU" bottom: "conv1" top: "conv1" } layer { name: "pool1" type: "Pooling" bottom: "conv1" top: "pool1" pooling_param { pool: MAX kernel_size: 3 stride: 2 } } layer { name: "fire2/squeeze1x1" type: "Convolution" bottom: "pool1" top: "fire2/squeeze1x1" convolution_param { num_output: 16 kernel_size: 1 } } ...
@siftr @michaelholm-ce that caffe version is just a simulation of XNOR-NET using single precision operators. You can find that the computation in binary_conv_layer.cu is almost the same as cudnn_conv_layer.cu.
I detect face base on MTCNN ,CAFFE version Prediction time 60ms/image using openblas,when I chang Conv to BinconvConv and modify binaryconv code ,prediction time 50ms/image , How to modify the code to increase the speed by 50%
Is there any implementation of XNOR-Net in Caffe? I'm very interested to embed a net in a phone.