AttributeError when using None field value in torchtext with GPU
🐛 Bug

Hello,
I'm trying to do some NLP model with lightning and torchtext,
and I found the error when I use field with None field value in torchtext's Iterator with GPU.
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-11-bd904d609559> in <module>()
----> 1 test_x(tmpdir)  # works when using no gpu

15 frames
/usr/local/lib/python3.6/dist-packages/pytorch_lightning/utilities/apply_func.py in batch_to(data)
    115             device_data = copy(data)
    116             for field in data.fields:
--> 117                 device_field = move_data_to_device(getattr(data, field), device)
    118                 setattr(device_data, field, device_field)
    119             return device_data

AttributeError: 'Batch' object has no attribute 'TITLE'

To Reproduce

I reproduced it with simple model and task.
https://colab.research.google.com/drive/1YVbfCEcV3sirHZUa1wX7BU4O3heoV6Pn?usp=sharing
Expected behavior
I'm not sure it is error or not,
I think field with None field value should not pass to move_data_to_device when using GPU.

Environment
Google Colab Pro

CUDA:

GPU:

Tesla V100-SXM2-16GB


available:         True
version:           10.1


Packages:

numpy:             1.18.5
pyTorch_debug:     True
pyTorch_version:   1.7.0+cu101
pytorch-lightning: 1.0.7
tqdm:              4.41.1


System:

OS:                Linux
architecture:

64bit



processor:         x86_64
python:            3.6.9
version:           #1 SMP Thu Jul 23 08:00:38 PDT 2020