Skip to content

Commit 70514cb

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 513121d commit 70514cb

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

tests/tests_pytorch/models/test_hooks.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,7 @@ def on_before_zero_grad(self, optimizer):
6161

6262
model = CurrentTestModel()
6363

64-
trainer = Trainer(
65-
devices=1,
66-
default_root_dir=tmp_path,
67-
max_steps=max_steps,
68-
max_epochs=2
69-
)
64+
trainer = Trainer(devices=1, default_root_dir=tmp_path, max_steps=max_steps, max_epochs=2)
7065
assert model.on_before_zero_grad_called == 0
7166
trainer.fit(model)
7267
assert max_steps == model.on_before_zero_grad_called
@@ -744,7 +739,8 @@ def test_trainer_model_hook_system_predict(tmp_path):
744739
devices=1,
745740
default_root_dir=tmp_path,
746741
limit_predict_batches=batches,
747-
enable_progress_bar=False, callbacks=[callback]
742+
enable_progress_bar=False,
743+
callbacks=[callback],
748744
)
749745
trainer.predict(model)
750746
expected = [

0 commit comments

Comments
 (0)