Skip to content

Commit bc61551

Browse files
committed
add protection
1 parent 003fa34 commit bc61551

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/diffusers/models/attention_dispatch.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2496,7 +2496,7 @@ def _templated_context_parallel_attention(
24962496

24972497
@_AttentionBackendRegistry.register(
24982498
AttentionBackendName.FLASH,
2499-
constraints=[_check_device, _check_qkv_dtype_bf16_or_fp16, _check_shape],
2499+
constraints=[_check_attn_mask_or_causal, _check_device, _check_qkv_dtype_bf16_or_fp16, _check_shape],
25002500
supports_context_parallel=True,
25012501
)
25022502
def _flash_attention(

0 commit comments

Comments
 (0)