Latest updates break the code on Windows
Closed this issue · 3 comments
I was trying to add auto crop feature in WebUI and found the latest code is no longer working on Windows.
(anitalker) C:\temp\AniTalker>python ./code/demo.py --infer_type hubert_audio_only --stage1_checkpoint_path ckpts/stage1.ckpt --stage2_checkpoint_path ckpts/stage2_audio_only_hubert.ckpt --test_image_path test_demos/portraits/monalisa.jpg --test_audio_path test_demos/audios/monalisa.wav --test_hubert_path test_demos/audios_hubert/monalisa.npy --result_path outputs/monalisa_hubert/ --face_sr
Traceback (most recent call last):
File "C:\temp\AniTalker\code\demo.py", line 297, in <module>
if torch.backends.mps.is_available():
AttributeError: module 'torch.backends' has no attribute 'mps'
Oh, I apologize. I overlooked the possibility that the 'mps' package might not exist. This issue has been urgently fixed.
@liutaocode
No worries, I found the fix.
In earlier version of torch it 'mps' was not supported but running the following command works and no code changes required
pip install torch==1.13.1+cu116 torchvision==0.14.1+cu116 torchaudio==0.13.1+cu116 --index-url https://download.pytorch.org/whl/cu116
I am planning to create a new requirements_windows.txt so that the dependencies can be easily managed for Windows. I tried similar approach for another tool and it worked.
Give me some time and it should resolve this issue, also add windows WebUI with auto crop which is working and tested locally. I will need your help to test on Linux.
Pull request raise to fix this and several other updates.
#38