Update app.py
Browse files
app.py
CHANGED
@@ -206,10 +206,8 @@ def predict(text, threshold):
|
|
206 |
else:
|
207 |
checks.append(f"\n⚠️ No YouTube video found for “{cleaned_text}” — the predicted pose is based on the model’s learned approximation.")
|
208 |
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
return video_html, msg + "\n" + "\n".join(checks)
|
213 |
|
214 |
except Exception as e:
|
215 |
print("Error during prediction:", e)
|
@@ -223,7 +221,7 @@ gr.Interface(
|
|
223 |
gr.Slider(0.0, 1.0, value=0.05, step=0.05, label="Confidence Threshold (for displaying joints)")
|
224 |
],
|
225 |
outputs=[
|
226 |
-
gr.
|
227 |
gr.Markdown(label="Word Check + YouTube Reference")
|
228 |
],
|
229 |
title="Text-to-Malay Sign Pose Generator",
|
|
|
206 |
else:
|
207 |
checks.append(f"\n⚠️ No YouTube video found for “{cleaned_text}” — the predicted pose is based on the model’s learned approximation.")
|
208 |
|
209 |
+
|
210 |
+
return path, msg + "\n" + "\n".join(checks)
|
|
|
|
|
211 |
|
212 |
except Exception as e:
|
213 |
print("Error during prediction:", e)
|
|
|
221 |
gr.Slider(0.0, 1.0, value=0.05, step=0.05, label="Confidence Threshold (for displaying joints)")
|
222 |
],
|
223 |
outputs=[
|
224 |
+
gr.Video(label="Generated Pose Animation"),
|
225 |
gr.Markdown(label="Word Check + YouTube Reference")
|
226 |
],
|
227 |
title="Text-to-Malay Sign Pose Generator",
|