18 lines
511 B
Python
18 lines
511 B
Python
from dash import Dash, dcc, html
|
|
import logging
|
|
import dash_bootstrap_components as dbc
|
|
|
|
|
|
def show_figures(*figures):
|
|
for figure in figures:
|
|
figure.layout.template = 'plotly_dark'
|
|
|
|
app = Dash(external_stylesheets=[dbc.themes.DARKLY])
|
|
app.layout = html.Div([
|
|
dcc.Graph(figure=figure) for figure in figures
|
|
])
|
|
log = logging.getLogger('werkzeug')
|
|
log.setLevel(logging.ERROR)
|
|
|
|
app.show = lambda *args, **kwargs: app.run_server(*args, **kwargs, debug=False)
|
|
return app |