tim = 0 start = torch.cuda.Event(enable_timing=True) #the times end = torch.cuda.Event(enable_timing=True) start.record() out = net(image_input) end.record() torch.cuda.synchronize() tim = start.elapsed_time(end)
08-01
1439
11-21
1957