hpcaitech / Open-Sora

Open-Sora: Democratizing Efficient Video Production for All
https://hpcaitech.github.io/Open-Sora/
Apache License 2.0
22.29k stars 2.18k forks source link

BlockDiagonalMask import error #684

Closed yja1 closed 2 months ago

yja1 commented 2 months ago

in block.py 476 line module 'xformers.ops.fmha' has no attribute 'BlockDiagonalMask' use rocm/xformers

github-actions[bot] commented 2 months ago

This issue is stale because it has been open for 7 days with no activity.

github-actions[bot] commented 2 months ago

This issue was closed because it has been inactive for 7 days since being marked as stale.

tobiaswuerth commented 3 weeks ago

I experienced the same issue. I think it had to do with the wrong version. I had torch+cu124 installed and xformers==0.0.28 something.

python.exe -m pip uninstall xformers torch torchvision torchaudio
python.exe -m pip install xformers torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121

solved it for me.

Now I have:

xformers==0.0.27.post2
torch==2.4.0+cu121
torchvision==0.19.0+cu121
torchaudio==2.4.0+cu121