Skip to content

Commit

Permalink
update xformers for updated pytorch version
Browse files Browse the repository at this point in the history
  • Loading branch information
winglian committed Oct 9, 2024
1 parent 7046d8a commit a508c8c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ flash-attn==2.6.3
sentencepiece
wandb
einops
xformers==0.0.27
xformers==0.0.28.post1
optimum==1.16.2
hf_transfer
colorama
Expand Down
4 changes: 4 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ def parse_requirements():
else:
raise ValueError("Invalid version format")

if (major, minor) >= (2, 4):
if patch == 0:
_install_requires.pop(_install_requires.index(xformers_version))
_install_requires.append("xformers>=0.0.27")
if (major, minor) >= (2, 3):
if patch == 0:
_install_requires.pop(_install_requires.index(xformers_version))
Expand Down

0 comments on commit a508c8c

Please sign in to comment.