Exemple #1
0
def main():
    print("Creating CoreMemDriver...")
    spi_driver = CoreMemDriver()
    #spi_driver = MockCoreMemDriver()
    print("Done")

    run_server(spi_driver)
Exemple #2
0
#The main file for pulling the data and generating the dashboard

from utils import id_check, build_fig
import pandas as pd
import plotly.express as px
from app import run_server
import sys

if __name__ == '__main__':

    #Pulling data with Pandas
    df = pd.read_csv('phq_all_final.csv',
                     parse_dates=["date", "patient_date_created"])

    #Checking the patient id inputs for validity-getting ids from system args.
    valid_ids = id_check(sys.argv[1:], df)

    #Checking whether there are any records for the inputted patients
    if len(valid_ids) == 0:
        print("No patient records found")

    else:
        #Building the figure for the dashboard
        fig = build_fig(df, valid_ids)

        #Running the server and opening the dashboard in a browser
        run_server(fig)
Exemple #3
0
"""A one line summary of the program.

Overall program description (it can consist of several lines).
"""

from {{cookiecutter.app_name}}.app import app

app.run_server(debug=True, port=8077, threaded=True) # Debug
# app.run_server(debug=False, port=8077, threaded=True) # Release
Exemple #4
0
            # [html.Div([
            #     dcc.Link(query, href = '/apps/page_app/'+ query),
            #     html.Br()
            #     ]) for query in question_topics],

            # className = 'four columns')
        ],
        className='row',
        style={
            'text-align': 'center',
            'fontFamily': 'Titillium Web'
        }),

    # html.Div([
    #     html.Div([dcc.Graph(id = 'unique_links_bar',
    #     figure = {
    #     'data': [go.Bar(
    #         x=['Long-standing Topics', 'Topics in the News', 'Opinion-based Queries',
    #         "Question-based Queries"],
    #         y=[getAverageUniqueLinks(news_topics), getAverageUniqueLinks(long_standing_topics),
    #         getAverageUniqueLinks(opinion_topics), getAverageUniqueLinks(question_topics)],
    #         )],
    #     "layout": {
    #         "title": "Number of Unique Links"}
    #         })], className = 'four columns')
    # ],className = 'row')
])

if __name__ == '__main__':
    app.run_server(debug=True)
Exemple #5
0
            'y': data_count,
            'line': {
                'width': 3,
            }
        }],
        'layout': {
            'margin': {
                'l': 30,
                'r': 20,
                'b': 30,
                't': 20
            }
        }
    }


external_css = [
    "https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/css/materialize.min.css"
]
for css in external_css:
    app.css.append_css({"external_url": css})

external_js = [
    'https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/js/materialize.min.js'
]
for js in external_js:
    app.scripts.append_script({'external_url': js})

server = app.server
dev_server = app.run_server(debug=True)
Exemple #6
0
__author__ = 'Hossein Zolfi <*****@*****.**>'

import app

app.run_server()
Exemple #7
0
from app import run_server

app = run_server()
Exemple #8
0
from app import run_server

if __name__ == '__main__':
    run_server()