[cleanup] assign todos, faster bart-cnn test (#7835)

* 2 beam output

* unassign/remove TODOs

* remove one more
This commit is contained in:
Sam Shleifer
2020-10-16 03:11:18 -04:00
committed by GitHub
parent 7b13bd01df
commit 96e47d9229
8 changed files with 29 additions and 54 deletions

File diff suppressed because one or more lines are too long

View File

@@ -125,12 +125,9 @@ class FSMTModelTest(ModelTesterMixin, unittest.TestCase):
all_model_classes = (FSMTModel, FSMTForConditionalGeneration) if is_torch_available() else ()
all_generative_model_classes = (FSMTForConditionalGeneration,) if is_torch_available() else ()
is_encoder_decoder = True
# TODO(SS): fix the below in a separate PR
test_pruning = False
test_torchscript = True
test_head_masking = False
test_resize_embeddings = True # This requires inputs_dict['input_ids']
test_missing_keys = False # because FSMTForConditionalGeneration and FSMTModel now have identical state_dict
test_missing_keys = False
def setUp(self):
self.model_tester = ModelTester(self)
@@ -326,7 +323,6 @@ class FSMTHeadTests(unittest.TestCase):
max_length=max_length,
)
self.assertEqual(new_input_ids.shape, (input_ids.shape[0], max_length))
# TODO(SS): uneven length batches, empty inputs
def test_shift_tokens_right(self):
input_ids = torch.Tensor([[71, 82, 18, 33, 2, 1, 1], [68, 34, 26, 58, 30, 82, 2]]).long()