X-Git-Url: https://www.fleuret.org/cgi-bin/gitweb/gitweb.cgi?p=profiler-torch.git;a=blobdiff_plain;f=test-profiler.lua;h=a78c944464b8a147894650924b34256ab8ebbba6;hp=2f1f0ec7883d993eb222ba5f7404da1257e7e41d;hb=c2a852c17eb19f472762343ee8dfe3e0d1b40dbf;hpb=1cc41a13ae500ceaf037b3ff880a0eeb25472633 diff --git a/test-profiler.lua b/test-profiler.lua index 2f1f0ec..a78c944 100755 --- a/test-profiler.lua +++ b/test-profiler.lua @@ -48,7 +48,10 @@ local model = nn.Sequential() -- Decor it for profiling -profiler.decor(model) +profiler.decorate(model) +print() + +torch.save('model.t7', model) -- Create the data and criterion @@ -86,7 +89,8 @@ end -- Print the accumulated timings profiler.print(model, nbSamples) +-- profiler.print(model) -print('----------------------------------------------------------------------') +print() print(string.format('Total model time %.02fs', modelTime)) print(string.format('Total data time %.02fs', dataTime))