-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathinstall-xpu0.bat
More file actions
63 lines (56 loc) · 1.77 KB
/
install-xpu0.bat
File metadata and controls
63 lines (56 loc) · 1.77 KB
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
@echo off
echo --- Desktop2Stereo Installer (With XPU for Intel GPUs.) ---
echo - Setting up the virtual environment
@REM torch compile: https://www.intel.com/content/www/us/en/developer/articles/technical/boost-pytorch-inductor-performance-on-windows.html
@REM Set paths
Set "VIRTUAL_ENV=.env"
Set "PYTHON_EXE=python.exe"
@REM Check if Python is available
where %PYTHON_EXE% >nul 2>&1
if %errorlevel% neq 0 (
echo Python is not found in PATH. Please install Python 3.11 first.
pause
exit /b 1
)
@REM Create virtual environment if it doesn't exist
if not exist "%VIRTUAL_ENV%\Scripts\activate.bat" (
echo Creating virtual environment...
%PYTHON_EXE% -m venv "%VIRTUAL_ENV%"
if %errorlevel% neq 0 (
echo Failed to create virtual environment
pause
exit /b 1
)
)
@REM Activate virtual environment
echo - Virtual environment activation
call "%VIRTUAL_ENV%\Scripts\activate.bat"
if %errorlevel% neq 0 (
echo Failed to activate virtual environment
pause
exit /b 1
)
@REM Update pip
echo - Updating the pip package
%PYTHON_EXE% -m pip install --upgrade pip --no-cache-dir
if %errorlevel% neq 0 (
echo Failed to update pip
pause
exit /b 1
)
@REM Install requirements
echo.
echo - Installing the requirements
%PYTHON_EXE% -m pip install -r requirements-xpu0.txt --no-cache-dir
%PYTHON_EXE% -m pip install -r requirements.txt --no-cache-dir
%PYTHON_EXE% -m pip install onnx==1.20.1 onnxscript==0.6.0 --no-cache-dir
%PYTHON_EXE% -m pip install openvino==2025.4.1 --no-cache-dir
%PYTHON_EXE% -m pip install wincam==1.0.14 --no-cache-dir
%PYTHON_EXE% -m pip install windows-capture==1.5.0 --no-cache-dir
if %errorlevel% neq 0 (
echo Failed to install requirements
pause
exit /b 1
)
echo Python environment deployed successfully.
pause