-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathinstall_packages.bat
More file actions
27 lines (21 loc) · 1.05 KB
/
install_packages.bat
File metadata and controls
27 lines (21 loc) · 1.05 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
:: Try activating the Conda environment
echo Activating the Conda environment 'EDU'...
:: Check if CONDA_PREFIX is set, which would indicate conda is initialized
IF "%CONDA_PREFIX%"=="" (
:: If not set, find the correct path to conda's activation script
IF EXIST "%UserProfile%\miniconda3\condabin\conda.bat" (
call "%UserProfile%\miniconda3\condabin\conda.bat" activate EDU
) ELSE IF EXIST "%UserProfile%\Anaconda3\condabin\conda.bat" (
call "%UserProfile%\Anaconda3\condabin\conda.bat" activate EDU
) ELSE (
echo "Could not find the Conda activation script. Ensure that Conda is installed and properly initialized."
exit /b 1
)
) ELSE (
call conda activate EDU
)
:: Install the required packages
echo Installing PyTorch, Torchvision, CUDA 11.8, and Ultralytics...
conda install -c pytorch -c nvidia -c conda-forge pytorch torchvision pytorch-cuda=11.8 ultralytics -y && pip install opencv-contrib-python && pip install tqdm
echo Environment setup complete. You can now run your code in the 'EDU' environment.
pause