-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREAD ME.txt
More file actions
168 lines (112 loc) Β· 3.31 KB
/
Copy pathREAD ME.txt
File metadata and controls
168 lines (112 loc) Β· 3.31 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
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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
# π€ FACE ANALYSIS SYSTEM (PROJECT GUIDE)
---
## π 1. PROJECT OVERVIEW
This project is a Face Analysis System that uses computer vision and pretrained deep learning models to detect faces, estimate age, and simulate aging effects in real time.
This project is a **Face Analysis System** built using Python.
It performs:
* Face Detection
* Age Prediction
* Face-based Aging Effect
The system captures an image using the laptop camera and processes it using AI models.
Our system captures an image using the camera, then uses OpenCV DNN to detect faces.
After detecting the face, we use a pretrained model to predict the age group.
Finally, we apply region-specific image processing techniques to simulate aging effects on the detected face.
---
## π§ 2. CONCEPTS USED
This project uses concepts from:
* Computer Vision
* Machine Learning
* Image Processing
* Deep Learning (pretrained models)
Key ideas:
* Face Detection using OpenCV DNN
* Age Prediction using pretrained model
* Image Transformation for aging effect
---
## π οΈ 3. TECHNOLOGIES & LIBRARIES USED
Install these libraries before running the project:
```bash
pip install streamlit opencv-python numpy pillow
```
Libraries used:
* streamlit β for frontend UI
* opencv-python (cv2) β for image processing and AI models
* numpy β for array operations
* pillow (PIL) β for image handling
---
## π 4. PROJECT STRUCTURE
```
face_aging_project/
βββ app.py
βββ model.py
βββ models/
β βββ deploy.prototxt
β βββ res10_300x300_ssd_iter_140000.caffemodel
β βββ age_deploy.prototxt
β βββ age_net.caffemodel
```
---
## βοΈ 5. HOW THE PROJECT WORKS
Step-by-step flow:
1. User opens the app
2. Camera captures image
3. Image is converted to NumPy array
4. Face is detected using OpenCV DNN
5. Age is predicted using pretrained model
6. Aging effect is applied to detected face
7. Output is displayed
---
## π» 6. HOW TO RUN THE PROJECT
Step 1: Open project folder in VS Code
Step 2: Open terminal
Step 3: Install libraries:
```bash
pip install streamlit opencv-python numpy pillow
```
Step 4: Run the app:
```bash
streamlit run app.py
```
Step 5: Open browser (usually http://localhost:8501)
---
## πΈ 7. HOW TO USE
1. Click "Take a photo"
2. Allow camera permission
3. Capture your image
4. Click "Analyze Face"
5. View:
* Original Image
* Processed Image
* Predicted Age
---
## β οΈ 8. IMPORTANT NOTES
* Make sure all model files are inside the "models" folder
* File names must be correct (no .txt extension)
* Internet is not required to run this project
* Works completely offline
---
## π§ͺ 9. OUTPUT
The system shows:
* Detected face with bounding box
* Predicted age group
* Modified (aged) image
---
## π 10. FUTURE IMPROVEMENTS
* Real AI-based aging using GAN models
* Gender detection
* Multiple face tracking
* Cloud API integration
---
## π§βπ» 11. AUTHOR NOTES
This project is designed to be:
* Simple to run
* Easy to understand
* Expandable in future
If any error occurs:
* Check file paths
* Check model files
* Restart Streamlit
---
Due to hardware and time constraints, we implemented an optimized version. However, the system is designed to support GAN-based models in future upgrades.
## β€οΈ END
Just run the app and everything should work smoothly :)