DocumentQuestionAnsweringPipeline only for fast ⚡ tokenizers (#22745)
* fix --------- Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
This commit is contained in:
@@ -246,20 +246,6 @@ class LayoutLMModelTest(ModelTesterMixin, PipelineTesterMixin, unittest.TestCase
|
||||
)
|
||||
fx_compatible = True
|
||||
|
||||
# TODO: Fix the failed tests
|
||||
def is_pipeline_test_to_skip(
|
||||
self, pipeline_test_casse_name, config_class, model_architecture, tokenizer_name, processor_name
|
||||
):
|
||||
if (
|
||||
pipeline_test_casse_name == "DocumentQuestionAnsweringPipelineTests"
|
||||
and tokenizer_name is not None
|
||||
and not tokenizer_name.endswith("Fast")
|
||||
):
|
||||
# This pipeline uses `sequence_ids()` which is only available for fast tokenizers.
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
def setUp(self):
|
||||
self.model_tester = LayoutLMModelTester(self)
|
||||
self.config_tester = ConfigTester(self, config_class=LayoutLMConfig, hidden_size=37)
|
||||
|
||||
Reference in New Issue
Block a user