Skip to content
This repository has been archived by the owner on Apr 2, 2020. It is now read-only.

Using torch2caffe #16

Closed
Svjatogor opened this issue Aug 11, 2016 · 2 comments
Closed

Using torch2caffe #16

Svjatogor opened this issue Aug 11, 2016 · 2 comments

Comments

@Svjatogor
Copy link

Svjatogor commented Aug 11, 2016

I've done

git clone  https://github.com/facebook/fb-caffe-exts.git
cd fb-caffe-exts

exported paths like that to my system

export LD_PRELOAD=/path/to/libcaffe.so
export PYTHONPATH=$PYTHONPATH:/path/to/caffe/python/:/path/to/fb-caffe-exts/

then

th torch2caffe/torch2caffe.lua --help

and it all failed:

/home/user/torch/install/bin/luajit: /home/user/torch/install/share/lua/5.1/trepl/init.lua:384: /home/user/torch/install/share/lua/5.1/trepl/init.lua:384: module 'fb.python' not found:No LuaRocks module found for fb.python
    no field package.preload['fb.python']
    no file '/home/user/.luarocks/share/lua/5.1/fb/python.lua'
    no file '/home/user/.luarocks/share/lua/5.1/fb/python/init.lua'
    no file '/home/user/torch/install/share/lua/5.1/fb/python.lua'
    no file '/home/user/torch/install/share/lua/5.1/fb/python/init.lua'
    no file './fb/python.lua'
    no file '/home/user/torch/install/share/luajit-2.1.0-beta1/fb/python.lua'
    no file '/usr/local/share/lua/5.1/fb/python.lua'
    no file '/usr/local/share/lua/5.1/fb/python/init.lua'
    no file '/home/user/.luarocks/lib/lua/5.1/fb/python.so'
    no file '/home/user/torch/install/lib/lua/5.1/fb/python.so'
    no file '/home/user/torch/install/lib/fb/python.so'
    no file './fb/python.so'
    no file '/usr/local/lib/lua/5.1/fb/python.so'
    no file '/usr/local/lib/lua/5.1/loadall.so'
    no file '/home/user/.luarocks/lib/lua/5.1/fb.so'
    no file '/home/user/torch/install/lib/lua/5.1/fb.so'
    no file '/home/user/torch/install/lib/fb.so'
    no file './fb.so'
    no file '/usr/local/lib/lua/5.1/fb.so'
    no file '/usr/local/lib/lua/5.1/loadall.so'
stack traceback:
    [C]: in function 'error'
    /home/user/torch/install/share/lua/5.1/trepl/init.lua:384: in function 'require'
    torch2caffe/torch2caffe.lua:9: in main chunk
    [C]: in function 'dofile'
    ...user/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:145: in main chunk
    [C]: at 0x00406670


I want to convert torch to caffe model. How can I prepare this soft to do that? Smth to install or what?

@zhanghang1989
Copy link

Hey,
This script will install all the dependencies
@https://github.com/zhanghang1989/fb-caffe-exts/blob/mydev/install-dep-16.04.sh

Best

@alejandronespereira
Copy link

Just what I was looking for @zhanghang1989. Thanks a lot

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants