-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvdm_live.py
More file actions
39 lines (29 loc) · 1.51 KB
/
Copy pathvdm_live.py
File metadata and controls
39 lines (29 loc) · 1.51 KB
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
33
34
35
36
37
38
39
"""
Copyright © 2025 Justin K. Lietz, Neuroca, Inc. All Rights Reserved.
This research is protected under a dual-license to foster open academic
research while ensuring commercial applications are aligned with the project's ethical principles.
Commercial use of proprietary VDM code requires written permission from Justin K. Lietz.
See LICENSE file for full terms.
"""
from __future__ import annotations
import argparse
import os
from vdm_rt.frontend.app import build_app
def main() -> None:
ap = argparse.ArgumentParser(description="VDM Live Dashboard launcher (compat shim).")
ap.add_argument("--runs-root", default="runs", help="Path to runs root directory (default: ./runs)")
ap.add_argument("--host", default="127.0.0.1", help="Dash host (default: 127.0.0.1)")
ap.add_argument("--port", type=int, default=8060, help="Dash port (default: 8060)")
args = ap.parse_args()
# Preserve CLI choices in env for downstream components that may read them
os.environ.setdefault("RUNS_ROOT", os.path.abspath(args.runs_root))
os.environ.setdefault("DASH_HOST", args.host)
os.environ.setdefault("DASH_PORT", str(args.port))
os.environ.setdefault("PYTHONUNBUFFERED", "1")
app = build_app(os.environ["RUNS_ROOT"])
print(f"[vdm_live] runs_root={os.environ['RUNS_ROOT']}")
print(f"[vdm_live] Starting Dash on http://{args.host}:{args.port}")
# Avoid debug reloader to prevent duplicate callbacks
app.run(host=args.host, port=args.port, debug=False)
if __name__ == "__main__":
main()