Spaces:
Running
Running
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +11 -12
src/streamlit_app.py
CHANGED
@@ -19,19 +19,18 @@ st.markdown(
|
|
19 |
unsafe_allow_html=True
|
20 |
)
|
21 |
|
22 |
-
#
|
23 |
-
|
24 |
-
with col2:
|
25 |
-
weight = st.slider("Interpolation Weight", 0.0, 1.0, step=0.1)
|
26 |
|
27 |
-
# Video
|
28 |
filename = f"videos_generated_{weight:.1f}.mp4"
|
29 |
video_path = os.path.join(VIDEO_FOLDER, filename)
|
30 |
|
31 |
-
#
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
|
|
|
19 |
unsafe_allow_html=True
|
20 |
)
|
21 |
|
22 |
+
# Slider
|
23 |
+
weight = st.slider("Interpolation Weight", 0.0, 1.0, step=0.1)
|
|
|
|
|
24 |
|
25 |
+
# Video path
|
26 |
filename = f"videos_generated_{weight:.1f}.mp4"
|
27 |
video_path = os.path.join(VIDEO_FOLDER, filename)
|
28 |
|
29 |
+
# Display video or error
|
30 |
+
if os.path.exists(video_path):
|
31 |
+
st.video(video_path)
|
32 |
+
else:
|
33 |
+
st.markdown(
|
34 |
+
f"<p style='text-align: center; color: red;'>No video found for weight = {weight:.1f}</p>",
|
35 |
+
unsafe_allow_html=True
|
36 |
+
)
|