Fix some typos. (#17560)
* Fix some typos. Signed-off-by: Yulv-git <yulvchi@qq.com> * Fix typo. Signed-off-by: Yulv-git <yulvchi@qq.com> * make fixup.
This commit is contained in:
@@ -2183,7 +2183,9 @@ class LayoutLMv2TokenizationTest(TokenizerTesterMixin, unittest.TestCase):
|
||||
sequence = tokenizer(seq_0, boxes=boxes_0, add_special_tokens=False)
|
||||
total_length = len(sequence["input_ids"])
|
||||
|
||||
self.assertGreater(total_length, 4, "Issue with the testing sequence, please update it it's too short")
|
||||
self.assertGreater(
|
||||
total_length, 4, "Issue with the testing sequence, please update it, it's too short"
|
||||
)
|
||||
|
||||
# Test with max model input length
|
||||
model_max_length = tokenizer.model_max_length
|
||||
@@ -2193,7 +2195,9 @@ class LayoutLMv2TokenizationTest(TokenizerTesterMixin, unittest.TestCase):
|
||||
sequence1 = tokenizer(seq_1, boxes=boxes_1, add_special_tokens=False)
|
||||
total_length1 = len(sequence1["input_ids"])
|
||||
self.assertGreater(
|
||||
total_length1, model_max_length, "Issue with the testing sequence, please update it it's too short"
|
||||
total_length1,
|
||||
model_max_length,
|
||||
"Issue with the testing sequence, please update it, it's too short",
|
||||
)
|
||||
|
||||
# Simple
|
||||
|
||||
@@ -2097,7 +2097,9 @@ class LayoutLMv3TokenizationTest(TokenizerTesterMixin, unittest.TestCase):
|
||||
sequence = tokenizer(seq_0, boxes=boxes_0, add_special_tokens=False)
|
||||
total_length = len(sequence["input_ids"])
|
||||
|
||||
self.assertGreater(total_length, 4, "Issue with the testing sequence, please update it it's too short")
|
||||
self.assertGreater(
|
||||
total_length, 4, "Issue with the testing sequence, please update it, it's too short"
|
||||
)
|
||||
|
||||
# Test with max model input length
|
||||
model_max_length = tokenizer.model_max_length
|
||||
@@ -2107,7 +2109,9 @@ class LayoutLMv3TokenizationTest(TokenizerTesterMixin, unittest.TestCase):
|
||||
sequence1 = tokenizer(seq_1, boxes=boxes_1, add_special_tokens=False)
|
||||
total_length1 = len(sequence1["input_ids"])
|
||||
self.assertGreater(
|
||||
total_length1, model_max_length, "Issue with the testing sequence, please update it it's too short"
|
||||
total_length1,
|
||||
model_max_length,
|
||||
"Issue with the testing sequence, please update it, it's too short",
|
||||
)
|
||||
|
||||
# Simple
|
||||
|
||||
@@ -281,7 +281,7 @@ class TFViTMAEModelTest(TFModelTesterMixin, unittest.TestCase):
|
||||
super().check_pt_tf_models(tf_model, pt_model, tf_inputs_dict)
|
||||
|
||||
# overwrite from common since TFViTMAEForPretraining outputs loss along with
|
||||
# logits and mask indices. loss and mask indicies are not suitable for integration
|
||||
# logits and mask indices. loss and mask indices are not suitable for integration
|
||||
# with other keras modules.
|
||||
def test_compile_tf_model(self):
|
||||
config, inputs_dict = self.model_tester.prepare_config_and_inputs_for_common()
|
||||
|
||||
Reference in New Issue
Block a user