itayhubara/BinaryNet

About the Cifar10 case

airjimmy89 opened this issue · 2 comments

Hi,

I am trying to run the CIFAR-10 case, but it gives me the following error:

/home/xx/Projects/torch/install/bin/luajit: ...e/xx/Projects/torch/install/share/lua/5.1/trepl/init.lua:384: ...ojects/torch/install/share/lua/5.1/dp/preprocess/zca.lua:44: invalid arguments: DoubleTensor FloatTensor
expected arguments: DoubleTensor [DoubleTensor] double | DoubleTensor [DoubleTensor] [double] DoubleTensor
stack traceback:
[C]: in function 'error'
...e/xx/Projects/torch/install/share/lua/5.1/trepl/init.lua:384: in function 'require'
Main_BinaryNet_Cifar10.lua:84: in main chunk
[C]: in function 'dofile'
...ects/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk
[C]: at 0x00406670

When I run the MNIST case, there is no such problem.

Does anyone know how to solve this problem? Thanks in advance!

Hi,

We used zca whitening to preprocess Cifar10 dataset. It seems that you have some kind of a problem with it. Try deleting line 70 at Main_BinaryNet_Cifar10.lua ("torch.setdefaulttensortype('torch.FloatTensor'")

Best
Itay

Thanks! @itayhubara It works now :D