Skip to content

Commit 2156619

Browse files
authored
Add TFAutoModelForSemanticSegmentation to the main __init__.py (#18600)
Co-authored-by: ydshieh <[email protected]>
1 parent 4eed2be commit 2156619

File tree

4 files changed

+15
-0
lines changed

4 files changed

+15
-0
lines changed

docs/source/en/model_doc/auto.mdx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,10 @@ Likewise, if your `NewModel` is a subclass of [`PreTrainedModel`], make sure its
186186

187187
[[autodoc]] TFAutoModelForImageClassification
188188

189+
## TFAutoModelForSemanticSegmentation
190+
191+
[[autodoc]] TFAutoModelForSemanticSegmentation
192+
189193
## TFAutoModelForMaskedLM
190194

191195
[[autodoc]] TFAutoModelForMaskedLM

src/transformers/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2105,6 +2105,7 @@
21052105
"TFAutoModelForNextSentencePrediction",
21062106
"TFAutoModelForPreTraining",
21072107
"TFAutoModelForQuestionAnswering",
2108+
"TFAutoModelForSemanticSegmentation",
21082109
"TFAutoModelForSeq2SeqLM",
21092110
"TFAutoModelForSequenceClassification",
21102111
"TFAutoModelForSpeechSeq2Seq",
@@ -4599,6 +4600,7 @@
45994600
TFAutoModelForNextSentencePrediction,
46004601
TFAutoModelForPreTraining,
46014602
TFAutoModelForQuestionAnswering,
4603+
TFAutoModelForSemanticSegmentation,
46024604
TFAutoModelForSeq2SeqLM,
46034605
TFAutoModelForSequenceClassification,
46044606
TFAutoModelForSpeechSeq2Seq,

src/transformers/models/auto/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,7 @@
128128
"TFAutoModelForNextSentencePrediction",
129129
"TFAutoModelForPreTraining",
130130
"TFAutoModelForQuestionAnswering",
131+
"TFAutoModelForSemanticSegmentation",
131132
"TFAutoModelForSeq2SeqLM",
132133
"TFAutoModelForSequenceClassification",
133134
"TFAutoModelForSpeechSeq2Seq",
@@ -271,6 +272,7 @@
271272
TFAutoModelForNextSentencePrediction,
272273
TFAutoModelForPreTraining,
273274
TFAutoModelForQuestionAnswering,
275+
TFAutoModelForSemanticSegmentation,
274276
TFAutoModelForSeq2SeqLM,
275277
TFAutoModelForSequenceClassification,
276278
TFAutoModelForSpeechSeq2Seq,

src/transformers/utils/dummy_tf_objects.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -362,6 +362,13 @@ def __init__(self, *args, **kwargs):
362362
requires_backends(self, ["tf"])
363363

364364

365+
class TFAutoModelForSemanticSegmentation(metaclass=DummyObject):
366+
_backends = ["tf"]
367+
368+
def __init__(self, *args, **kwargs):
369+
requires_backends(self, ["tf"])
370+
371+
365372
class TFAutoModelForSeq2SeqLM(metaclass=DummyObject):
366373
_backends = ["tf"]
367374

0 commit comments

Comments
 (0)