pkulchenko/ZeroBranePackage

cannot load '/home/parallels/torch/install/lib/lua/5.1/libtorch.so'

chenbohua3 opened this issue · 5 comments

when i following the instruction of http://notebook.kulchenko.com/zerobrane/torch-debugging-with-zerobrane-studio
and then run the test.lua
finally i got the error cannot load '/home/parallels/torch/install/lib/lua/5.1/libtorch.so'
but there does exit libtorch.so in the above path
how can i fix it plz help me
thx a lot :)
my system is ubuntu 16.04

You'll need to provide more information. What version of ZeroBrane Studio are you using? What did you set path.torch value to? What do you get in the Output window?

thanks for your patience.
ZeroBrane version is 1.60
user.lua for user and system are both:
path.torch = [[/home/parallels/torch/install]]
path.lua = [[/home/parallels/torch/install/bin/luajit]]
lua interpreter i choose torch-7

output are as follows:
Program starting as '"/home/parallels/torch/install/bin/luajit" "/home/parallels/code/face-alignment-training/test.lua" '.
Program 'luajit' started in '/home/parallels/code/face-alignment-training' (pid: 8795).
/home/parallels/torch/install/bin/luajit: /home/parallels/torch/install/share/lua/5.1/torch/init.lua:13: cannot load '/home/parallels/torch/install/lib/lua/5.1/libtorch.so'
stack traceback:
[C]: in function 'require'
/home/parallels/torch/install/share/lua/5.1/torch/init.lua:13: in main chunk
[C]: in function 'require'
/home/parallels/code/face-alignment-training/test.lua:5: in main chunk
[C]: at 0x00405d50
Program completed in 0.01 seconds (pid: 8795).

I don't see anything obviously wrong here, but if /home/parallels/torch/install/bin/luajit can't load /home/parallels/torch/install/lib/lua/5.1/libtorch.so, this is probably not something that the IDE should be responsible for. Does the same command work outside of the IDE? Do luajit and libtorch.so have the same architecture (32bit vs 64bit)? It clearly finds the file, but maybe some of its dependencies are missing?

i think you are right, when i use luajit in terminal and require 'torch', the same error appears.

now i am trying to fix my torch problem.

thanks again :)

ok; thanks you for the update. I'm closing for now, but feel free to update when you got additional information.