Skip to content
Snippets Groups Projects
Commit 2c050de5 authored by Tamino Huxohl's avatar Tamino Huxohl
Browse files

test batch size for patches in unet main

parent fcb23a3e
No related branches found
No related tags found
No related merge requests found
...@@ -169,11 +169,12 @@ if __name__ == "__main__": ...@@ -169,11 +169,12 @@ if __name__ == "__main__":
net = net.to(device) net = net.to(device)
iterations = 100 iterations = 100
for batch_size in range(1, 17): for batch_size in range(128, 129):
since = time.time() since = time.time()
for i in range(iterations): for i in range(iterations):
print(f"{str(batch_size):>2}/17 - {str(i+1):>3}/{iterations}", end="\r") print(f"{str(batch_size):>2}/17 - {str(i+1):>3}/{iterations}", end="\r")
_inputs = torch.rand((batch_size, 1, 64, 128, 128)) # _inputs = torch.rand((batch_size, 1, 64, 128, 128))
_inputs = torch.rand((batch_size, 1, 32, 32, 32))
_inputs = _inputs.to(device) _inputs = _inputs.to(device)
_outputs = net(_inputs) _outputs = net(_inputs)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment