(self)
| 431 | self.assertTrue(np.array_equal(x, xnp)) |
| 432 | |
| 433 | def test_double_keeps_precision(self): |
| 434 | x = 39.14223403241 |
| 435 | out = mx.array(x, dtype=mx.float64).item() |
| 436 | self.assertEqual(out, x) |
| 437 | |
| 438 | out = mx.array([x], dtype=mx.float64).item() |
| 439 | self.assertEqual(out, x) |
| 440 | |
| 441 | def test_construction_from_lists_of_mlx_arrays(self): |
| 442 | dtypes = [ |