Skip to content

Add Block Diffusion Attention Mask to attn_gym/masks #126

@Skylion007

Description

@Skylion007

Image
Implement the Block Diffusion Hybrid Attention Kernel from https://arxiv.org/abs/2503.09573 . Disclaimer I am an author. It's a simple, illustrative, and efficient kernel that can achieve >5X speedup over SDPA due to the sparsity of the mask. Therefore, probably a good example to highlight flex attention for performance reasons.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions