CivArchive
    ← All articles
    Published October 19, 2023by impactframes

    FIX A1111 Xformers and py Torch issues

    825 views2 reactions2 comments on CivitAI7 collected
    installationxformersa1111tool guidetorchissues

    This is for ppl with Nvdia GPUs

    I made this video for people having issues after installing a new extension or getting their A1111 venv messup somehow

    here is the essential it works on V1.6 as it requires this specific version of torch xformers

    This only works on current A1111 v1.6

    if none of this work you wiil need to delete the venv and run webui-user.bat to reinstall A1111

    linux

    cd ~/stable-diffusion-webui

    source ./venv/bin/activate

    pip uninstall torch torchvision torchaudio

    pip uninstall xformers

    pip install torch==2.0.1+cu118 torchvision==0.15.2+cu118 torchaudio==2.0.2 --index-url https://download.pytorch.org/whl/cu118

    pip install xformers==0.0.21

    win terminal

    cd ./venv/scripts

    ./activate

    pip uninstall torch torchvision torchaudio

    pip uninstall xformers

    pip install torch==2.0.1+cu118 torchvision==0.15.2+cu118 torchaudio==2.0.2 --index-url https://download.pytorch.org/whl/cu118

    pip install xformers==0.0.21

    win cmd

    cd ./venv/scripts

    activate

    pip uninstall torch torchvision torchaudio

    pip uninstall xformers

    pip install torch==2.0.1+cu118 torchvision==0.15.2+cu118 torchaudio==2.0.2 --index-url https://download.pytorch.org/whl/cu118

    pip install xformers==0.0.21

    Not super sure but for MacOS try:

    cd venv/Scripts

    activate

    pip uninstall torch torchvision torchaudio

    pip uninstall xformers

    pip install torch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2

    pip install xformers==0.0.21

    --This is only a guess for a future version of A1111 greater than 1.6 supposing the latest torch would work---

    To future proof possibly this will work by changing the cuda to the version of cuda you have and it will install the latest components of torch and xformers in this case I use cuda12.1

    pip uninstall torch torchvision torchaudio

    pip uninstall xformers

    pip install --force-reinstall torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121

    Also the future

    pip uninstall xformers

    pip install --force-reinstall --no-deps --pre xformers