-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsetup.bat
More file actions
58 lines (50 loc) · 1.43 KB
/
setup.bat
File metadata and controls
58 lines (50 loc) · 1.43 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
REM Setup script for SF_Project on Windows
echo ========================================
echo CIFAR-10 Image Classifier Setup
echo ========================================
echo.
REM Check if Python is installed
python --version >nul 2>&1
if errorlevel 1 (
echo ERROR: Python is not installed or not in PATH
echo Please install Python 3.8 or higher from https://www.python.org/
pause
exit /b 1
)
echo [1/4] Python found!
echo.
REM Create virtual environment (optional but recommended)
echo [2/4] Creating virtual environment...
if not exist "venv" (
python -m venv venv
echo Virtual environment created!
) else (
echo Virtual environment already exists!
)
echo.
REM Activate virtual environment
echo [3/4] Activating virtual environment...
call venv\Scripts\activate.bat
echo.
REM Install dependencies
echo [4/4] Installing dependencies...
pip install -r requirements.txt
echo.
REM Create necessary directories
if not exist "static\uploads" mkdir static\uploads
echo Created upload directory!
echo.
echo ========================================
echo Setup Complete!
echo ========================================
echo.
echo To run the application:
echo 1. Activate virtual environment: venv\Scripts\activate
echo 2. Run the app: python app.py
echo 3. Open browser: http://localhost:5000
echo.
echo To train the model:
echo Run the Jupyter notebook: SF_project(convolutional_neural_network).ipynb
echo.
pause