Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: make build PEP 517 compatible #955

Closed
wjn0 opened this issue May 14, 2024 · 3 comments
Closed

Feature request: make build PEP 517 compatible #955

wjn0 opened this issue May 14, 2024 · 3 comments

Comments

@wjn0
Copy link

wjn0 commented May 14, 2024

I tried to run:

$ pip wheel --no-cache-dir --use-pep517 "flash-attn (==2.5.8)"

and this failed with

ModuleNotFoundError: No module named 'packaging'

Is there anything in the build process preventing compatibility with PEP 517 (which prevents the use of dependency managers like Poetry which are quite helpful)?

@wjn0
Copy link
Author

wjn0 commented May 14, 2024

Duplicate of #927. But I did want to share this workaround for Poetry users (namely, use the GitHub wheel release). Tailor your CUDA, PyTorch, and CPython version accordingly of course:

poetry add "flash-attn @ https://github.com/Dao-AILab/flash-attention/releases/download/v2.5.8/flash_attn-2.5.8+cu122torch2.3cxx11abiFALSE-cp310-cp310-linux_x86_64.whl"

@tridao
Copy link
Contributor

tridao commented May 14, 2024

I haven't found a satisfactory way to make it PEP 517 compatible. If we include pytorch in the setup requirements, it might download a different pytorch version than what users already have, just to build the extension. This can make installation very slow for some users.

@wjn0
Copy link
Author

wjn0 commented May 15, 2024

Yeah, that makes sense. I appreciate your response! Thanks for a great package. I'll close this as a dup of #927 for now.

@wjn0 wjn0 closed this as completed May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants