Spaces:
Sleeping
Sleeping
felix.wf
commited on
Commit
·
033540b
1
Parent(s):
9c81fd8
add how many people detected
Browse files
app.py
CHANGED
@@ -33,6 +33,7 @@ if file_name is not None:
|
|
33 |
# 打印结果
|
34 |
print(persons)
|
35 |
st.text(persons)
|
|
|
36 |
|
37 |
# 假设有一张原始图片,加载图片并截取出每个 "person" 的部分
|
38 |
original_image = face_image
|
@@ -140,7 +141,7 @@ if file_name is not None:
|
|
140 |
|
141 |
with row2:
|
142 |
st.pyplot(pie_fig) # Display the pie chart
|
143 |
-
|
144 |
with row3:
|
145 |
st.pyplot(bar_fig) # Display the bar chart
|
146 |
|
|
|
33 |
# 打印结果
|
34 |
print(persons)
|
35 |
st.text(persons)
|
36 |
+
st.text(f"Number of persons detected: {len(persons)}")
|
37 |
|
38 |
# 假设有一张原始图片,加载图片并截取出每个 "person" 的部分
|
39 |
original_image = face_image
|
|
|
141 |
|
142 |
with row2:
|
143 |
st.pyplot(pie_fig) # Display the pie chart
|
144 |
+
|
145 |
with row3:
|
146 |
st.pyplot(bar_fig) # Display the bar chart
|
147 |
|