Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions dpnp/tests/helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,14 @@ def is_arl_or_mtl(device=None):
return _get_dev_mask(device) == 0x7D00


def is_bmg(device=None):
"""
Return True if a test is running on Arc Battlemage (B-Series) GPU device,
False otherwise.
"""
return _get_dev_mask(device) == 0xE200


def is_cpu_device(device=None):
"""
Return True if a test is running on CPU device, False otherwise.
Expand Down
29 changes: 29 additions & 0 deletions dpnp/tests/test_histogram.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import dpnp

from .helper import (
LTS_VERSION,
assert_dtype_allclose,
generate_random_numpy_array,
get_abs_array,
Expand All @@ -21,6 +22,10 @@
get_integer_dtypes,
get_integer_float_dtypes,
has_support_aspect64,
is_bmg,
is_lnl,
is_lts_driver,
is_win_platform,
numpy_version,
)
from .third_party.cupy import testing
Expand Down Expand Up @@ -487,6 +492,12 @@ def test_weights_another_sycl_queue(self):
with assert_raises(ValueError):
dpnp.histogram(v, weights=w)

@pytest.mark.skipif(
not is_win_platform()
and not is_lts_driver(version=LTS_VERSION.V1_6)
and (is_lnl() or is_bmg()),
reason="SAT-8135",
)
@pytest.mark.parametrize(
"bins_count",
[10, 10**2, 10**3, 10**4, 10**5, 10**6],
Expand Down Expand Up @@ -585,6 +596,12 @@ def test_weights_unsupported_dtype(self, xp, dt):
w = xp.arange(5, dtype=dt)
assert_raises((TypeError, ValueError), xp.bincount, v, weights=w)

@pytest.mark.skipif(
not is_win_platform()
and not is_lts_driver(version=LTS_VERSION.V1_6)
and (is_lnl() or is_bmg()),
reason="SAT-8135",
)
@pytest.mark.parametrize(
"bins_count",
[10, 10**2, 10**3, 10**4, 10**5, 10**6],
Expand Down Expand Up @@ -851,6 +868,12 @@ def test_weights_another_sycl_queue(self):
with assert_raises(ValueError):
dpnp.histogramdd(v, weights=w)

@pytest.mark.skipif(
not is_win_platform()
and not is_lts_driver(version=LTS_VERSION.V1_6)
and (is_lnl() or is_bmg()),
reason="SAT-8135",
)
@pytest.mark.parametrize(
"bins_count",
[10, 10**2, 10**3, 10**4, 10**5, 10**6],
Expand Down Expand Up @@ -1092,6 +1115,12 @@ def test_size_mismatch(self, xp):
y = xp.linspace(0.0, 1.0, num=20)
assert_raises(ValueError, xp.histogram2d, x, y)

@pytest.mark.skipif(
not is_win_platform()
and not is_lts_driver(version=LTS_VERSION.V1_6)
and (is_lnl() or is_bmg()),
reason="SAT-8135",
)
@pytest.mark.parametrize(
"bins_count",
[10, 10**2, 10**3],
Expand Down
Loading