How to Run RVC WebUI on RTX 50-Series GPUs (Python 3.10 + PyTorch 2.7)

How to Run RVC WebUI on RTX 50-Series GPUs (Python 3.10 + PyTorch 2.7)

A step-by-step setup guide for installing Retrieval-based Voice Conversion WebUI (RVC WebUI) on machines with NVIDIA RTX 50-series GPUs.

I originally had this issue with RTX 5080 and fixed it via a useful github post & trial and error with using ChatGPT etc after spending several days trying to fix. It’s worth noting that the first install of following this didn’t work for me. Also worth noting, although sometimes it states an error on the GUI, it is in fact running. Always check the terminal. Even if the application says ‘Error’, it is sometimes a GUI error and not a terminal error.

I tried multiple times with different pytorch installs and nightly builds but always ran into more and more issues. Below seems to be the most consistant way of getting it to work.

Credit to: https://github.com/quasiblob

Credit to ChatGPT for doing a lot of the leg work on troubleshooting.


Important Notes

  • These instructions are only for RTX 50-series GPUs
  • Assumes usage of Python 3.10.x
  • Uses a venv virtual environment
  • Some steps may need manual tweaks due to evolving dependencies
  • Core WebUI features appear to work:
    • ✅ Inference tab
    • ✅ Training tab
    • ✅ Checkpoint tab
    • ✅ ONNX export (without simplify)

Installation Steps

1. Clone the Repository

git clone https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI RVC_webUI
cd RVC_webUI

2. Create and Activate Virtual Environment (Python 3.10)

py -3.10 -m venv venv
call ./venv/Scripts/activate.bat

3. Update Pip

python.exe -m pip install pip==24.0

4. Install Requirements

pip install -r requirements.txt

5. Install PyTorch (SM 12.0 requires >= 2.7)

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

6. Install Missing Dependencies

pip install onnxsim
pip install matplotlib==3.10.3

7. Verify ONNX Packages

pip show onnx onnxruntime onnxruntime-gpu
# Recommended to keep either CPU or GPU runtime—not both

8. Verify CUDA-Enabled PyTorch

pip show torch torchaudio

9. Check for Dependency Conflicts

pip check

10. Save Installed Packages (Optional)

pip freeze > install_packages.txt

11. Ensure Pip is Still v24.0

pip --version
python.exe -m pip install pip==24.0 # If not 24.0

12. Confirm ffmpeg is in PATH

ffmpeg  # Should return a version
# If not, install ffmpeg and add it to system PATH

13. Download Required Models

python tools/download_models.py

14. Modify go-web.bat

Open go-web.bat in a text editor and change:

From:
runtime\python.exe infer-web.py --pycmd runtime\python.exe --port 7897

To:
venv\scripts\python.exe infer-web.py --pycmd venv\scripts\python.exe --port 7897

Fixing Known Errors (Do all of the following regardless of error)

Error #1 – pickle.UnpicklingError (Inference)

  • Fix: Modify checkpoint_utils.py

Open:

.\venv\Lib\site-packages\fairseq\checkpoint_utils.py

At line 315, change:

state = torch.load(f, map_location=torch.device("cpu"), weights_only=False)

Error #2 – 'FigureCanvasAgg' has no attribute 'tostring_rgb' (Training)

Open:

.\infer\lib\train\utils.py

At line 238, replace:

# data = ...
data = np.frombuffer(fig.canvas.tostring_rgb(), dtype=np.uint8).reshape(fig.canvas.get_width_height()[::-1] + (3,))

Repeat this fix in the plot_alignment_to_numpy function below.

Also, downgrade matplotlib:

pip install matplotlib==3.9.0

Error #3 – PermissionError during ONNX Export

Modify infer-web.py

Locate and change export_onnx function:

def export_onnx(ModelPath, ExportedPath):
from infer.modules.onnx.export import export_onnx as eo
result = eo(ModelPath, ExportedPath)
return result
Modify export.py

Open:

.\infer\modules\onnx\export.py

Update:

cpt = torch.load(ModelPath, map_location="cpu", weights_only=False)

And near the end, replace:

model, _ = onnxsim.simplify(ExportedPath)
onnx.save(model, ExportedPath)
return "Finished"

With:

try:
# model, _ = onnxsim.simplify(ExportedPath)
# onnx.save(model, ExportedPath)
print("export_onnx: onnxsim/onnx.save skipped/completed (if uncommented).")
except NameError:
print("export_onnx: onnxsim.simplify was skipped.")
except Exception as e:
print(f"export_onnx: An unexpected error occurred: {e}")

print("export_onnx: About to return 'Finished'.")
return "Finished"

Error #4 – Error during training

On the 50 series, it’s normal for it to error when you press ‘train model’ however, it is still working typically, it’s a GUI error! You will need to look at the terminal window to see actual progress. It should mention about epochs and 1/100 or whatever after 5-10 minutes.

However, when you press ‘Train Feature Index’ it will show ‘error’ and it won’t work in the terminal either.

Let’s assume, you press ‘train model’ it shows an error on the GUI but you look at the terminal and see it completing. Brilliant! Now, you press ‘train feature index’, it errors on the GUI and in the terminal – Not brilliant. To fix this, we need to do the following:

Open

.\infer\modules\train\

Create file
train_index.py


Paste in the following:
.\iimport os
import numpy as np
import faiss
from pathlib import Path
import argparse

def compute_faiss_index(feat_dir, index_path):
feats = []
for f in Path(feat_dir).glob("*.npy"):
feats.append(np.load(f))
feats = np.concatenate(feats, axis=0)
print(f"Total features shape: {feats.shape}")

dim = feats.shape[1]
print(f"Using faiss index of dimension {dim}")
index = faiss.IndexFlatL2(dim)
index.add(feats)
faiss.write_index(index, str(index_path))
print(f"Index saved to {index_path}")

if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument("-e", "--exp_name", required=True)
parser.add_argument("-sr", "--sampling_rate", default="40k")
parser.add_argument("-v", "--version", default="v2")
args = parser.parse_args()

exp_dir = Path(f"logs/{args.exp_name}/3_feature768")
index_path = exp_dir / "index.pkl"

print(f"Building index from {exp_dir}")
compute_faiss_index(exp_dir, index_path)

In a seperate terminal window, do the following:

cd .\Retrieval-based-Voice-Conversion-WebUI-main\

venv\Scripts\activate

python infer\modules\train\train_index.py -e voicemail-test -v v2

Change voicemail-test to whatever your experiment is called / the folder being used in

C:\Users\xxxx\Retrieval-based-Voice-Conversion-WebUI-main\logs\FOLDER_NAME

That should then allow the train feature to work.

Whenever you need to use the feature ‘train feature index’, you will need to use the above method via the custom ‘train_index.py’ file. It will not work any other way!

Just to confirm the process:

Click train > add name of training model > enter the path of the audio file > click process data > once done, click feature extraction > once done > click train model > ignore error and look at terminal window > then create ‘train_index.py’ and open up a seperate terminal and load into the virtual enviroment > then run the following: python infer\modules\train\train_index.py -e voicemail-test -v v2 and wait to finish in terminal window! All done!



Run the App

In terminal, whilst in the venv\Scripts\activate enviroment, you can run the following:
go-web.bat
If you close the terminal window, you will need to CD back to C:\Users\xxxx\Retrieval-based-Voice-Conversion-WebUI-main
then run:
venv\Scripts\activate
then run
go-web.bat

You’re done! 🎉


Any issues, reach out to me on twitter / X and I can try and help!