dengan torch.no_grad () jika kondisi
with torch.set_grad_enabled(not no_grad_condition):
out=network(input)
Bored Coder
with torch.set_grad_enabled(not no_grad_condition):
out=network(input)