Spaces:
Runtime error
Runtime error
Shafeek Saleem
commited on
Commit
•
0cb5452
1
Parent(s):
2e086e2
bug fixed
Browse files- 0_Introduction.py +25 -40
- assets/quiz.json +53 -56
- pages/4_Trying It Out.py +1 -1
0_Introduction.py
CHANGED
@@ -7,47 +7,32 @@ initialize_level()
|
|
7 |
|
8 |
LEVEL = 0
|
9 |
|
10 |
-
import cv2
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
def intro_page():
|
15 |
-
st.
|
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 |
-
# st.write(
|
41 |
-
# """
|
42 |
-
# In this tutorial, you will learn how to build a simple application that can detect and recognise faces from a given photo. Face recognition has revolutionized
|
43 |
-
# various industries, including security, entertainment, and personal identification. Are you ready to dive into the exciting world of face recognition?
|
44 |
-
# """
|
45 |
-
# )
|
46 |
-
#
|
47 |
-
# st.info(f"Click on the button below to start the tutorial!")
|
48 |
-
#
|
49 |
-
# if st.button("I am Ready!"):
|
50 |
-
# complete_level(LEVEL)
|
51 |
|
52 |
|
53 |
render_page(intro_page, LEVEL)
|
|
|
7 |
|
8 |
LEVEL = 0
|
9 |
|
|
|
|
|
|
|
|
|
10 |
def intro_page():
|
11 |
+
st.header("Face Recognition")
|
12 |
+
st.subheader("Introduction")
|
13 |
+
|
14 |
+
st.write(
|
15 |
+
"""
|
16 |
+
Welcome to the interactive tutorial on creating your very own Face Recognition Application!
|
17 |
+
"""
|
18 |
+
)
|
19 |
+
|
20 |
+
st.image(
|
21 |
+
"https://static.wixstatic.com/media/abb909_35aa4b27e4b840659a20fd69f0a18354~mv2.gif",
|
22 |
+
use_column_width=True,
|
23 |
+
)
|
24 |
+
|
25 |
+
st.write(
|
26 |
+
"""
|
27 |
+
In this tutorial, you will learn how to build a simple application that can detect and recognise faces from a given photo. Face recognition has revolutionized
|
28 |
+
various industries, including security, entertainment, and personal identification. Are you ready to dive into the exciting world of face recognition?
|
29 |
+
"""
|
30 |
+
)
|
31 |
+
|
32 |
+
st.info(f"Click on the button below to start the tutorial!")
|
33 |
+
|
34 |
+
if st.button("I am Ready!"):
|
35 |
+
complete_level(LEVEL)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
36 |
|
37 |
|
38 |
render_page(intro_page, LEVEL)
|
assets/quiz.json
CHANGED
@@ -1,92 +1,89 @@
|
|
1 |
[
|
2 |
{
|
3 |
-
"question": "
|
4 |
"options": [
|
5 |
-
"
|
6 |
-
"
|
7 |
-
"
|
8 |
-
"Teaching humans to recognize facial features"
|
9 |
],
|
10 |
-
"answer": "
|
11 |
},
|
12 |
{
|
13 |
-
"question": "
|
14 |
"options": [
|
15 |
-
"
|
16 |
-
"
|
17 |
-
"
|
18 |
-
"
|
19 |
],
|
20 |
-
"answer": "
|
21 |
},
|
22 |
{
|
23 |
-
"question": "
|
24 |
-
"options": [
|
25 |
-
|
26 |
-
"To recognize and understand human emotions",
|
27 |
-
"To create graphical user interfaces",
|
28 |
-
"To generate statistical reports"
|
29 |
-
],
|
30 |
-
"answer": "To analyze and manipulate images and videos"
|
31 |
},
|
32 |
{
|
33 |
-
"question": "
|
34 |
"options": [
|
35 |
-
"
|
36 |
-
"
|
37 |
-
"
|
38 |
-
"
|
39 |
],
|
40 |
-
"answer": "
|
41 |
},
|
42 |
{
|
43 |
-
"question": "
|
44 |
"options": [
|
45 |
-
"
|
46 |
-
"
|
47 |
-
"
|
48 |
-
"
|
49 |
],
|
50 |
-
"answer": "
|
51 |
},
|
52 |
{
|
53 |
-
"question": "
|
54 |
"options": [
|
55 |
-
"It
|
56 |
-
"It
|
57 |
-
"It
|
58 |
-
"It adjusts the application's settings based on user preferences"
|
59 |
],
|
60 |
-
"answer": "It
|
|
|
|
|
|
|
|
|
|
|
61 |
},
|
62 |
{
|
63 |
-
"question": "What is
|
64 |
"options": [
|
65 |
-
"
|
66 |
-
"
|
67 |
-
"
|
68 |
-
"
|
69 |
],
|
70 |
-
"answer": "
|
71 |
},
|
72 |
{
|
73 |
-
"question": "
|
74 |
"options": [
|
75 |
-
"
|
76 |
-
"
|
77 |
-
"
|
78 |
-
"
|
79 |
],
|
80 |
-
"answer": "
|
81 |
},
|
82 |
{
|
83 |
-
"question": "
|
84 |
"options": [
|
85 |
-
"
|
86 |
-
"
|
87 |
-
"
|
88 |
-
"Skip the testing phase and move directly to deployment"
|
89 |
],
|
90 |
-
"answer": "
|
91 |
}
|
92 |
]
|
|
|
1 |
[
|
2 |
{
|
3 |
+
"question": "What is face recognition?",
|
4 |
"options": [
|
5 |
+
"The ability to detect emotions through facial expressions.",
|
6 |
+
"The process of identifying or verifying a person's identity through their facial features.",
|
7 |
+
"The act of analyzing facial beauty and attractiveness."
|
|
|
8 |
],
|
9 |
+
"answer": "The process of identifying or verifying a person's identity through their facial features."
|
10 |
},
|
11 |
{
|
12 |
+
"question": "Which technology is commonly used for face recognition?",
|
13 |
"options": [
|
14 |
+
"Voice recognition",
|
15 |
+
"Fingerprint recognition",
|
16 |
+
"Iris recognition",
|
17 |
+
"All of the above"
|
18 |
],
|
19 |
+
"answer": "Iris recognition"
|
20 |
},
|
21 |
{
|
22 |
+
"question": "True or False: Face recognition can only be used for security purposes.",
|
23 |
+
"options": ["True", "False"],
|
24 |
+
"answer": "False"
|
|
|
|
|
|
|
|
|
|
|
25 |
},
|
26 |
{
|
27 |
+
"question": "What is the primary biometric characteristic used in face recognition?",
|
28 |
"options": [
|
29 |
+
"Eye color",
|
30 |
+
"Facial hair",
|
31 |
+
"Facial structure",
|
32 |
+
"Skin color"
|
33 |
],
|
34 |
+
"answer": "Facial structure"
|
35 |
},
|
36 |
{
|
37 |
+
"question": "Which of the following is a potential application of face recognition technology?",
|
38 |
"options": [
|
39 |
+
"Unlocking smartphones",
|
40 |
+
"Airport security",
|
41 |
+
"Monitoring attendance in schools",
|
42 |
+
"All of the above"
|
43 |
],
|
44 |
+
"answer": "All of the above"
|
45 |
},
|
46 |
{
|
47 |
+
"question": "What is the main advantage of face recognition over other biometric methods?",
|
48 |
"options": [
|
49 |
+
"It is less expensive to implement.",
|
50 |
+
"It is more secure and accurate.",
|
51 |
+
"It can be easily altered or manipulated."
|
|
|
52 |
],
|
53 |
+
"answer": "It is more secure and accurate."
|
54 |
+
},
|
55 |
+
{
|
56 |
+
"question": "True or False: Face recognition systems work equally well for all individuals, regardless of race or ethnicity.",
|
57 |
+
"options": ["True", "False"],
|
58 |
+
"answer": "False"
|
59 |
},
|
60 |
{
|
61 |
+
"question": "What is the term used to describe the process of training a face recognition system to recognize specific individuals?",
|
62 |
"options": [
|
63 |
+
"Calibration",
|
64 |
+
"Enrollment",
|
65 |
+
"Authorization",
|
66 |
+
"Validation"
|
67 |
],
|
68 |
+
"answer": "Enrollment"
|
69 |
},
|
70 |
{
|
71 |
+
"question": "Which of the following factors can affect the accuracy of face recognition systems?",
|
72 |
"options": [
|
73 |
+
"Lighting conditions",
|
74 |
+
"Changes in facial appearance (e.g., aging, makeup)",
|
75 |
+
"Occlusions (e.g., wearing glasses, masks)",
|
76 |
+
"All of the above"
|
77 |
],
|
78 |
+
"answer": "All of the above"
|
79 |
},
|
80 |
{
|
81 |
+
"question": "How does face recognition technology work?",
|
82 |
"options": [
|
83 |
+
"By analyzing the unique patterns in a person's eyes",
|
84 |
+
"By comparing the shape and structure of a person's face with stored templates",
|
85 |
+
"By measuring the temperature of a person's face"
|
|
|
86 |
],
|
87 |
+
"answer": "By comparing the shape and structure of a person's face with stored templates"
|
88 |
}
|
89 |
]
|
pages/4_Trying It Out.py
CHANGED
@@ -30,7 +30,7 @@ def step4_page():
|
|
30 |
)
|
31 |
# Select input type
|
32 |
st.info("Select your input type to analyze!")
|
33 |
-
input_type = st.radio("Select the Input Type", ["Image upload", "Camera"
|
34 |
# Put slide to adjust tolerance
|
35 |
tolerance = st.slider("Tolerance", 0.0, 1.0, 0.5, 0.01)
|
36 |
st.info(
|
|
|
30 |
)
|
31 |
# Select input type
|
32 |
st.info("Select your input type to analyze!")
|
33 |
+
input_type = st.radio("Select the Input Type", ["Image upload", "Camera"])
|
34 |
# Put slide to adjust tolerance
|
35 |
tolerance = st.slider("Tolerance", 0.0, 1.0, 0.5, 0.01)
|
36 |
st.info(
|