Spaces:
Running
Running
Commit ·
a74a8c1
1
Parent(s): 73ac613
legend
Browse files
app.py
CHANGED
|
@@ -432,6 +432,32 @@ def build_map(agent_sp):
|
|
| 432 |
)
|
| 433 |
).add_to(m)
|
| 434 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 435 |
m.get_root().width = "100%"
|
| 436 |
m.get_root().height = "420px"
|
| 437 |
return m._repr_html_()
|
|
@@ -506,10 +532,9 @@ with gr.Blocks(title="HiCoTraj Demo", theme=gr.themes.Soft()) as app:
|
|
| 506 |
gr.Markdown("## HiCoTraj — Trajectory Visualization & Hierarchical CoT Demo")
|
| 507 |
gr.Markdown("*Zero-Shot Demographic Reasoning via Hierarchical Chain-of-Thought Prompting from Trajectory* · ACM SIGSPATIAL GeoGenAgent 2025")
|
| 508 |
gr.Markdown("""
|
| 509 |
-
**Dataset:** NUMOSIM
|
| 510 |
-
> Stanford C, Adari S, Liao X, et al. *NUMoSim: A Synthetic Mobility Dataset with Anomaly Detection Benchmarks.* ACM SIGSPATIAL Workshop on Geospatial Anomaly Detection, 2024.
|
| 511 |
|
| 512 |
-
**Map legend:** 🔴 Early visits (light red) → 🔴 Recent visits (dark red) · Each dot = one stay point · Click dot for details
|
| 513 |
""")
|
| 514 |
|
| 515 |
with gr.Row():
|
|
|
|
| 432 |
)
|
| 433 |
).add_to(m)
|
| 434 |
|
| 435 |
+
legend_html = """
|
| 436 |
+
<div style="
|
| 437 |
+
position:fixed; bottom:18px; left:18px; z-index:9999;
|
| 438 |
+
background:rgba(255,255,255,0.92); border-radius:8px;
|
| 439 |
+
padding:8px 12px; font-size:11px; font-family:sans-serif;
|
| 440 |
+
box-shadow:0 1px 5px rgba(0,0,0,0.2); line-height:1.8;
|
| 441 |
+
">
|
| 442 |
+
<div style="font-weight:600;margin-bottom:4px;">Stay Point Legend</div>
|
| 443 |
+
<div style="display:flex;align-items:center;gap:6px;">
|
| 444 |
+
<svg width="60" height="10">
|
| 445 |
+
<defs><linearGradient id="lg" x1="0" x2="1" y1="0" y2="0">
|
| 446 |
+
<stop offset="0%" stop-color="#ffcc00"/>
|
| 447 |
+
<stop offset="100%" stop-color="#8b0000"/>
|
| 448 |
+
</linearGradient></defs>
|
| 449 |
+
<rect width="60" height="10" rx="4" fill="url(#lg)"/>
|
| 450 |
+
</svg>
|
| 451 |
+
<span>Earlier → Later</span>
|
| 452 |
+
</div>
|
| 453 |
+
<div style="display:flex;align-items:center;gap:6px;margin-top:2px;">
|
| 454 |
+
<svg width="14" height="14"><circle cx="7" cy="7" r="5" fill="#cc4444" opacity="0.5"/></svg>
|
| 455 |
+
<span>Movement path</span>
|
| 456 |
+
</div>
|
| 457 |
+
<div style="color:#999;font-size:10px;margin-top:2px;">Click dot for details</div>
|
| 458 |
+
</div>
|
| 459 |
+
"""
|
| 460 |
+
m.get_root().html.add_child(folium.Element(legend_html))
|
| 461 |
m.get_root().width = "100%"
|
| 462 |
m.get_root().height = "420px"
|
| 463 |
return m._repr_html_()
|
|
|
|
| 532 |
gr.Markdown("## HiCoTraj — Trajectory Visualization & Hierarchical CoT Demo")
|
| 533 |
gr.Markdown("*Zero-Shot Demographic Reasoning via Hierarchical Chain-of-Thought Prompting from Trajectory* · ACM SIGSPATIAL GeoGenAgent 2025")
|
| 534 |
gr.Markdown("""
|
| 535 |
+
**Dataset:** NUMOSIM[1]
|
| 536 |
+
> [1]Stanford C, Adari S, Liao X, et al. *NUMoSim: A Synthetic Mobility Dataset with Anomaly Detection Benchmarks.* ACM SIGSPATIAL Workshop on Geospatial Anomaly Detection, 2024.
|
| 537 |
|
|
|
|
| 538 |
""")
|
| 539 |
|
| 540 |
with gr.Row():
|