Unverified Commit d853a010 authored by Muhammed Fatih BALIN's avatar Muhammed Fatih BALIN Committed by GitHub
Browse files

[GraphBolt] Enable `DistributedItemSampler` test only on CPU. (#7323)

parent 9a340c77
import os import os
import re import re
import unittest
from sys import platform from sys import platform
import backend as F
import dgl import dgl
import pytest import pytest
import torch import torch
import torch.distributed as dist import torch.distributed as dist
import torch.multiprocessing as mp import torch.multiprocessing as mp
from dgl import graphbolt as gb from dgl import graphbolt as gb
from torch.testing import assert_close
def test_ItemSampler_minibatcher(): def test_ItemSampler_minibatcher():
...@@ -1090,6 +1092,7 @@ def test_RangeCalculation(params): ...@@ -1090,6 +1092,7 @@ def test_RangeCalculation(params):
assert key == answer assert key == answer
@unittest.skipIf(F._default_context_str != "cpu", reason="GPU not required.")
@pytest.mark.parametrize("num_ids", [24, 30, 32, 34, 36]) @pytest.mark.parametrize("num_ids", [24, 30, 32, 34, 36])
@pytest.mark.parametrize("num_workers", [0, 2]) @pytest.mark.parametrize("num_workers", [0, 2])
@pytest.mark.parametrize("drop_last", [False, True]) @pytest.mark.parametrize("drop_last", [False, True])
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment