Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
a5d18396
Unverified
Commit
a5d18396
authored
May 16, 2022
by
lewtun
Committed by
GitHub
May 16, 2022
Browse files
Remove next sentence prediction from supported ONNX tasks (#17276)
parent
05a90579
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
6 deletions
+0
-6
src/transformers/onnx/features.py
src/transformers/onnx/features.py
+0
-6
No files found.
src/transformers/onnx/features.py
View file @
a5d18396
...
...
@@ -45,7 +45,6 @@ if is_torch_available():
AutoModelForMaskedImageModeling
,
AutoModelForMaskedLM
,
AutoModelForMultipleChoice
,
AutoModelForNextSentencePrediction
,
AutoModelForQuestionAnswering
,
AutoModelForSeq2SeqLM
,
AutoModelForSequenceClassification
,
...
...
@@ -57,7 +56,6 @@ if is_tf_available():
TFAutoModelForCausalLM
,
TFAutoModelForMaskedLM
,
TFAutoModelForMultipleChoice
,
TFAutoModelForNextSentencePrediction
,
TFAutoModelForQuestionAnswering
,
TFAutoModelForSeq2SeqLM
,
TFAutoModelForSequenceClassification
,
...
...
@@ -112,7 +110,6 @@ class FeaturesManager:
"question-answering"
:
AutoModelForQuestionAnswering
,
"image-classification"
:
AutoModelForImageClassification
,
"masked-im"
:
AutoModelForMaskedImageModeling
,
"next-sentence-prediction"
:
AutoModelForNextSentencePrediction
,
}
if
is_tf_available
():
_TASKS_TO_TF_AUTOMODELS
=
{
...
...
@@ -124,7 +121,6 @@ class FeaturesManager:
"token-classification"
:
TFAutoModelForTokenClassification
,
"multiple-choice"
:
TFAutoModelForMultipleChoice
,
"question-answering"
:
TFAutoModelForQuestionAnswering
,
"next-sentence-prediction"
:
TFAutoModelForNextSentencePrediction
,
}
# Set of model topologies we support associated to the features supported by each topology and the factory
...
...
@@ -159,7 +155,6 @@ class FeaturesManager:
"multiple-choice"
,
"token-classification"
,
"question-answering"
,
"next-sentence-prediction"
,
onnx_config_cls
=
BertOnnxConfig
,
),
"big-bird"
:
supported_features_mapping
(
...
...
@@ -326,7 +321,6 @@ class FeaturesManager:
"mobilebert"
:
supported_features_mapping
(
"default"
,
"masked-lm"
,
"next-sentence-prediction"
,
"sequence-classification"
,
"multiple-choice"
,
"token-classification"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment