1
0
Fork 0
mirror of synced 2024-05-19 04:12:19 +12:00

Fix a bug that the time benchmark does not works when method=user and scale=1

This commit is contained in:
nagadomi 2016-07-22 19:56:33 +09:00
parent 962bdcf300
commit 3add726da3

View file

@ -320,9 +320,13 @@ local function benchmark(opt, x, model1, model2)
model2_output = image_f(model2, input, opt.crop_size, opt.batch_size)
end
end
t = sys.clock()
model1_output = image_f(model1, input, opt.crop_size, opt.batch_size)
model1_time = model1_time + (sys.clock() - t)
if model2 then
t = sys.clock()
model2_output = image_f(model2, input, opt.crop_size, opt.batch_size)
model2_time = model2_time + (sys.clock() - t)
end
end
end