This commit is contained in:
Saifeddine ALOUI 2023-08-31 23:59:26 +02:00
parent 66abfac334
commit 755f28dc74

2
app.py
View File

@ -856,7 +856,7 @@ class LoLLMsWebUI(LoLLMsAPPI):
return jsonify({'status':False, "error": "Couldn't install cuda toolkit. Make sure you are running from conda environment"})
ASCIIColors.green("Cuda toolkit installed successfully")
ASCIIColors.yellow("Removing pytorch")
res = subprocess.check_call(["pip","uninstall","torch", "torchvision", "torchaudio"])
res = subprocess.check_call(["pip","uninstall","torch", "torchvision", "torchaudio", "-y"])
ASCIIColors.green("PyTorch unstalled successfully")
ASCIIColors.yellow("Installing pytorch with cuda support")
res = subprocess.check_call(["pip","install","--upgrade","torch==2.0.1+cu117", "torchvision", "torchaudio", "--index-url", "https://download.pytorch.org/whl/cu117","no-cache"])