Skip to content

Commit

Permalink
Fix quality and repo consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
sgugger authored and elusenji committed Jun 12, 2022
1 parent b319e1e commit 7259ecf
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/source/en/serialization.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ Ready-made configurations include the following architectures:
- M2M100
- Marian
- mBART
- MobileBert
- MobileBERT
- OpenAI GPT-2
- PLBart
- RoBERTa
Expand Down
2 changes: 1 addition & 1 deletion src/transformers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1793,12 +1793,12 @@
"TFAutoModelForImageClassification",
"TFAutoModelForMaskedLM",
"TFAutoModelForMultipleChoice",
"TFAutoModelForNextSentencePrediction",
"TFAutoModelForPreTraining",
"TFAutoModelForQuestionAnswering",
"TFAutoModelForSeq2SeqLM",
"TFAutoModelForSequenceClassification",
"TFAutoModelForSpeechSeq2Seq",
"TFAutoModelForNextSentencePrediction",
"TFAutoModelForTableQuestionAnswering",
"TFAutoModelForTokenClassification",
"TFAutoModelForVision2Seq",
Expand Down
2 changes: 1 addition & 1 deletion src/transformers/models/auto/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,12 +103,12 @@
"TFAutoModelForImageClassification",
"TFAutoModelForMaskedLM",
"TFAutoModelForMultipleChoice",
"TFAutoModelForNextSentencePrediction",
"TFAutoModelForPreTraining",
"TFAutoModelForQuestionAnswering",
"TFAutoModelForSeq2SeqLM",
"TFAutoModelForSequenceClassification",
"TFAutoModelForSpeechSeq2Seq",
"TFAutoModelForNextSentencePrediction",
"TFAutoModelForTableQuestionAnswering",
"TFAutoModelForTokenClassification",
"TFAutoModelForVision2Seq",
Expand Down
7 changes: 7 additions & 0 deletions src/transformers/utils/dummy_tf_objects.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,13 @@ def __init__(self, *args, **kwargs):
requires_backends(self, ["tf"])


class TFAutoModelForNextSentencePrediction(metaclass=DummyObject):
_backends = ["tf"]

def __init__(self, *args, **kwargs):
requires_backends(self, ["tf"])


class TFAutoModelForPreTraining(metaclass=DummyObject):
_backends = ["tf"]

Expand Down

0 comments on commit 7259ecf

Please sign in to comment.