Marian distill scripts + integration test (#6799)

This commit is contained in:
Sam Shleifer
2020-08-31 13:48:26 -04:00
committed by GitHub
parent 02d09c8fcc
commit 61b7ba93f5
4 changed files with 132 additions and 14 deletions

View File

@@ -114,7 +114,9 @@ class ExamplesTests(TestCasePlus):
--max_seq_length=128
""".split()
if torch.cuda.is_available():
testargs += ["--fp16", "--gpus=1"]
testargs += ["--gpus=1"]
if is_cuda_and_apex_avaliable():
testargs.append("--fp16")
with patch.object(sys, "argv", testargs):
result = run_pl_glue.main()