ComfyUI/build_run.bat
2023-12-11 11:00:58 +08:00

25 lines
492 B
Batchfile

@echo off
setlocal
set VENV_DIR=venv
set REQUIREMENTS=requirements.txt
echo Setting up virtual environment...
python -m venv %VENV_DIR%
call %VENV_DIR%\Scripts\activate.bat
pip3 show torch > nul
if %errorlevel% neq 0 (
pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
)
echo Installing requirements...
pip install -r %REQUIREMENTS%
echo Setup complete.
echo Running the application...
call %VENV_DIR%\Scripts\activate.bat
python main.py