Spaces:
Sleeping
Sleeping
Commit
·
8685cda
1
Parent(s):
c4f2558
Update app.py
Browse files
app.py
CHANGED
@@ -142,7 +142,7 @@ def plot_seir(population):
|
|
142 |
kind = "line",
|
143 |
x = "timestep",
|
144 |
y= ["S","E","I", "R"])
|
145 |
-
fig.update_layout(title =
|
146 |
xaxis_title="Time (Days)",
|
147 |
yaxis_title="People")
|
148 |
return fig
|
@@ -151,7 +151,7 @@ with gr.Blocks(css = css) as demo:
|
|
151 |
gr.Markdown("""
|
152 |
## Epidemic Simulation
|
153 |
""")
|
154 |
-
population_input = gr.Slider(1000, 100000, value=10000)
|
155 |
simulate_btn = gr.Button('Run Simulation')
|
156 |
graph = gr.Plot()
|
157 |
simulate_btn.click(plot_seir, inputs = population_input, outputs = graph)
|
|
|
142 |
kind = "line",
|
143 |
x = "timestep",
|
144 |
y= ["S","E","I", "R"])
|
145 |
+
fig.update_layout(title = "Population Evolution Over Time",
|
146 |
xaxis_title="Time (Days)",
|
147 |
yaxis_title="People")
|
148 |
return fig
|
|
|
151 |
gr.Markdown("""
|
152 |
## Epidemic Simulation
|
153 |
""")
|
154 |
+
population_input = gr.Slider(1000, 100000, value=10000, label = "Population")
|
155 |
simulate_btn = gr.Button('Run Simulation')
|
156 |
graph = gr.Plot()
|
157 |
simulate_btn.click(plot_seir, inputs = population_input, outputs = graph)
|