-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added dash-extension support. Also significant tidy up and refactoring.
- Loading branch information
1 parent
1b7520a
commit 2a3289e
Showing
12 changed files
with
698 additions
and
771 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -127,3 +127,6 @@ dmypy.json | |
|
||
# Pyre type checker | ||
.pyre/ | ||
|
||
# cache dir | ||
tmp/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,17 @@ | ||
import dash | ||
import dash_html_components as html | ||
import dash_core_components as dcc | ||
from dash_extensions.enrich import Dash, FileSystemStore | ||
import dash_bootstrap_components as dbc | ||
from whitenoise import WhiteNoise | ||
import os | ||
|
||
os.makedirs("tmp/", exist_ok=True) | ||
output_defaults=dict(backend=FileSystemStore(cache_dir="tmp/",threshold=100), session_check=True) | ||
|
||
external_stylesheets = [dbc.themes.SPACELAB, 'https://codepen.io/chriddyp/pen/bWLwgP.css'] | ||
app = Dash(__name__, suppress_callback_exceptions=True, output_defaults=output_defaults, | ||
external_stylesheets=[dbc.themes.SPACELAB, 'https://codepen.io/chriddyp/pen/bWLwgP.css'], | ||
external_scripts=["https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/MathJax.js?config=TeX-MML-AM_CHTML" ]) | ||
app.title = "Uncertainty Quantification with equadratures" | ||
|
||
app=dash.Dash(__name__, external_stylesheets=external_stylesheets,suppress_callback_exceptions=True,meta_tags=[{'name': 'viewport', | ||
'content': 'width=device-width, initial-scale=0.2, maximum-scale=1.2,minimum-scale=0.5'}]) | ||
server = app.server | ||
server.secret_key = os.environ.get('secret_key', 'secret') | ||
# To serve static files (e.g. images etc) | ||
server.wsgi_app = WhiteNoise(server.wsgi_app, root='static/') |
Oops, something went wrong.