-
Notifications
You must be signed in to change notification settings - Fork 148
Issue with running torch2caffe/torch2caffe.lua #2
Comments
I worked around this issue by using LD_PRELOAD to load libcaffe shared object. I did encounter other issues such as unimplemented layers (LRN) which I was able to handle as well. I'm going to close this issue out and open a separate issue for other questions. Thanks! |
Hi Vimalthilak, Sorry I missed this - yes, this uses fblualib's Python, so you need to ensure that pycaffe, libcaffe.so is on PYTHONPATH, etc. For the additional layers - we're essentially adding them as-needed. I need to sync up and add a few new ones (cudnn.SpatialBatchNormalization, nn.CAddTable I think are the only additions). LRN would be cool - I assume you mean cudnn.SpatialCrossMapLRN? |
Hi @ajtulloch, Thanks for the response!
It can be cudnn.SpatialCrossMapLRN or nn.SpatialCrossMapLRN. This layer is easy enough that I hacked around lib.lua and lib_py.py (IIRC) to get these to work. By any chance, have you had a chance to port the model in https://github.com/soumith/inception.torch to caffe. A port of inception-v3 would be nice as well but that requires batch normalization layer. Not sure if it's doable as-is. I am happy to provide any help, if doable, if that helps with your effort to develop and add features to and/or test this library. Thanks! |
Hi, Where did you find torch2caffe.lib? I am getting the next error: /usr/local/bin/luajit: torch2caffe.lua:9: module 'torch2caffe.lib' not found:No LuaRocks module found for torch2caffe.lib Thanks |
@fhdiaze It's the lib module under torch2caffe. I think you need to ensure that lib under /torch2caffe is in the path somewhere. |
@vimalthilak thanks for the response, which file do you mean? all? I do not have so much experience with lua. Thanks. |
It should work if you have the |
Hi, I am doing: package.path = package.path .. ';/home/fhdiaze/Code/fb-caffe-exts/torch2caffe/?.lua and after that local t2c = require 'torch2caffe.lib' But I am getting the next error: [string "local t2c = require 'torch2caffe.lib'..."]:1: module 'torch2caffe.lib' not found:No LuaRocks module found for torch2caffe.lib Do I have to install using luarocks? Thanks |
Does something like http://stackoverflow.com/questions/18125775/lua-require-fails-to-find-submodule-but-searchpath-succeeds work? |
@ajtulloch We're trying to convert the pretrained Resnet Torch models here with |
Sure, I need to resync with our internal branch. Give me a few hours. |
1 similar comment
Sure, I need to resync with our internal branch. Give me a few hours. |
@ajtulloch 👍 thanks! |
@ajtulloch Do you have any update on the resync? Thanks! |
I have got the test running now (penlight was causing problems), but all are failing:
The error is due to: If anyone knows the root of this problem, please post. Thanks. |
HI @ajtulloch, have you resync with your internal branch? It seems that is still report "Unknown layer type: nn.SpatialBatchNormalization". |
Dear ajtulloch /usr/bin/luajit: /usr/share/lua/5.1/trepl/init.lua:384: /usr/share/lua/5.1/trepl/init.lua:384: module 'fb.python' not found:No LuaRocks module found for fb.python |
@ajtulloch I have follow your steps... I compile Caffe with pycaffe and insert the path in .bashrc file. But now i got this error... Can you help me in this regards.. Thanks |
Hi,
Thanks for providing an open torch2caffe conversion tool. I encountered the following error when I executed torch2caffe.lua:
Any idea what I might be missing in my set-up? I tried to add an init.py but that's leading me to a completely different error
Any help is greatly appreciated! Thanks.
The text was updated successfully, but these errors were encountered: