AttributeError: 'xxx' object has no attribute 'tng_dataloader'
Describe the bug
I modified the template to implement my model and task. In the process, I ran it several times and correctly. However, when I revised the evaluation metrics, the program suddenly started to report errors: AttributeError: 'DSANet' object has no attribute 'tng_dataloader'. However, I've defined the def tng_dataloader(self) method. Although I delete what I have written and make sure all is right, the error still exists.
Code
The error report:
Traceback (most recent call last):
  File "single_cpu_trainer.py", line 112, in <module>
    main(hyperparams)
  File "single_cpu_trainer.py", line 83, in main
    trainer.fit(model)
  File "E:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\pytorch_lightning\models\trainer.py", line 567, in fit
    self.__run_pretrain_routine(model)
  File "E:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\pytorch_lightning\models\trainer.py", line 742, in __run_pretrain_routine
    self.get_dataloaders(ref_model)
  File "E:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\pytorch_lightning\models\trainer.py", line 469, in get_dataloaders
    self.tng_dataloader = model.tng_dataloader
  File "E:\Program Files (x86)\Microsoft Visual Studio\Shared\Anaconda3_64\lib\site-packages\torch\nn\modules\module.py", line 591, in __getattr__
    type(self).__name__, name))
AttributeError: 'DSANet' object has no attribute 'tng_dataloader'

The code:
class DSANet(LightningModule):
    # ...
    def __dataloader(self, train):
        # init data generators
        set_type = 'train' if train else 'test'
        dataset = MTSFDataset(window=self.hparams.window, horizon=self.hparams.horizon, data_name=self.hparams.data_name, set_type=set_type, data_dir=self.hparams.data_dir)
        # when using multi-node we need to add the datasampler
        train_sampler = None
        batch_size = self.hparams.batch_size
        try:
            if self.on_gpu:
                train_sampler = DistributedSampler(dataset, rank=self.trainer.proc_rank)
                batch_size = batch_size // self.trainer.world_size # scale batch size
        except Exception as e:
            pass
        should_shuffle = train_sampler is None
        loader = DataLoader(
            dataset=dataset,
            batch_size=batch_size,
            shuffle=should_shuffle,
            sampler=train_sampler
        )
        return loader

    @pl.data_loader
    def tng_dataloader(self):
        print('tng data loader called')
        return self.__dataloader(train=True)

    @pl.data_loader
    def val_dataloader(self):
        print('val data loader called')
        return self.__dataloader(train=False)

    @pl.data_loader
    def test_dataloader(self):
        print('test data loader called')
        return self.__dataloader(train=False)
I can make a new repo and upload my code if it is needed.
Expected behavior
Run correctly.
Screenshots
command line:

Environment:

OS: windows 10.0, 17134
conda version (no venv): conda 4.7.11
PyTorch version: 1.2.0
Lightning version: 0.4.6
Test-tube version: 0.6.9

Additional context
What have you tried:  I used print and found that it seemed to be something wrong around  loader = DataLoader( dataset=dataset, batch_size=batch_size, shuffle=should_shuffle, sampler=train_sampler ). And I found that val_dataloader and test_dataloader are also None when printing info about my class. However, I still don't know why.