diff --git a/dpnp/linalg/dpnp_utils_linalg.py b/dpnp/linalg/dpnp_utils_linalg.py index f105cff5a6c2..1a2ac0c99f57 100644 --- a/dpnp/linalg/dpnp_utils_linalg.py +++ b/dpnp/linalg/dpnp_utils_linalg.py @@ -449,6 +449,7 @@ def _batched_qr(a, mode="reduced"): a_t, shape=(batch_size, m, m), dtype=res_type, + order="C", ) else: mc = k @@ -456,6 +457,7 @@ def _batched_qr(a, mode="reduced"): a_t, shape=(batch_size, n, m), dtype=res_type, + order="C", ) # use DPCTL tensor function to fill the matrix array `q[..., :n, :]` @@ -2532,6 +2534,7 @@ def dpnp_qr(a, mode="reduced"): a_t, shape=(m, m), dtype=res_type, + order="C", ) else: mc = k @@ -2539,6 +2542,7 @@ def dpnp_qr(a, mode="reduced"): a_t, shape=(n, m), dtype=res_type, + order="C", ) # use DPCTL tensor function to fill the matrix array `q[:n]` diff --git a/dpnp/tests/test_linalg.py b/dpnp/tests/test_linalg.py index 50482b929aec..891bc8e1887b 100644 --- a/dpnp/tests/test_linalg.py +++ b/dpnp/tests/test_linalg.py @@ -2372,12 +2372,24 @@ class TestQr: @pytest.mark.parametrize("dtype", get_all_dtypes(no_bool=True)) @pytest.mark.parametrize( "shape", - [(2, 2), (3, 4), (5, 3), (16, 16), (2, 2, 2), (2, 4, 2), (2, 2, 4)], + [ + (2, 1), + (2, 2), + (3, 4), + (5, 3), + (16, 16), + (3, 3, 1), + (2, 2, 2), + (2, 4, 2), + (2, 2, 4), + ], ids=[ + "(2, 1)", "(2, 2)", "(3, 4)", "(5, 3)", "(16, 16)", + "(3, 3, 1)", "(2, 2, 2)", "(2, 4, 2)", "(2, 2, 4)",