-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.py
32 lines (23 loc) · 856 Bytes
/
app.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import dash
from dash.dependencies import Input, Output, State
import dash_bootstrap_components as dbc
import plotly.express as px
import pandas as pd
import plotly.graph_objs as go
import os
import json
import datetime
import dash_auth
from layouts import layout
from callbacks import callbacks
external_stylesheets = [dbc.themes.BOOTSTRAP]
app = dash.Dash(__name__, external_stylesheets=external_stylesheets,assets_folder="static")
server = app.server
app.config.suppress_callback_exceptions = True
VALID_USERNAME_PASSWORD_PAIRS = {"admin": "admin"}
auth = dash_auth.BasicAuth(app, VALID_USERNAME_PASSWORD_PAIRS)
app.layout = layout()
app.title = "Analyzing sports commentary in order to automatically recognize events and extract insights"
callbacks(app)
if __name__ == "__main__":
app.run_server(host="127.0.0.1", port="8050", debug=True)