|
|
|
|
|
"""
|
|
|
TechMatrix Solvers ISL Translation System
|
|
|
Deployment Verification Script
|
|
|
|
|
|
This script verifies that all required files are present for deployment
|
|
|
"""
|
|
|
|
|
|
import os
|
|
|
import sys
|
|
|
|
|
|
def verify_files():
|
|
|
"""Verify all required files are present"""
|
|
|
required_files = [
|
|
|
'README.md',
|
|
|
'requirements.txt',
|
|
|
'packages.txt',
|
|
|
'app.py',
|
|
|
'pose_models.py',
|
|
|
'pose_utils.py',
|
|
|
'isl_processor.py',
|
|
|
'expression_mapping.py',
|
|
|
'LICENSE',
|
|
|
'.gitignore',
|
|
|
'categories_processed.png',
|
|
|
'DataPipeline.png',
|
|
|
'model-graph.png'
|
|
|
]
|
|
|
|
|
|
required_dirs = [
|
|
|
'eda'
|
|
|
]
|
|
|
|
|
|
missing_files = []
|
|
|
missing_dirs = []
|
|
|
|
|
|
print("π TechMatrix Solvers ISL Translation System")
|
|
|
print("π Deployment Verification")
|
|
|
print("=" * 50)
|
|
|
|
|
|
|
|
|
print("\nπ Checking required files:")
|
|
|
for file in required_files:
|
|
|
if os.path.exists(file):
|
|
|
print(f"β
{file}")
|
|
|
else:
|
|
|
print(f"β {file}")
|
|
|
missing_files.append(file)
|
|
|
|
|
|
|
|
|
print("\nπ Checking required directories:")
|
|
|
for dir in required_dirs:
|
|
|
if os.path.isdir(dir):
|
|
|
print(f"β
{dir}/")
|
|
|
else:
|
|
|
print(f"β {dir}/")
|
|
|
missing_dirs.append(dir)
|
|
|
|
|
|
|
|
|
print("\nπ·οΈ Checking TechMatrix Solvers branding:")
|
|
|
if os.path.exists('README.md'):
|
|
|
with open('README.md', 'r') as f:
|
|
|
readme_content = f.read()
|
|
|
if 'TechMatrix Solvers' in readme_content:
|
|
|
print("β
Team branding present in README")
|
|
|
else:
|
|
|
print("β Team branding missing in README")
|
|
|
|
|
|
if 'Abhay Gupta' in readme_content:
|
|
|
print("β
Team member info present")
|
|
|
else:
|
|
|
print("β Team member info missing")
|
|
|
|
|
|
|
|
|
print("\nπ§ Checking main application structure:")
|
|
|
if os.path.exists('app.py'):
|
|
|
with open('app.py', 'r') as f:
|
|
|
app_content = f.read()
|
|
|
if 'streamlit' in app_content:
|
|
|
print("β
Streamlit framework detected")
|
|
|
if 'TechMatrix Solvers' in app_content:
|
|
|
print("β
Team branding in application")
|
|
|
if 'pose_models' in app_content and 'pose_utils' in app_content:
|
|
|
print("β
Core modules imported")
|
|
|
|
|
|
print("\n" + "=" * 50)
|
|
|
|
|
|
if missing_files or missing_dirs:
|
|
|
print("β Deployment verification FAILED")
|
|
|
if missing_files:
|
|
|
print(f"Missing files: {', '.join(missing_files)}")
|
|
|
if missing_dirs:
|
|
|
print(f"Missing directories: {', '.join(missing_dirs)}")
|
|
|
return False
|
|
|
else:
|
|
|
print("β
Deployment verification PASSED")
|
|
|
print("π Project is ready for deployment!")
|
|
|
print("\nπ Deployment Instructions:")
|
|
|
print("1. Upload project to HuggingFace Spaces")
|
|
|
print("2. Select Streamlit SDK")
|
|
|
print("3. Set app_file: app.py")
|
|
|
print("4. The system will automatically install dependencies")
|
|
|
print("\nπ₯ TechMatrix Solvers Team:")
|
|
|
print("- Abhay Gupta (Team Lead)")
|
|
|
print("- Kripanshu Gupta (Backend Developer)")
|
|
|
print("- Dipanshu Patel (UI/UX Designer)")
|
|
|
print("- Bhumika Patel (Deployment & Female Presenter)")
|
|
|
print("\nπ« Shri Ram Group of Institutions")
|
|
|
return True
|
|
|
|
|
|
def check_requirements():
|
|
|
"""Check requirements.txt format"""
|
|
|
print("\nπ¦ Checking dependencies:")
|
|
|
try:
|
|
|
with open('requirements.txt', 'r') as f:
|
|
|
requirements = f.read().strip().split('\n')
|
|
|
print(f"β
Found {len(requirements)} dependencies")
|
|
|
|
|
|
|
|
|
key_deps = ['streamlit', 'torch', 'keras', 'opencv-python', 'numpy']
|
|
|
for dep in key_deps:
|
|
|
if any(dep in req for req in requirements):
|
|
|
print(f"β
{dep} dependency found")
|
|
|
else:
|
|
|
print(f"β οΈ {dep} dependency not explicitly found")
|
|
|
|
|
|
except Exception as e:
|
|
|
print(f"β Error reading requirements.txt: {e}")
|
|
|
|
|
|
if __name__ == "__main__":
|
|
|
print("TechMatrix Solvers ISL Translation System")
|
|
|
print("Deployment Verification Tool\n")
|
|
|
|
|
|
success = verify_files()
|
|
|
check_requirements()
|
|
|
|
|
|
if success:
|
|
|
sys.exit(0)
|
|
|
else:
|
|
|
sys.exit(1) |