X-Git-Url: https://www.fleuret.org/cgi-bin/gitweb/gitweb.cgi?p=dagnn.git;a=blobdiff_plain;f=test-dagnn.lua;h=0c9fe6d57376b8be5a3d2621677e1bd667f429a9;hp=434f662ae37b4bee93bc36ebf8177095d11455a6;hb=941ae69a9ccf274e3bff8b1fa45da04fb825a647;hpb=e5030cca047eed4b8c5db172fc52e893b1b1d843 diff --git a/test-dagnn.lua b/test-dagnn.lua index 434f662..0c9fe6d 100755 --- a/test-dagnn.lua +++ b/test-dagnn.lua @@ -42,17 +42,22 @@ g:addEdge(b, c) g:addEdge(b, d) g:addEdge(d, f) -g:setInput({a}) -g:setOutput({e, f}) +g:setInput({ a }) +g:setOutput({ e, f }) g:print() input = torch.Tensor(3, 10):uniform() -output = g:updateOutput({input}) +output = g:updateOutput({ input }) printTensorTable(output) ---------------------------------------------------------------------- +print('******************************************************************') +print('** updateGradInput ***********************************************') +print('******************************************************************') gradInput = g:updateGradInput({ input }, output) + +printTensorTable(gradInput)