[devops] add large-scale distributed test marker (#4452)

* [test] remove cpu marker

* [test] remove gpu marker

* [test] update pytest markers

* [ci] update unit test ci
This commit is contained in:
Hongxin Liu
2023-08-16 18:56:52 +08:00
committed by GitHub
parent 6ef33f75aa
commit 26e29d58f0
13 changed files with 81 additions and 125 deletions

View File

@@ -8,7 +8,6 @@ import pytest
from colossalai.context.config import Config
@pytest.mark.cpu
def test_load_config():
filename = Path(__file__).parent.joinpath('sample_config.py')
config = Config.from_file(filename)

View File

@@ -143,7 +143,6 @@ def run_dist(rank, world_size, port, backend, port_list, host):
reset_seeds()
@pytest.mark.cpu
@rerun_if_address_is_in_use()
def test_context():
"""

View File

@@ -5,11 +5,10 @@ import os
from pathlib import Path
import pytest
from torchvision import transforms, datasets
from torch.utils.data import DataLoader
from torchvision import datasets, transforms
@pytest.mark.cpu
def test_cifar10_dataset():
# build transform
transform_pipeline = [transforms.ToTensor()]

View File

@@ -53,7 +53,6 @@ def run_data_sampler(rank, world_size, port):
torch.cuda.empty_cache()
@pytest.mark.cpu
@rerun_if_address_is_in_use()
def test_data_sampler():
spawn(run_data_sampler, 4)

View File

@@ -64,7 +64,6 @@ def run_data_sampler(rank, world_size, port):
torch.cuda.empty_cache()
@pytest.mark.cpu
@rerun_if_address_is_in_use()
def test_data_sampler():
spawn(run_data_sampler, 4)

View File

@@ -40,7 +40,6 @@ def forward_inplace(x, weight):
return out
@pytest.mark.gpu
@clear_cache_before_run()
@parameterize("use_reentrant", [True, False])
@parameterize("cpu_offload", [True, False])