29bcf309848b9c5ff95ab0d6dd0f12b7ae28f9b4,tests/core/test_datamodules.py,,test_train_loop_only,#Any#,192

Before Change


    // fit model
    trainer.fit(model, dm)
    assert trainer.state == TrainerState.FINISHED, f"Training failed with {trainer.state}"
    assert trainer.logger_connector.callback_metrics["loss"] < 0.6


def test_train_val_loop_only(tmpdir):
    reset_seed()

After Change


def test_train_loop_only(tmpdir):
    reset_seed()

    dm = BoringDataModule()
    model = BoringModel()

    model.validation_step = None
    model.validation_step_end = None
    model.validation_epoch_end = None
    model.test_step = None
    model.test_step_end = None
    model.test_epoch_end = None

    trainer = Trainer(
        default_root_dir=tmpdir,
        max_epochs=1,
        weights_summary=None,
    )

    // fit model
    result = trainer.fit(model, dm)
    assert trainer.state == TrainerState.FINISHED, f"Training failed with {trainer.state}"
    assert result
    // TODO: add end-to-end test
    // assert trainer.callback_metrics["loss"] < 0.6
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 5

Non-data size: 3

Instances


Project Name: williamFalcon/pytorch-lightning
Commit Name: 29bcf309848b9c5ff95ab0d6dd0f12b7ae28f9b4
Time: 2021-01-12
Author: rohitgr1998@gmail.com
File Name: tests/core/test_datamodules.py
Class Name:
Method Name: test_train_loop_only


Project Name: williamFalcon/pytorch-lightning
Commit Name: 29bcf309848b9c5ff95ab0d6dd0f12b7ae28f9b4
Time: 2021-01-12
Author: rohitgr1998@gmail.com
File Name: tests/core/test_datamodules.py
Class Name:
Method Name: test_full_loop_single_gpu


Project Name: williamFalcon/pytorch-lightning
Commit Name: 29bcf309848b9c5ff95ab0d6dd0f12b7ae28f9b4
Time: 2021-01-12
Author: rohitgr1998@gmail.com
File Name: tests/core/test_datamodules.py
Class Name:
Method Name: test_full_loop_dp


Project Name: williamFalcon/pytorch-lightning
Commit Name: 29bcf309848b9c5ff95ab0d6dd0f12b7ae28f9b4
Time: 2021-01-12
Author: rohitgr1998@gmail.com
File Name: tests/core/test_datamodules.py
Class Name:
Method Name: test_train_val_loop_only


Project Name: williamFalcon/pytorch-lightning
Commit Name: 29bcf309848b9c5ff95ab0d6dd0f12b7ae28f9b4
Time: 2021-01-12
Author: rohitgr1998@gmail.com
File Name: tests/core/test_datamodules.py
Class Name:
Method Name: test_full_loop