MCPcopy Create free account
hub / github.com/dask/dask / test_array_function_cupy_svd

Function test_array_function_cupy_svd

dask/array/tests/test_array_function.py:130–141  ·  view source on GitHub ↗
(chunks)

Source from the content-addressed store, hash-verified

128
129@pytest.mark.parametrize("chunks", [(100, 100), (500, 100)])
130def test_array_function_cupy_svd(chunks):
131 cupy = pytest.importorskip("cupy")
132 x = cupy.random.default_rng().random((500, 100))
133
134 y = da.from_array(x, chunks=chunks, asarray=False)
135
136 u_base, s_base, v_base = da.linalg.svd(y)
137 u, s, v = np.linalg.svd(y)
138
139 assert_eq(u, u_base)
140 assert_eq(s, s_base)
141 assert_eq(v, v_base)
142
143
144@pytest.mark.parametrize(

Callers

nothing calls this directly

Calls 2

assert_eqFunction · 0.90
randomMethod · 0.45

Tested by

no test coverage detected