Update app.py
Browse files
app.py
CHANGED
@@ -103,7 +103,7 @@ def process_data():
|
|
103 |
x="date",
|
104 |
y="cumulative",
|
105 |
color="user",
|
106 |
-
title="
|
107 |
labels={
|
108 |
"date": "Дата",
|
109 |
"cumulative": "Накопительное количество SMS",
|
@@ -157,7 +157,7 @@ def process_data():
|
|
157 |
df_history,
|
158 |
x="ds",
|
159 |
y="y",
|
160 |
-
title="Прогноз
|
161 |
labels={
|
162 |
"ds": "Дата",
|
163 |
"value": "Количество SMS"
|
@@ -178,11 +178,11 @@ def process_data():
|
|
178 |
return (bars_html, fig, forecast_fig)
|
179 |
|
180 |
with gr.Blocks() as demo:
|
181 |
-
gr.Markdown("<h2
|
182 |
btn = gr.Button("Обновить данные и показать результат")
|
183 |
html_output = gr.HTML(label="Прогресс-бары: количество SMS и %")
|
184 |
-
plot_output = gr.Plot(label="
|
185 |
-
forecast_output = gr.Plot(label="Прогноз до
|
186 |
|
187 |
btn.click(fn=process_data, outputs=[html_output, plot_output, forecast_output])
|
188 |
|
|
|
103 |
x="date",
|
104 |
y="cumulative",
|
105 |
color="user",
|
106 |
+
title="Количество SMS",
|
107 |
labels={
|
108 |
"date": "Дата",
|
109 |
"cumulative": "Накопительное количество SMS",
|
|
|
157 |
df_history,
|
158 |
x="ds",
|
159 |
y="y",
|
160 |
+
title="Прогноз до конца февраля 2025 (всего)",
|
161 |
labels={
|
162 |
"ds": "Дата",
|
163 |
"value": "Количество SMS"
|
|
|
178 |
return (bars_html, fig, forecast_fig)
|
179 |
|
180 |
with gr.Blocks() as demo:
|
181 |
+
gr.Markdown("<h2>Количество сохраненных SMS (Даша, Лера, Света)</h2>")
|
182 |
btn = gr.Button("Обновить данные и показать результат")
|
183 |
html_output = gr.HTML(label="Прогресс-бары: количество SMS и %")
|
184 |
+
plot_output = gr.Plot(label="Накопительный график по датам (Даша, Лера, Света, Всего)")
|
185 |
+
forecast_output = gr.Plot(label="Прогноз до конца февраля 2025 (всего)")
|
186 |
|
187 |
btn.click(fn=process_data, outputs=[html_output, plot_output, forecast_output])
|
188 |
|