Update.
[profiler-torch.git] / test-profiler.lua
index 71127a0..6d79e91 100755 (executable)
@@ -51,12 +51,9 @@ local model = nn.Sequential()
        )
    :add(nn.Linear(1000, 100))
 
--- Decor it for profiling
+-- Decorate it for profiling
 
 profiler.decorate(model)
-print()
-
-torch.save('model.t7', model)
 
 -- Create the data and criterion
 
@@ -93,8 +90,9 @@ end
 
 -- Print the accumulated timings
 
--- profiler.print(model, nbSamples)
-profiler.print(model)
+print()
+profiler.print(model, nbSamples)
+-- profiler.print(model)
 
 print(string.format('Total model time %.02fs', modelTime))
 print(string.format('Total data time %.02fs', dataTime))