src/estimagic/dashboard/run_dashboard.py
def run_dashboard(
    database_path,
    no_browser,
    port,
    updating_options,
):
    """Start the dashboard pertaining to one database.

    Args:
        database_path (str or pathlib.Path): Path to an sqlite3 file which
            typically has the file extension ``.db``.
        no_browser (bool): If True the dashboard does not open in the browser.
        port (int): Port where to display the dashboard.
        updating_options (dict): Specification how to update the plotting data.
            It contains "rollover", "update_frequency", "update_chunk", "jump" and
            "stride".

    """
    port = _find_free_port() if port is None else port
    port = int(port)

    if not isinstance(database_path, (str, pathlib.Path)):
        raise TypeError(
            "database_path must be string or pathlib.Path. ",
            f"You supplied {type(database_path)}.",
        )
    else:
        database_path = pathlib.Path(database_path)
        if not database_path.exists():
            raise ValueError(
                f"The database path {database_path} you supplied does not exist."
            )

    session_data = {
        "last_retrieved": 0,
        "database_path": database_path,
        "callbacks": {},
    }

    app_func = partial(
        dashboard_app,
        session_data=session_data,
        updating_options=updating_options,
    )
    apps = {"/": Application(FunctionHandler(app_func))}

    _start_server(apps=apps, port=port, no_browser=no_browser)
Start the dashboard pertaining to one database.

    Args:
        database_path (str or pathlib.Path): Path to an sqlite3 file which
            typically has the file extension ``.db``.
        no_browser (bool): If True the dashboard does not open in the browser.
        port (int): Port where to display the dashboard.
        updating_options (dict): Specification how to update the plotting data.
            It contains "rollover", "update_frequency", "update_chunk", "jump" and
            "stride".

    
Start the dashboard pertaining to one database.
Start the dashboard pertaining to one database .
def run_dashboard(
    database_path,
    no_browser,
    port,
    updating_options,
):
    port = _find_free_port() if port is None else port
    port = int(port)
    if not isinstance(database_path, (str, pathlib.Path)):
        raise TypeError(
            "database_path must be string or pathlib.Path. ",
            f"You supplied {type(database_path)}.",
        )
    else:
        database_path = pathlib.Path(database_path)
        if not database_path.exists():
            raise ValueError(
                f"The database path {database_path} you supplied does not exist."
            )
    session_data = {
        "last_retrieved": 0,
        "database_path": database_path,
        "callbacks": {},
    }
    app_func = partial(
        dashboard_app,
        session_data=session_data,
        updating_options=updating_options,
    )
    apps = {"/": Application(FunctionHandler(app_func))}
    _start_server(apps=apps, port=port, no_browser=no_browser)
def run_dashboard ( database_path , no_browser , port , updating_options , ) : port = _find_free_port ( ) if port is None else port port = int ( port ) if not isinstance ( database_path , ( str , pathlib . Path ) ) : raise TypeError ( "database_path must be string or pathlib.Path. " , f"You supplied {type(database_path)}." , ) else : database_path = pathlib . Path ( database_path ) if not database_path . exists ( ) : raise ValueError ( f"The database path {database_path} you supplied does not exist." ) session_data = { "last_retrieved" : 0 , "database_path" : database_path , "callbacks" : { } , } app_func = partial ( dashboard_app , session_data = session_data , updating_options = updating_options , ) apps = { "/" : Application ( FunctionHandler ( app_func ) ) } _start_server ( apps = apps , port = port , no_browser = no_browser )
Start the dashboard pertaining to one database.
Start the dashboard pertaining to one database .
"""Start the dashboard pertaining to one database.

    Args:
        database_path (str or pathlib.Path): Path to an sqlite3 file which
            typically has the file extension ``.db``.
        no_browser (bool): If True the dashboard does not open in the browser.
        port (int): Port where to display the dashboard.
        updating_options (dict): Specification how to update the plotting data.
            It contains "rollover", "update_frequency", "update_chunk", "jump" and
            "stride".

    """
database_path
Path to an sqlite3 file which
typically has the file extension ``.db``.
Path to an sqlite3 file which typically has the file extension ` ` . db ` ` .
no_browser
If True the dashboard does not open in the browser.
If True the dashboard does not open in the browser .
port
Port where to display the dashboard.
Port where to display the dashboard .
updating_options
Specification how to update the plotting data.
It contains "rollover", "update_frequency", "update_chunk", "jump" and
"stride".
Specification how to update the plotting data . It contains " rollover " " update_frequency " " update_chunk " " jump " and " stride " .