Unverified Commit 5ce90f32 authored by Titus's avatar Titus Committed by GitHub
Browse files

Bnb test fix for different hardwares (#29066)



* generated text on A10G

* generated text in CI

* Apply suggestions from code review

add explanatory comments
Co-authored-by: default avatarYounes Belkada <49240599+younesbelkada@users.noreply.github.com>

---------
Co-authored-by: default avatarYounes Belkada <49240599+younesbelkada@users.noreply.github.com>
parent 08cd694e
......@@ -97,6 +97,8 @@ class BaseMixedInt8Test(unittest.TestCase):
input_text = "Hello my name is"
EXPECTED_OUTPUTS = set()
EXPECTED_OUTPUTS.add("Hello my name is John.\nI am a friend of the family.\n")
# Expected values on a A10
EXPECTED_OUTPUTS.add("Hello my name is John.\nI am a friend of your father.\n")
MAX_NEW_TOKENS = 10
def setUp(self):
......@@ -847,6 +849,8 @@ class MixedInt8GPT2Test(MixedInt8Test):
EXPECTED_OUTPUTS = set()
EXPECTED_OUTPUTS.add("Hello my name is John Doe, and I'm a big fan of")
EXPECTED_OUTPUTS.add("Hello my name is John Doe, and I'm a fan of the")
# Expected values on a A10
EXPECTED_OUTPUTS.add("Hello my name is John Doe, and I am a member of the")
def test_int8_from_pretrained(self):
r"""
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment