Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -83,36 +83,33 @@ def update_interface(result):
|
|
| 83 |
|
| 84 |
return outputs
|
| 85 |
|
| 86 |
-
|
| 87 |
-
.full-width-plot {
|
| 88 |
-
width: 100% !important;
|
| 89 |
-
height: 400px !important;
|
| 90 |
-
}
|
| 91 |
-
"""
|
| 92 |
-
|
| 93 |
-
with gr.Blocks(css=custom_css) as iface:
|
| 94 |
gr.Markdown("# AI Personality Detection")
|
| 95 |
gr.Markdown("Upload a video")
|
| 96 |
|
| 97 |
-
|
| 98 |
-
|
| 99 |
-
|
| 100 |
-
|
| 101 |
-
|
| 102 |
-
|
|
|
|
|
|
|
|
|
|
| 103 |
|
| 104 |
with gr.Tabs() as tabs:
|
| 105 |
-
speaker_tabs = [gr.Tab(f"
|
| 106 |
speaker_outputs = []
|
| 107 |
for tab in speaker_tabs:
|
| 108 |
with tab:
|
| 109 |
-
|
| 110 |
-
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
|
| 114 |
-
|
| 115 |
-
|
|
|
|
| 116 |
speaker_outputs.extend([
|
| 117 |
attachment_plot, attachment_explanation, dimensions_plot,
|
| 118 |
bigfive_plot, bigfive_explanation, personality_plot, personality_explanation
|
|
|
|
| 83 |
|
| 84 |
return outputs
|
| 85 |
|
| 86 |
+
with gr.Blocks() as iface:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 87 |
gr.Markdown("# AI Personality Detection")
|
| 88 |
gr.Markdown("Upload a video")
|
| 89 |
|
| 90 |
+
with gr.Row():
|
| 91 |
+
with gr.Column(scale=1):
|
| 92 |
+
video_input = gr.Video(label="Upload Video")
|
| 93 |
+
max_speakers = gr.Slider(minimum=1, maximum=3, step=1, value=2, label="Maximum Number of Speakers")
|
| 94 |
+
analyze_button = gr.Button("Analyze")
|
| 95 |
+
|
| 96 |
+
with gr.Column(scale=2):
|
| 97 |
+
transcript_output = gr.Textbox(label="Transcript", lines=10)
|
| 98 |
+
execution_info = gr.Textbox(label="Execution Information")
|
| 99 |
|
| 100 |
with gr.Tabs() as tabs:
|
| 101 |
+
speaker_tabs = [gr.Tab(f"Speaker {i+1}") for i in range(3)]
|
| 102 |
speaker_outputs = []
|
| 103 |
for tab in speaker_tabs:
|
| 104 |
with tab:
|
| 105 |
+
with gr.Column(scale=1):
|
| 106 |
+
attachment_plot = gr.Plot(label="Attachment Styles")
|
| 107 |
+
attachment_explanation = gr.Textbox(label="Attachment Styles Explanation")
|
| 108 |
+
dimensions_plot = gr.Plot(label="Attachment Dimensions")
|
| 109 |
+
bigfive_plot = gr.Plot(label="Big Five Traits")
|
| 110 |
+
bigfive_explanation = gr.Textbox(label="Big Five Traits Explanation")
|
| 111 |
+
personality_plot = gr.Plot(label="Personality Disorders")
|
| 112 |
+
personality_explanation = gr.Textbox(label="Personality Disorders Explanation")
|
| 113 |
speaker_outputs.extend([
|
| 114 |
attachment_plot, attachment_explanation, dimensions_plot,
|
| 115 |
bigfive_plot, bigfive_explanation, personality_plot, personality_explanation
|