Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
joao-alex-cunha authored and rwightman committed Nov 17, 2023
1 parent bbf0ab0 commit a38c2b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/test_optim.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ def fn_base(optimizer, weight, bias):
# to a different type and move to a different device.
if torch_device == 'cpu':
return
elif torch_device == 'cuda' and not torch.cuda.is_available:
elif torch_device == 'cuda' and not torch.cuda.is_available():
return

with torch.no_grad():
Expand Down

0 comments on commit a38c2b4

Please sign in to comment.