Unverified Commit 6739e1d2 authored by Poedator's avatar Poedator Committed by GitHub
Browse files

test_custom_4d_attention_mask skip with sliding window attn (#30833)

parent 87a35181
...@@ -4407,6 +4407,8 @@ class ModelTesterMixin: ...@@ -4407,6 +4407,8 @@ class ModelTesterMixin:
if not model_class._supports_static_cache: if not model_class._supports_static_cache:
self.skipTest(f"{model_class.__name__} is not guaranteed to work with custom 4D attention masks") self.skipTest(f"{model_class.__name__} is not guaranteed to work with custom 4D attention masks")
config, _ = self.model_tester.prepare_config_and_inputs_for_common() config, _ = self.model_tester.prepare_config_and_inputs_for_common()
if getattr(config, "sliding_window", 0) > 0:
self.skipTest(f"{model_class.__name__} with sliding window attention is not supported by this test")
model = model_class(config).to(device=torch_device, dtype=torch.float32) model = model_class(config).to(device=torch_device, dtype=torch.float32)
( (
......
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