Spaces:
No application file
No application file
Download app.py.py from dee2004/rl-study-scheduler: direct link, hf CLI and curl.
- Browser
- Download file 552 Bytes
-
https://huggingface.co/spaces/dee2004/rl-study-scheduler/resolve/main/app.py.py
- Command line
-
hf download hf://spaces/dee2004/rl-study-scheduler/app.py.py
-
curl -L -o app.py.py https://huggingface.co/spaces/dee2004/rl-study-scheduler/resolve/main/app.py.py
552 Bytes
| import gradio as gr | |
| from compare import compare_agents, aggregate_results | |
| def run_scheduler(episodes): | |
| rl, base = compare_agents(episodes) | |
| rl_stats = aggregate_results(rl) | |
| base_stats = aggregate_results(base) | |
| return f""" | |
| RL Agent: | |
| {rl_stats} | |
| Baseline: | |
| {base_stats} | |
| Insight: | |
| RL performs better under stress and deadlines. | |
| """ | |
| demo = gr.Interface( | |
| fn=run_scheduler, | |
| inputs=gr.Slider(10, 100, value=50, step=10, label="Episodes"), | |
| outputs="text", | |
| title="RL Study Scheduler" | |
| ) | |
| demo.launch() |