Skip to content

Commit 1c040d7

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 56d05a3 commit 1c040d7

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

tests/tests_pytorch/callbacks/test_finetuning_callback.py

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,12 @@
1919
from lightning.pytorch import LightningModule, Trainer, seed_everything
2020
from lightning.pytorch.callbacks import BackboneFinetuning, BaseFinetuning, ModelCheckpoint
2121
from lightning.pytorch.demos.boring_classes import BoringModel, RandomDataset
22-
from tests_pytorch.helpers.runif import RunIf
2322
from torch import nn
2423
from torch.optim import SGD, Optimizer
2524
from torch.utils.data import DataLoader
2625

26+
from tests_pytorch.helpers.runif import RunIf
27+
2728

2829
class TestBackboneFinetuningCallback(BackboneFinetuning):
2930
def on_train_epoch_start(self, trainer, pl_module):
@@ -282,12 +283,10 @@ def test_complex_nested_model():
282283
directly themselves rather than exclusively their submodules containing parameters."""
283284

284285
model = nn.Sequential(
285-
OrderedDict(
286-
[
287-
("encoder", nn.Sequential(ConvBlockParam(3, 64), ConvBlock(64, 128))),
288-
("decoder", ConvBlock(128, 10)),
289-
]
290-
)
286+
OrderedDict([
287+
("encoder", nn.Sequential(ConvBlockParam(3, 64), ConvBlock(64, 128))),
288+
("decoder", ConvBlock(128, 10)),
289+
])
291290
)
292291

293292
# There are 10 leaf modules or parent modules w/ parameters in the test model

0 commit comments

Comments
 (0)