Switch return_dict to True by default. (#8530)
* Use the CI to identify failing tests * Remove from all examples and tests * More default switch * Fixes * More test fixes * More fixes * Last fixes hopefully * Use the CI to identify failing tests * Remove from all examples and tests * More default switch * Fixes * More test fixes * More fixes * Last fixes hopefully * Run on the real suite * Fix slow tests
This commit is contained in:
@@ -39,7 +39,7 @@ head on top of the encoder with an output size of 2. Models are initialized in `
|
||||
.. code-block:: python
|
||||
|
||||
from transformers import BertForSequenceClassification
|
||||
model = BertForSequenceClassification.from_pretrained('bert-base-uncased', return_dict=True)
|
||||
model = BertForSequenceClassification.from_pretrained('bert-base-uncased')
|
||||
model.train()
|
||||
|
||||
This is useful because it allows us to make use of the pre-trained BERT encoder and easily train it on whatever
|
||||
|
||||
Reference in New Issue
Block a user