-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lua -> python translation failed #41
Comments
Could you show some snippet to see how |
require 'torch'
Torch_model = torch.class('Torch_model') @oeway I believe I found the problem.I guess it is because lutorpy for python3 doesn't support package.path very well. I also leave some comments here: #4 I use the work around to setup LUA_PATH in bashrc directly to get the problem solved(no need to modify the package.path anymore) |
Thanks for the clarification, but I have no idea right now. I remember that that kind of code worked in python2, is it possible for you to try with python2? |
It works fine with python2, but some outside call in my case need python3, I have to stick with python3. I will use the work around by setting LUA_PATH. Thanks. |
lua file works fine
python3 file doesn't work
Throws the error:
File "test.py", line 9, in
model = Torch_model.new("./")
NameError: name 'Torch_model' is not defined
Any idea about this? The srom_torch_model is a customized lua model. Thanks
The text was updated successfully, but these errors were encountered: