kaishengtai/neuralart

nil error with CUDNN backend and Inception model

zielmicha opened this issue · 2 comments

This seems to be caused by line 14 of inception.lua - cudnn.SpatialCrossMapLRN doesn't exist.
Example:

$ th main.lua --style a.jpg --content b.jpg --backend cudnn --model inception --optimizer sgd
using cudnn backend 
/home/michal/rnn/torch/install/bin/luajit: /home/michal/rnn/neuralart/models/inception.lua:56: attempt to call local 'lrn' (a nil value)
stack traceback:
    /home/michal/rnn/neuralart/models/inception.lua:56: in function 'create_inception'
    main.lua:84: in main chunk
    [C]: in function 'dofile'
    .../rnn/torch/install/lib/luarocks/rocks/trepl/scm-1/bin/th:131: in main chunk
    [C]: at 0x00405ea0

you need the R3 bindings of cudnn:

git clone https://github.com/soumith/cudnn.torch.git -b R3
cd cudnn.torch
luarocks make

Thanks, Soumith.
@zielmicha Let me know if you continue to have issues with cudnn.