Skip to content
This repository was archived by the owner on Sep 9, 2025. It is now read-only.
This repository was archived by the owner on Sep 9, 2025. It is now read-only.

flash attention import error is getting masked #9

Description

@RobotSail

We still use the flash_attn_varlen_func even when we failed to import it so we get the following error:

[rank3]:     attn_output = flash_attn_varlen_func(
[rank3]:                   ^^^^^^^^^^^^^^^^^^^^^^
[rank3]: NameError: name 'flash_attn_varlen_func' is not defined

But this error usually arises as a fault of not being able to install flash attention for any reason. So when we cannot import flash attention, we should either avoid using this function or we should throw an error indicating why we can't import flash attention.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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