Generate: skip left-padding tests on old models (#23437)
This commit is contained in:
@@ -1516,3 +1516,7 @@ class BartStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin, un
|
||||
|
||||
def test_save_load_fast_init_from_base(self):
|
||||
pass
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -811,3 +811,7 @@ class BigBirdPegasusStandaloneDecoderModelTest(ModelTesterMixin, GenerationTeste
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -561,3 +561,7 @@ class BlenderbotStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMix
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -566,3 +566,7 @@ class BlenderbotSmallStandaloneDecoderModelTest(ModelTesterMixin, GenerationTest
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -249,6 +249,10 @@ class CTRLModelTest(ModelTesterMixin, GenerationTesterMixin, PipelineTesterMixin
|
||||
model = CTRLModel.from_pretrained(model_name)
|
||||
self.assertIsNotNone(model)
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
|
||||
@require_torch
|
||||
class CTRLModelLanguageGenerationTest(unittest.TestCase):
|
||||
|
||||
@@ -520,6 +520,10 @@ class ImageGPTModelTest(ModelTesterMixin, GenerationTesterMixin, PipelineTesterM
|
||||
|
||||
self.assertTrue(models_equal)
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
|
||||
# We will verify our results on an image of cute cats
|
||||
def prepare_img():
|
||||
|
||||
@@ -862,3 +862,7 @@ class MarianStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin,
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -692,3 +692,7 @@ class MBartStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin, u
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -818,3 +818,7 @@ class MvpStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin, uni
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -573,3 +573,7 @@ class PegasusStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin,
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -658,3 +658,7 @@ class PLBartStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin,
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
@@ -1146,6 +1146,10 @@ class ProphetNetStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMix
|
||||
# decoder cannot keep gradients
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
|
||||
@require_torch
|
||||
class ProphetNetStandaloneEncoderModelTest(ModelTesterMixin, unittest.TestCase):
|
||||
|
||||
@@ -682,6 +682,10 @@ class ReformerLocalAttnModelTest(ReformerTesterMixin, GenerationTesterMixin, Mod
|
||||
[expected_shape] * len(iter_hidden_states),
|
||||
)
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
|
||||
@require_torch
|
||||
class ReformerLSHAttnModelTest(
|
||||
@@ -839,6 +843,10 @@ class ReformerLSHAttnModelTest(
|
||||
def test_past_key_values_format(self):
|
||||
pass
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
|
||||
@require_torch
|
||||
@require_sentencepiece
|
||||
|
||||
@@ -486,6 +486,10 @@ class TransfoXLModelTest(ModelTesterMixin, GenerationTesterMixin, PipelineTester
|
||||
weight = getattr(module, param)
|
||||
weight.data.fill_(3)
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
|
||||
@require_torch
|
||||
class TransfoXLModelLanguageGenerationTest(unittest.TestCase):
|
||||
|
||||
@@ -192,3 +192,7 @@ class TrOCRStandaloneDecoderModelTest(ModelTesterMixin, GenerationTesterMixin, P
|
||||
# decoder cannot keep gradients
|
||||
def test_retain_grad_hidden_states_attentions(self):
|
||||
return
|
||||
|
||||
@unittest.skip("The model doesn't support left padding") # and it's not used enough to be worth fixing :)
|
||||
def test_left_padding_compatibility(self):
|
||||
pass
|
||||
|
||||
Reference in New Issue
Block a user