-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathrun_protzilla.bat
More file actions
58 lines (49 loc) · 1.71 KB
/
run_protzilla.bat
File metadata and controls
58 lines (49 loc) · 1.71 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
@echo off
echo Welcome to PROTzilla
REM Check if Anaconda or Miniconda3 is installed
call conda --version >nul 2>&1
if %errorlevel% EQU 0 (
echo conda already installed
goto check_environment
)
echo Anaconda not already installed.
REM Check if Miniconda3 is installed
call miniconda --version >nul 2>&1
if %errorlevel% EQU 0 (
echo Miniconda3 is already installed.
goto check_environment
)
echo Miniconda3 not already installed.
REM Install Miniconda3
echo Downloading Miniconda3...
call powershell.exe -ExecutionPolicy Bypass -Command "Invoke-WebRequest -Uri 'https://repo.anaconda.com/miniconda/Miniconda3-latest-Windows-x86_64.exe' -OutFile 'Miniconda3-latest.exe'"
echo Installing Miniconda3...
start "" /wait Miniconda3-latest.exe /InstallationType=JustMe /AddToPath=1 /S /D=%UserProfile%\Miniconda3
del Miniconda3-latest.exe
echo Miniconda3 installation completed.
echo please run the script again
pause
goto :eof
:check_environment
REM Check if the environment exists
echo Checking if protzilla_win environment exists...
conda env list | findstr /C:"protzilla_win" >nul 2>&1
if %errorlevel% EQU 0 (
echo protzilla_win environment already exists.
goto activate_env
)
REM Create the environment
echo Creating protzilla_win environment...
call conda create -y --name protzilla_win python=3.11 -c conda-forge
echo protzilla_win environment created.
:activate_env
REM Activate the environment and install requirements
echo Activating protzilla_win environment...
call activate protzilla_win
pip install wheel
pip install -r requirements.txt
echo installed all requirements
REM downloading uniprot if necessary
python protzilla/data_integration/database_download.py
REM Run Django server
python ui/manage.py runserver