I tried this bit of code from the readme and got attempt to call global 'testHook' (a nil value). So I changed local testHook = function(self, path) to testHook = function(self, path) and it works. Just posting here to report that the read me example might be wrong.
dofile('donkey.lua')
img = testHook({loadSize}, 'test.jpg')
model = torch.load('model_10.t7')
if img:dim() == 3 then
img = img:view(1, img:size(1), img:size(2), img:size(3))
end
predictions = model:forward(img:cuda())
I tried this bit of code from the readme and got attempt to call global 'testHook' (a nil value). So I changed
local testHook = function(self, path)
totestHook = function(self, path)
and it works. Just posting here to report that the read me example might be wrong.