xxradon / PytorchToCaffe

Pytorch model to caffe model, supported pytorch 0.3, 0.3.1, 0.4, 0.4.1 ,1.0 , 1.0.1 , 1.2 ,1.3 .notice that only pytorch 1.1 have some bugs
MIT License
783 stars 224 forks source link

Error when loading Alexnet transformed in caffe #24

Open MBasarte opened 5 years ago

MBasarte commented 5 years ago

Hello,

In order to translate Alexnet from Pytorch to Caffe, I added the lines describe in https://github.com/xxradon/PytorchToCaffe/issues/5#issuecomment-495517848.

The script throws Transform Completed and I get my prototxt and caffemodel files but when I try to load them from Caffe I get the following error:

F0607 13:28:49.344043 5379 reshape_layer.cpp:87] Check failed: top[0]->count() == bottom[0]->count() (9216 vs. 1024) output count must match input count Check failure stack trace: Aborted (core dumped)

I cant find the solution to this problem... any idea?

Big thanks! :)