aleju / mario-ai

Playing Mario with Deep Reinforcement Learning
MIT License
682 stars 142 forks source link

lsnes run lua script error #1

Closed LoungDd closed 7 years ago

LoungDd commented 7 years ago

Hi, aleju. I have followed your instructions and I got stuck in:

Now start the training via Tools -> Run Lua script... and select train.lua.

when I do this operation, the lsnes will throw an error: Error running Lua hunk: [string "train.lua"]:5: module 'paths' not found: no field package.preload['paths'] no file './paths.lua' no file '/usr/local/share/lua/5.1/paths.lua' no file '/usr/local/share/lua/5.1/paths/init.lua' no file '/usr/local/lib/lua/5.1/paths.lua' no file '/usr/local/lib/lua/5.1/paths/init.lua' no file './paths.so' no file '/usr/local/lib/lua/5.1/paths.so' no file '/usr/local/lib/lua/5.1/loadall.so'

But I have already installed paths in ~/torch by using luarocks and require 'paths' works fine in lua cmd line. It seems that lsnes doesnot recognize modules in torch? So, I install package 'paths' in /usr/local/lib/luarocks, then this error was replaced by: module 'torch' not found. Any idea for what's wrong with this problem? Thx

LoungDd commented 7 years ago

Resolved by sudo PREFIX=/usr/local ./install.sh to reinstall the torch.