Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -103,9 +103,9 @@ with gr.Blocks(css=".output-text { font-family: 'Arial'; color: #222; font-size:
|
|
103 |
with gr.Row():
|
104 |
display_graph = gr.Image(value=plot_sensor_data(sensor_data), type="pil", label="Sensor Data Over Time")
|
105 |
recommendations = gr.Textbox(label="Analysis & Recommendations", placeholder="Insights will appear here...")
|
106 |
-
data_table = gr.Dataframe(sensor_data, label="Generated Sensor Data (Table View)", row_count=(10, "fixed"), interactive=False)
|
107 |
|
108 |
-
# Set up Gradio interaction
|
109 |
-
car_image.change(fn=analyze_data, inputs=[car_image,
|
110 |
|
111 |
app.launch()
|
|
|
103 |
with gr.Row():
|
104 |
display_graph = gr.Image(value=plot_sensor_data(sensor_data), type="pil", label="Sensor Data Over Time")
|
105 |
recommendations = gr.Textbox(label="Analysis & Recommendations", placeholder="Insights will appear here...")
|
106 |
+
data_table = gr.Dataframe(value=sensor_data, label="Generated Sensor Data (Table View)", row_count=(10, "fixed"), interactive=False)
|
107 |
|
108 |
+
# Set up Gradio interaction with wrapped DataFrame component
|
109 |
+
car_image.change(fn=analyze_data, inputs=[car_image, data_table], outputs=[recommendations, display_graph])
|
110 |
|
111 |
app.launch()
|