Repository: huggingface/transformers
Pull request: add expectations for xpu for olmo_hybrid model

@IlyasMoutawwakil , pls help review, thx!

Changed files:
filename: tests/models/olmo_hybrid/test_modeling_olmo_hybrid.py
patch: @@ -179,7 +179,19 @@ def test_model_logits(self):
                         -4.722480773925781,
                         -4.015453338623047,
                     ]
-                ]
+                ],
+                ("xpu", 3): [
+                    [
+                        -3.799433145904541,
+                        -3.799685734939575,
+                        -2.977006951522827,
+                        -2.7950011024475098,
+                        -3.529636131668091,
+                        -4.018356552886963,
+                        -4.717680773925781,
+                        -3.985853338623047,
+                    ]
+                ],
             }
         )
         EXPECTED_MEAN = torch.tensor(expectations.get_expectation(), device=torch_device)
@@ -218,7 +230,39 @@ def test_model_logits(self):
                     -4.03125,
                     1.2421875,
                     -1.1328125,
-                ]
+                ],
+                ("xpu", 3): [
+                    3.8125,
+                    -0.5391,
+                    -1.7266,
+                    -2.1875,
+                    -2.2344,
+                    -2.8750,
+                    -0.8477,
+                    -1.2266,
+                    -1.6172,
+                    -2.75,
+                    -1.2656,
+                    0.8516,
+                    -2.5469,
+                    0.8281,
+                    -2.1562,
+                    2.9062,
+                    3.6719,
+                    3.5625,
+                    3.1250,
+                    2.7812,
+                    2.7031,
+                    1.7578,
+                    1.9141,
+                    2.2188,
+                    1.8984,
+                    -2.4844,
+                    -2.0156,
+                    -4.0000,
+                    1.2344,
+                    -1.1250,
+                ],
             }
         )
         EXPECTED_SLICE = torch.tensor(expectations.get_expectation(), device=torch_device)
@@ -232,6 +276,10 @@ def test_model_greedy_generation(self):
                     "cuda",
                     8,
                 ): "Simply put, the theory of relativity states that \xa0the laws of physics are the same for all non-accelerating observers. This means that the laws of physics are the same for all observers, regardless of their relative motion or the strength of the gravitational field they are in. This theory was first proposed by Albert Einstein in 1905 and has since been confirmed",
+                (
+                    "xpu",
+                    3,
+                ): "Simply put, the theory of relativity states that \xa0the laws of physics are the same for all non-accelerating observers. This means that the laws of physics are the same for all observers, regardless of their relative motion or the strength of the gravitational field they are in. This theory was first proposed by Albert Einstein in 1905 and has since been confirmed",
             }
         )
         EXPECTED_TEXT_COMPLETION = expectations.get_expectation()