Skip test_multi_gpu_data_parallel_forward for UperNetModelTest (#21216)
fix Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
This commit is contained in:
@@ -20,7 +20,7 @@ import unittest
|
|||||||
|
|
||||||
from huggingface_hub import hf_hub_download
|
from huggingface_hub import hf_hub_download
|
||||||
from transformers import ConvNextConfig, UperNetConfig
|
from transformers import ConvNextConfig, UperNetConfig
|
||||||
from transformers.testing_utils import require_torch, require_vision, slow, torch_device
|
from transformers.testing_utils import require_torch, require_torch_multi_gpu, require_vision, slow, torch_device
|
||||||
from transformers.utils import is_torch_available, is_vision_available
|
from transformers.utils import is_torch_available, is_vision_available
|
||||||
|
|
||||||
from ...test_configuration_common import ConfigTester
|
from ...test_configuration_common import ConfigTester
|
||||||
@@ -199,6 +199,11 @@ class UperNetModelTest(ModelTesterMixin, unittest.TestCase):
|
|||||||
def test_save_load_fast_init_to_base(self):
|
def test_save_load_fast_init_to_base(self):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
@require_torch_multi_gpu
|
||||||
|
@unittest.skip(reason="UperNet has some layers using `add_module` which doesn't work well with `nn.DataParallel`")
|
||||||
|
def test_multi_gpu_data_parallel_forward(self):
|
||||||
|
pass
|
||||||
|
|
||||||
def test_hidden_states_output(self):
|
def test_hidden_states_output(self):
|
||||||
def check_hidden_states_output(inputs_dict, config, model_class):
|
def check_hidden_states_output(inputs_dict, config, model_class):
|
||||||
model = model_class(config)
|
model = model_class(config)
|
||||||
|
|||||||
Reference in New Issue
Block a user