-
Notifications
You must be signed in to change notification settings - Fork 4
/
startup.bat
44 lines (32 loc) · 1.31 KB
/
startup.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
@echo off
setlocal
REM Get the current directory of the batch file
set "SCRIPT_DIR=%~dp0"
REM Set the log file path
set "LOG_FILE=%SCRIPT_DIR%\log.txt"
REM Change to the script directory
cd /d "%SCRIPT_DIR%"
REM Create and activate the main virtual environment
python -m venv venv
call venv\Scripts\activate
REM Install PyTorch, torchvision, and torchaudio from a specific index URL
REM python -m pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 2>> "%LOG_FILE%"
REM Install openai-whisper from the GitHub repository
REM python -m pip install git+https://github.com/openai/whisper.git 2>> "%LOG_FILE%"
REM Install Greenlet - SCF (Transferr to V2, was causing issues, check log)
REM python -m pip install --upgrade pip
REM python -m pip install greenlet
REM python -m pip install websockets~=11.0
REM python -m pip install sounddevice
REM python -m pip install opencv-python
REM Install the remaining dependencies from requirements.txt
REM python -m pip install -r requirements.txt 2>> "%LOG_FILE%"
REM Execute the Python script (replace "main.py" with the actual file name)
python main.py 2>> "%LOG_FILE%"
REM Deactivate the virtual environment
deactivate
REM Display message and prompt user to exit
echo.
echo Batch file execution completed. Press any key to exit.
pause >nul
endlocal