|
|
|
|
|
|
|
|
|
|
|
Write-Host "π TechMatrix Solvers - ISL Translation System" -ForegroundColor Cyan
|
|
|
Write-Host "Setting up Windows environment..." -ForegroundColor Green
|
|
|
|
|
|
|
|
|
Write-Host "`nπ Checking Python installation..." -ForegroundColor Yellow
|
|
|
try {
|
|
|
$pythonVersion = python --version 2>&1
|
|
|
Write-Host "β
Found: $pythonVersion" -ForegroundColor Green
|
|
|
} catch {
|
|
|
Write-Host "β Python not found. Please install Python 3.8+ first." -ForegroundColor Red
|
|
|
exit 1
|
|
|
}
|
|
|
|
|
|
|
|
|
Write-Host "`nπ¦ Checking pip installation..." -ForegroundColor Yellow
|
|
|
try {
|
|
|
$pipVersion = pip --version 2>&1
|
|
|
Write-Host "β
Found: $pipVersion" -ForegroundColor Green
|
|
|
} catch {
|
|
|
Write-Host "β pip not found. Please install pip first." -ForegroundColor Red
|
|
|
exit 1
|
|
|
}
|
|
|
|
|
|
|
|
|
Write-Host "`nπ Upgrading pip..." -ForegroundColor Yellow
|
|
|
pip install --upgrade pip
|
|
|
|
|
|
|
|
|
Write-Host "`nπ§Ή Cleaning up conflicting OpenCV packages..." -ForegroundColor Yellow
|
|
|
pip uninstall opencv-python opencv-python-headless opencv-contrib-python -y 2>$null
|
|
|
|
|
|
|
|
|
Write-Host "`nπ§ Installing PyTorch (CPU version)..." -ForegroundColor Yellow
|
|
|
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
|
|
|
|
|
|
|
|
|
Write-Host "`nπΈ Installing OpenCV (headless)..." -ForegroundColor Yellow
|
|
|
pip install opencv-python-headless==4.8.1.78
|
|
|
|
|
|
|
|
|
Write-Host "`nπ Installing core dependencies..." -ForegroundColor Yellow
|
|
|
pip install streamlit>=1.28.0
|
|
|
pip install numpy>=1.24.0
|
|
|
pip install pandas>=2.0.0
|
|
|
pip install Pillow>=9.0.0
|
|
|
pip install matplotlib==3.5.3
|
|
|
pip install scipy>=1.10.0
|
|
|
pip install scikit-image>=0.20.0
|
|
|
pip install tqdm>=4.65.0
|
|
|
|
|
|
|
|
|
Write-Host "`nπ€ Installing AI/ML dependencies..." -ForegroundColor Yellow
|
|
|
pip install keras>=2.13.0
|
|
|
pip install seaborn>=0.12.0
|
|
|
pip install huggingface_hub>=0.16.0
|
|
|
|
|
|
|
|
|
Write-Host "`n㪠Installing media processing..." -ForegroundColor Yellow
|
|
|
pip install av>=10.0.0
|
|
|
pip install ffmpeg-python>=0.2.0
|
|
|
|
|
|
|
|
|
Write-Host "`nπ₯ Checking FFmpeg installation..." -ForegroundColor Yellow
|
|
|
try {
|
|
|
$ffmpegVersion = ffmpeg -version 2>&1 | Select-String "version"
|
|
|
Write-Host "β
FFmpeg found: $($ffmpegVersion -split ' ')[2]" -ForegroundColor Green
|
|
|
} catch {
|
|
|
Write-Host "β οΈ FFmpeg not found. Installing via conda or manually download from https://ffmpeg.org/" -ForegroundColor Yellow
|
|
|
Write-Host " Trying conda install..." -ForegroundColor Yellow
|
|
|
try {
|
|
|
conda install ffmpeg -c conda-forge -y 2>$null
|
|
|
Write-Host "β
FFmpeg installed via conda" -ForegroundColor Green
|
|
|
} catch {
|
|
|
Write-Host "β Please install FFmpeg manually from https://ffmpeg.org/" -ForegroundColor Red
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
Write-Host "`nπ Verifying installation..." -ForegroundColor Yellow
|
|
|
python -c "
|
|
|
import sys
|
|
|
print(f'Python: {sys.version}')
|
|
|
|
|
|
try:
|
|
|
import cv2
|
|
|
print(f'β
OpenCV: {cv2.__version__}')
|
|
|
except Exception as e:
|
|
|
print(f'β OpenCV: {e}')
|
|
|
|
|
|
try:
|
|
|
import streamlit
|
|
|
print(f'β
Streamlit: {streamlit.__version__}')
|
|
|
except Exception as e:
|
|
|
print(f'β Streamlit: {e}')
|
|
|
|
|
|
try:
|
|
|
import torch
|
|
|
print(f'β
PyTorch: {torch.__version__}')
|
|
|
except Exception as e:
|
|
|
print(f'β PyTorch: {e}')
|
|
|
|
|
|
try:
|
|
|
import keras
|
|
|
print(f'β
Keras: {keras.__version__}')
|
|
|
except Exception as e:
|
|
|
print(f'β Keras: {e}')
|
|
|
|
|
|
try:
|
|
|
import numpy as np
|
|
|
print(f'β
NumPy: {np.__version__}')
|
|
|
except Exception as e:
|
|
|
print(f'β NumPy: {e}')
|
|
|
|
|
|
try:
|
|
|
import pandas as pd
|
|
|
print(f'β
Pandas: {pd.__version__}')
|
|
|
except Exception as e:
|
|
|
print(f'β Pandas: {e}')
|
|
|
"
|
|
|
|
|
|
Write-Host "`nπ Setup completed!" -ForegroundColor Cyan
|
|
|
Write-Host "`nTo run the application:" -ForegroundColor Green
|
|
|
Write-Host " streamlit run src/streamlit_app.py" -ForegroundColor White
|
|
|
Write-Host "`nTechMatrix Solvers Team - Ready to translate ISL! π€" -ForegroundColor Cyan |