@@ -468,7 +468,7 @@ def test_actx_ravel(actx_factory):
468
468
actx = actx_factory ()
469
469
rng = default_rng ()
470
470
ndim = rng .integers (low = 1 , high = 6 )
471
- shape = tuple (rng .integers (2 , 7 , ndim ))
471
+ shape = tuple (rng .integers (2 , 8 , ndim ))
472
472
473
473
assert_close_to_numpy (actx , lambda _np , ary : _np .ravel (ary ),
474
474
(rng .random (shape ),))
@@ -715,7 +715,7 @@ def test_array_equal(actx_factory):
715
715
def test_array_context_einsum_array_manipulation (actx_factory , spec ):
716
716
actx = actx_factory ()
717
717
718
- mat = actx .from_numpy (np .random .randn (10 , 10 ))
718
+ mat = actx .from_numpy (np .random .randn (16 , 16 ))
719
719
res = actx .to_numpy (actx .einsum (spec , mat ,
720
720
tagged = (FirstAxisIsElementsTag ())))
721
721
ans = np .einsum (spec , actx .to_numpy (mat ))
@@ -730,8 +730,8 @@ def test_array_context_einsum_array_manipulation(actx_factory, spec):
730
730
def test_array_context_einsum_array_matmatprods (actx_factory , spec ):
731
731
actx = actx_factory ()
732
732
733
- mat_a = actx .from_numpy (np .random .randn (5 , 5 ))
734
- mat_b = actx .from_numpy (np .random .randn (5 , 5 ))
733
+ mat_a = actx .from_numpy (np .random .randn (16 , 16 ))
734
+ mat_b = actx .from_numpy (np .random .randn (16 , 16 ))
735
735
res = actx .to_numpy (actx .einsum (spec , mat_a , mat_b ,
736
736
tagged = (FirstAxisIsElementsTag ())))
737
737
ans = np .einsum (spec , actx .to_numpy (mat_a ), actx .to_numpy (mat_b ))
@@ -744,9 +744,9 @@ def test_array_context_einsum_array_matmatprods(actx_factory, spec):
744
744
def test_array_context_einsum_array_tripleprod (actx_factory , spec ):
745
745
actx = actx_factory ()
746
746
747
- mat_a = actx .from_numpy (np .random .randn (7 , 5 ))
748
- mat_b = actx .from_numpy (np .random .randn (5 , 7 ))
749
- vec = actx .from_numpy (np .random .randn (7 ))
747
+ mat_a = actx .from_numpy (np .random .randn (16 , 4 ))
748
+ mat_b = actx .from_numpy (np .random .randn (4 , 16 ))
749
+ vec = actx .from_numpy (np .random .randn (16 ))
750
750
res = actx .to_numpy (actx .einsum (spec , mat_a , mat_b , vec ,
751
751
tagged = (FirstAxisIsElementsTag ())))
752
752
ans = np .einsum (spec ,
@@ -1481,7 +1481,7 @@ def _twice(x):
1481
1481
1482
1482
actx = actx_factory ()
1483
1483
ones = actx .thaw (actx .freeze (
1484
- actx .zeros (shape = (10 , 4 ), dtype = np .float64 ) + 1
1484
+ actx .zeros (shape = (16 , 4 ), dtype = np .float64 ) + 1
1485
1485
))
1486
1486
np .testing .assert_allclose (actx .to_numpy (_twice (ones )),
1487
1487
actx .to_numpy (actx .compile (_twice )(ones )))
@@ -1572,11 +1572,11 @@ def test_compile_anonymous_function(actx_factory):
1572
1572
actx = actx_factory ()
1573
1573
f = actx .compile (lambda x : 2 * x + 40 )
1574
1574
np .testing .assert_allclose (
1575
- actx .to_numpy (f (1 + actx .zeros ((10 , 4 ), "float64" ))),
1575
+ actx .to_numpy (f (1 + actx .zeros ((16 , 4 ), "float64" ))),
1576
1576
42 )
1577
1577
f = actx .compile (partial (lambda x : 2 * x + 40 ))
1578
1578
np .testing .assert_allclose (
1579
- actx .to_numpy (f (1 + actx .zeros ((10 , 4 ), "float64" ))),
1579
+ actx .to_numpy (f (1 + actx .zeros ((16 , 4 ), "float64" ))),
1580
1580
42 )
1581
1581
1582
1582
0 commit comments