-
Notifications
You must be signed in to change notification settings - Fork 207
/
Copy path01A.构建运行环境(默认源).bat
41 lines (31 loc) · 1.4 KB
/
01A.构建运行环境(默认源).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
@echo on
cd /D "%~dp0"
WHERE conda
IF %ERRORLEVEL% NEQ 0 (
if not exist "envs" mkdir envs
if not exist "envs\miniconda3" mkdir envs\miniconda3
IF not EXIST %~dp0envs\miniconda3\Scripts (
@RD /S /Q %~dp0envs\miniconda3
mkdir %~dp0envs\miniconda3
echo "Downloading miniconda..."
powershell -Command "(New-Object Net.WebClient).DownloadFile('https://repo.anaconda.com/miniconda/Miniconda3-py310_24.9.2-0-Windows-x86_64.exe', '.\envs\miniconda3.exe')"
echo "Installling minconda..."
start /wait "" %~dp0envs\miniconda3.exe /S /AddToPath=0 /RegisterPython=0 /InstallationType=JustMe /D=%~dp0envs\miniconda3
echo "Successfully install minconda"
del envs\miniconda3.exe
)
)
IF EXIST %~dp0envs\miniconda3\Scripts SET PATH=%~dp0envs\miniconda3\Scripts;%PATH%
call activate
call conda env list
call conda update -y --all
call conda create -y -n ezvtb_rt_venv python=3.10
call conda activate ezvtb_rt_venv
call conda env list
call conda install -y nvidia/label/cuda-12.6.3::cuda-nvcc-dev_win-64
call conda install -y conda-forge::pycuda
call python -m pip install --upgrade pip wheel
echo yes|python -m pip install nvidia-cudnn-cu12
echo yes|pip install tensorrt_cu12_libs==10.6.0 tensorrt_cu12_bindings==10.6.0 tensorrt==10.6.0 --extra-index-url https://pypi.nvidia.com
call python -m pip install -r requirements.txt --no-warn-script-location
pause