Spaces:
Runtime error
Runtime error
NassimeBejaia
commited on
Commit
•
87095c4
1
Parent(s):
bf3e5b9
Update app.py
Browse files
app.py
CHANGED
@@ -123,6 +123,19 @@ def extract_heads(filepath, frame0):
|
|
123 |
#st.write('Len of liste heads : ', len(listhead))
|
124 |
return nbperson, listhead
|
125 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
126 |
def display_heads(nbperson, listhead):
|
127 |
#os.system("streamlit run https://gist.githubusercontent.com/treuille/da70b4888f8b706fca7afc765751cd85/raw/0727bb67defd93774dae65a2bc6917f72e267460/image_paginator.py")
|
128 |
image_iterator = paginator("Select a sunset page", listhead)
|
@@ -162,7 +175,7 @@ def main():
|
|
162 |
#st.write('filepath : ',filepath)
|
163 |
st.success("Click again to retry or try a different video by uploading")
|
164 |
nbperson, listhead = extract_heads(filepath, frame0)
|
165 |
-
display_heads(nbperson, listhead)
|
166 |
|
167 |
return
|
168 |
|
|
|
123 |
#st.write('Len of liste heads : ', len(listhead))
|
124 |
return nbperson, listhead
|
125 |
|
126 |
+
#*********************************************************************************************
|
127 |
+
def display_heads)_(nbperson, listhead):
|
128 |
+
k = 0
|
129 |
+
for i in range(1, 10):
|
130 |
+
cols = st.columns(5)
|
131 |
+
for j in range(1, 5):
|
132 |
+
k = k + 1
|
133 |
+
cols[j].header("Person " + str(k))
|
134 |
+
cols[j].image(listhead[k], use_column_width=True)
|
135 |
+
return
|
136 |
+
|
137 |
+
#*********************************************************************************************
|
138 |
+
|
139 |
def display_heads(nbperson, listhead):
|
140 |
#os.system("streamlit run https://gist.githubusercontent.com/treuille/da70b4888f8b706fca7afc765751cd85/raw/0727bb67defd93774dae65a2bc6917f72e267460/image_paginator.py")
|
141 |
image_iterator = paginator("Select a sunset page", listhead)
|
|
|
175 |
#st.write('filepath : ',filepath)
|
176 |
st.success("Click again to retry or try a different video by uploading")
|
177 |
nbperson, listhead = extract_heads(filepath, frame0)
|
178 |
+
display_heads)_(nbperson, listhead)
|
179 |
|
180 |
return
|
181 |
|