Skip to content

Commit

Permalink
tidy imports
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathon Hare committed Nov 5, 2023
1 parent c22ba53 commit da2c9fe
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
1 change: 0 additions & 1 deletion tests/callbacks/test_torch_scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,6 @@ def test_lambda_lr(self, lr_mock):

class TestCyclicLR(TestCase):
def test_lambda_lr(self):
import torch
if not _pytorch_version_lt("1.0.0"): # CyclicLR is implemented
with patch('torch.optim.lr_scheduler.CyclicLR') as lr_mock:
state = {torchbearer.OPTIMIZER: 'optimizer', torchbearer.EPOCH: 0, torchbearer.MODEL: Mock()}
Expand Down
1 change: 0 additions & 1 deletion torchbearer/callbacks/torch_scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import warnings

import torch
from packaging import version

import torchbearer
from torchbearer.bases import get_metric, _pytorch_version_lt
Expand Down

0 comments on commit da2c9fe

Please sign in to comment.