Closed
Description
🐛 Bug
Information
Can't run forward in PyTorch 1.5.0, works fine in 1.4.0
Model I am using (Bert, XLNet ...): XLNet
Language I am using the model on (English, Chinese ...): English
The problem arises when using:
- the official example scripts: (give details below)
- my own modified scripts: (give details below)
Transformer + custom head + custom losses + differential learning rates, I don't think it matters.
The tasks I am working on is:
- an official GLUE/SQUaD task: (give the name)
- my own task or dataset: (give details below)
Custom news classification
To reproduce
Steps to reproduce the behavior:
- Install PyTorch 1.5.0
- Run forward on xlnet
File "transformers/modeling_xlnet.py", line 761, in forward
dtype_float = next(self.parameters()).dtype
StopIteration
Expected behavior
Runs forward
Environment info
transformersversion: 2.8.0- Platform: Ubuntu 18.04
- Python version: Anaconda 3.7
- PyTorch version (GPU?): 1.5, Yes
- Tensorflow version (GPU?): N/A
- Using GPU in script?: Yes
- Using distributed or parallel set-up in script?: Yes