~/OneDrive/src/pytorch-lightning/tests/trainer git: (master) *>>> git branch -vv * master 0f16f61c [official/master: ahead 2] Update CHANGELOG ~/OneDrive/src/pytorch-lightning/tests/trainer git: (master) >>> py -3.7 -m py.test -v test_trainer.py ============================================================================================================== test session starts =============================================================================================================== platform win32 -- Python 3.7.7, pytest-5.4.3, py-1.8.2, pluggy-0.13.1 -- C:\Users\Airiu\AppData\Local\Programs\Python\Python37\python.exe cachedir: .pytest_cache rootdir: C:\Users\Airiu\OneDrive\src\pytorch-lightning, inifile: setup.cfg plugins: cov-2.10.0, flake8-1.0.6 collected 61 items test_trainer.py::test_no_val_module[True] PASSED [ 1%] test_trainer.py::test_no_val_module[False] PASSED [ 3%] test_trainer.py::test_no_val_end_module[True] PASSED [ 4%] test_trainer.py::test_no_val_end_module[False] PASSED [ 6%] test_trainer.py::test_gradient_accumulation_scheduling PASSED [ 8%] test_trainer.py::test_loading_meta_tags FAILED [ 9%] test_trainer.py::test_loading_yaml PASSED [ 11%] test_trainer.py::test_dp_output_reduce PASSED [ 13%] test_trainer.py::test_model_checkpoint_options[CASE K=-1 (all)] PASSED [ 14%] test_trainer.py::test_model_checkpoint_options[CASE K=1 (2.5, epoch 4)] PASSED [ 16%] test_trainer.py::test_model_checkpoint_options[CASE K=2 (2.5 epoch 4, 2.8 epoch 2)] PASSED [ 18%] test_trainer.py::test_model_checkpoint_options[CASE K=4 (save all 4 base)] PASSED [ 19%] test_trainer.py::test_model_checkpoint_options[CASE K=3 (save the 2nd, 3rd, 4th model)] PASSED [ 21%] test_trainer.py::test_model_checkpoint_options[CASE K=1 (save the 4th model and the last model)] PASSED [ 22%] test_trainer.py::test_model_checkpoint_only_weights PASSED [ 24%] test_trainer.py::test_model_freeze_unfreeze PASSED [ 26%] test_trainer.py::test_resume_from_checkpoint_epoch_restored[True] PASSED [ 27%] test_trainer.py::test_resume_from_checkpoint_epoch_restored[False] PASSED [ 29%] test_trainer.py::test_trainer_max_steps_and_epochs PASSED [ 31%] test_trainer.py::test_trainer_min_steps_and_epochs PASSED [ 32%] test_trainer.py::test_benchmark_option PASSED [ 34%] test_trainer.py::test_testpass_overrides PASSED [ 36%] test_trainer.py::test_test_checkpoint_path[-1-None] PASSED [ 37%] test_trainer.py::test_test_checkpoint_path[-1-best] PASSED [ 39%] test_trainer.py::test_test_checkpoint_path[-1-specific] PASSED [ 40%] test_trainer.py::test_test_checkpoint_path[0-None] PASSED [ 42%] test_trainer.py::test_test_checkpoint_path[0-best] PASSED [ 44%] test_trainer.py::test_test_checkpoint_path[0-specific] PASSED [ 45%] test_trainer.py::test_test_checkpoint_path[1-None] PASSED [ 47%] test_trainer.py::test_test_checkpoint_path[1-best] PASSED [ 49%] test_trainer.py::test_test_checkpoint_path[1-specific] PASSED [ 50%] test_trainer.py::test_test_checkpoint_path[2-None] PASSED [ 52%] test_trainer.py::test_test_checkpoint_path[2-best] PASSED [ 54%] test_trainer.py::test_test_checkpoint_path[2-specific] PASSED [ 55%] test_trainer.py::test_disabled_validation PASSED [ 57%] test_trainer.py::test_nan_loss_detection PASSED [ 59%] test_trainer.py::test_nan_params_detection PASSED [ 60%] test_trainer.py::test_trainer_interrupted_flag PASSED [ 62%] test_trainer.py::test_gradient_clipping PASSED [ 63%] test_trainer.py::test_gpu_choice PASSED [ 65%] test_trainer.py::test_trainer_config[trainer_kwargs0-expected0] PASSED [ 67%] test_trainer.py::test_trainer_config[trainer_kwargs1-expected1] PASSED [ 68%] test_trainer.py::test_trainer_config[trainer_kwargs2-expected2] PASSED [ 70%] test_trainer.py::test_trainer_config[trainer_kwargs3-expected3] PASSED [ 72%] test_trainer.py::test_trainer_config[trainer_kwargs4-expected4] PASSED [ 73%] test_trainer.py::test_trainer_config[trainer_kwargs5-expected5] PASSED [ 75%] test_trainer.py::test_trainer_config[trainer_kwargs6-expected6] PASSED [ 77%] test_trainer.py::test_trainer_config[trainer_kwargs7-expected7] PASSED [ 78%] test_trainer.py::test_trainer_config[trainer_kwargs8-expected8] PASSED [ 80%] test_trainer.py::test_trainer_config[trainer_kwargs9-expected9] PASSED [ 81%] test_trainer.py::test_trainer_config[trainer_kwargs10-expected10] PASSED [ 83%] test_trainer.py::test_trainer_config[trainer_kwargs11-expected11] PASSED [ 85%] test_trainer.py::test_trainer_config[trainer_kwargs12-expected12] PASSED [ 86%] test_trainer.py::test_trainer_config[trainer_kwargs13-expected13] SKIPPED [ 88%] test_trainer.py::test_trainer_config[trainer_kwargs14-expected14] SKIPPED [ 90%] test_trainer.py::test_trainer_config[trainer_kwargs15-expected15] SKIPPED [ 91%] test_trainer.py::test_trainer_config[trainer_kwargs16-expected16] SKIPPED [ 93%] test_trainer.py::test_trainer_subclassing PASSED [ 95%] test_trainer.py::test_trainer_omegaconf[trainer_params0] PASSED [ 96%] test_trainer.py::test_trainer_omegaconf[trainer_params1] PASSED [ 98%] test_trainer.py::test_trainer_pickle PASSED [100%] ==================================================================================================================== FAILURES ==================================================================================================================== _____________________________________________________________________________________________________________ test_loading_meta_tags _____________________________________________________________________________________________________________ tmpdir = local('C:\\Users\\Airiu\\AppData\\Local\\Temp\\pytest-of-AIRIUM\\pytest-1\\test_loading_meta_tags0') def test_loading_meta_tags(tmpdir): """ test for backward compatibility to meta_tags.csv """ tutils.reset_seed() hparams = EvalModelTemplate.get_default_hparams() # save tags logger = tutils.get_default_logger(tmpdir) logger.log_hyperparams(Namespace(some_str='a_str', an_int=1, a_float=2.0)) logger.log_hyperparams(hparams) logger.save() # load hparams path_expt_dir = tutils.get_data_path(logger, path_dir=tmpdir) hparams_path = os.path.join(path_expt_dir, TensorBoardLogger.NAME_HPARAMS_FILE) hparams = load_hparams_from_yaml(hparams_path) # save as legacy meta_tags.csv tags_path = os.path.join(path_expt_dir, 'meta_tags.csv') save_hparams_to_tags_csv(tags_path, hparams) > tags = load_hparams_from_tags_csv(tags_path) test_trainer.py:203: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ..\..\pytorch_lightning\core\saving.py:295: in load_hparams_from_tags_csv tags = {row[0]: convert(row[1]) for row in list(csv_reader)[1:]} _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ .0 = > tags = {row[0]: convert(row[1]) for row in list(csv_reader)[1:]} E IndexError: list index out of range ..\..\pytorch_lightning\core\saving.py:295: IndexError ================================================================================================================ warnings summary ================================================================================================================ C:\Users\Airiu\OneDrive\src\pytorch-lightning\pytorch_lightning\utilities\apply_func.py:1 C:\Users\Airiu\OneDrive\src\pytorch-lightning\pytorch_lightning\utilities\apply_func.py:1 C:\Users\Airiu\OneDrive\src\pytorch-lightning\pytorch_lightning\utilities\apply_func.py:1: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3,and in 3.9 it will stop working from collections import Mapping, Sequence C:\Users\Airiu\AppData\Local\Programs\Python\Python37\lib\site-packages\win32\lib\pywintypes.py:2 C:\Users\Airiu\AppData\Local\Programs\Python\Python37\lib\site-packages\win32\lib\pywintypes.py:2: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses import imp, sys, os C:\Users\Airiu\AppData\Local\Programs\Python\Python37\lib\site-packages\graphql\type\directives.py:55 C:\Users\Airiu\AppData\Local\Programs\Python\Python37\lib\site-packages\graphql\type\directives.py:55: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3,and in 3.9 it will stop working assert isinstance(locations, collections.Iterable), 'Must provide locations for directive.' tests/trainer/test_trainer.py::test_no_val_end_module[True] C:\Users\Airiu\OneDrive\src\pytorch-lightning\tests\trainer\test_trainer.py:71: PytestWarning: Value of environment variable TORCH_HOME type should be str, but got local('C:\\Users\\Airiu\\AppData\\Local\\Temp\\pytest-of-AIRIUM\\pytest-1\\test_no_val_end_module_True_0') (type: LocalPath); converted to str implicitly monkeypatch.setenv('TORCH_HOME', tmpdir) tests/trainer/test_trainer.py::test_no_val_end_module[False] C:\Users\Airiu\OneDrive\src\pytorch-lightning\tests\trainer\test_trainer.py:71: PytestWarning: Value of environment variable TORCH_HOME type should be str, but got local('C:\\Users\\Airiu\\AppData\\Local\\Temp\\pytest-of-AIRIUM\\pytest-1\\test_no_val_end_module_False_0') (type: LocalPath); converted to str implicitly monkeypatch.setenv('TORCH_HOME', tmpdir) tests/trainer/test_trainer.py::test_resume_from_checkpoint_epoch_restored[True] C:\Users\Airiu\OneDrive\src\pytorch-lightning\tests\trainer\test_trainer.py:343: PytestWarning: Value of environment variable TORCH_HOME type should be str, but got local('C:\\Users\\Airiu\\AppData\\Local\\Temp\\pytest-of-AIRIUM\\pytest-1\\test_resume_from_checkpoint_ep0') (type: LocalPath); converted to str implicitly monkeypatch.setenv('TORCH_HOME', tmpdir) tests/trainer/test_trainer.py::test_resume_from_checkpoint_epoch_restored[False] C:\Users\Airiu\OneDrive\src\pytorch-lightning\tests\trainer\test_trainer.py:343: PytestWarning: Value of environment variable TORCH_HOME type should be str, but got local('C:\\Users\\Airiu\\AppData\\Local\\Temp\\pytest-of-AIRIUM\\pytest-1\\test_resume_from_checkpoint_ep1') (type: LocalPath); converted to str implicitly monkeypatch.setenv('TORCH_HOME', tmpdir) tests/trainer/test_trainer.py::test_trainer_interrupted_flag C:\Users\Airiu\OneDrive\src\pytorch-lightning\pytorch_lightning\utilities\distributed.py:25: UserWarning: Detected KeyboardInterrupt, attempting graceful shutdown... warnings.warn(*args, **kwargs) tests/trainer/test_trainer.py::test_trainer_config[trainer_kwargs4-expected4] C:\Users\Airiu\OneDrive\src\pytorch-lightning\pytorch_lightning\utilities\distributed.py:25: UserWarning: num_processes is only used for distributed_backend="ddp_cpu". Ignoring it. warnings.warn(*args, **kwargs) tests/trainer/test_trainer.py::test_trainer_config[trainer_kwargs11-expected11] C:\Users\Airiu\OneDrive\src\pytorch-lightning\pytorch_lightning\utilities\distributed.py:25: UserWarning: You requested one or more GPUs, but set the backend to `ddp_cpu`. Training will not use GPUs. warnings.warn(*args, **kwargs) tests/trainer/test_trainer.py::test_trainer_pickle C:\Users\Airiu\AppData\Local\Programs\Python\Python37\lib\site-packages\torch\storage.py:34: FutureWarning: pickle support for Storage will be removed in 1.5. Use `torch.save` instead warnings.warn("pickle support for Storage will be removed in 1.5. Use `torch.save` instead", FutureWarning) -- Docs: https://docs.pytest.org/en/latest/warnings.html ============================================================================================================ short test summary info ============================================================================================================= FAILED test_trainer.py::test_loading_meta_tags - IndexError: list index out of range ======================================================================================== 1 failed, 56 passed, 4 skipped, 12 warnings in 490.32s (0:08:10) ========================================================================================