File size: 4,746 Bytes
e2cffd9
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
#!/usr/bin/env python3
"""

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)
    
    # Check files
    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)
    
    # Check directories
    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)
    
    # Check README content for team branding
    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")
    
    # Check app.py for proper imports
    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")
            
            # Check for key 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)