scaffold — FastAPI + SQLite + HTMX dashboard, ingest + dispatcher
- app/main.py : dashboard /, partials /partials/{jobs,monitor} (htmx polling)
- app/templates/ : index, jobs table, monitor card par worker
- app/static/style.css : thème sombre cohérent
- scripts/ingest.py : scan SSD d'acquisition, EXIF CreateDate → segments
continus par (AUV, GoPro serial) avec seuil configurable
- scripts/dispatcher.py : polling queue, pick worker selon VRAM free,
extraction ffmpeg + lingbot-map windowed --offload_to_cpu, progression DB
- DB : SQLite (acquisitions + jobs), lifecycle queued→extracting→running→done
- Workers par défaut : .87 (3060 12GB) + .84 (3090 24GB)
Contexte : QC terrain le jour-même (avant photogrammétrie à 30 jours),
plusieurs heures × 2 GoPros × 2-3 AUVs d'enregistrement à traiter en parallèle.
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
26
app/templates/_monitor.html
Normal file
26
app/templates/_monitor.html
Normal file
@@ -0,0 +1,26 @@
|
||||
<div class="worker-grid">
|
||||
{% for w in workers %}
|
||||
<div class="worker {% if not w.online %}offline{% endif %}">
|
||||
<div class="hdr">
|
||||
<b>{{ w.host }}</b>
|
||||
<span class="gpu">{{ w.gpu }}</span>
|
||||
<span class="state">{% if w.online %}online{% else %}offline{% endif %}</span>
|
||||
</div>
|
||||
{% if w.online %}
|
||||
<div class="bar">
|
||||
<span>VRAM</span>
|
||||
<progress value="{{ w.vram_used_mib or 0 }}" max="{{ w.vram_total_mib or 1 }}"></progress>
|
||||
<small>{{ w.vram_used_mib }} / {{ w.vram_total_mib }} MiB</small>
|
||||
</div>
|
||||
<div class="bar">
|
||||
<span>GPU</span>
|
||||
<progress value="{{ w.gpu_util_pct or 0 }}" max="100"></progress>
|
||||
<small>{{ w.gpu_util_pct }}%</small>
|
||||
</div>
|
||||
<div class="bar"><span>Disk /</span><small>{{ w.disk_used_pct }}</small></div>
|
||||
{% else %}
|
||||
<div class="err">{{ w.error or "unreachable" }}</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
Reference in New Issue
Block a user