Dashboard Core — Vector Healing (Composer's healing panel)¶
Real predictive-healing pass over a noisy vector sequence (VQE/MD
telemetry, quantum state trajectories, or any other (n_steps, dim)
array) — a thin dashboard-facing wrapper around
ia_utils.vector_healing.enhanced_dense_healing_hybrid,
lazily imported so a missing/stripped ia_utils install fails with a
clear error at call time rather than breaking dashboard_core import
for everyone.
vector_healing ¶
Real predictive-healing pass over a noisy vector sequence (VQE/MD
telemetry, quantum state trajectories, or any other (n_steps, dim) array)
-- a thin wrapper around ia_utils.vector_healing.enhanced_dense_healing_hybrid,
which itself is built on dense_evolution.healing's Phi-Trigger primitives
(calculate_phi_ab, calculate_vettore_dinamico, evaluate_phi_trigger).
This existed in the pre-rebuild dashboard_core (Streamlit dashboard's "AI healing shield" middleware, routing VQE/MD telemetry through it before any panel was built from it) but was left behind when dashboard_core was rebuilt around the Composer kernel -- see this package's init.py docstring ("will be reintegrated selectively once this base is solid"). Reintegrated here as its own module, mirroring mitigation.py's shape (a dataclass result + one thin run_* function), rather than resurrecting the old monolithic dashboard_core.py.
run_vector_healing ¶
run_vector_healing(
vectors: ndarray, radius_baseline: Optional[int] = None
) -> VectorHealingResult
Heal a noisy (n_steps, dim) vector sequence: per step, a Phi-Trigger (dense_evolution.healing) decides whether the change from a local baseline looks like genuine dynamics (kept as-is) or static noise (replaced by the local median) -- see ia_utils.vector_healing.enhanced_dense_healing_hybrid's own docstring for the full algorithm. NaN/Inf entries are sanitized first (column-mean imputation) regardless of the trigger's decision.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
vectors
|
ndarray
|
array-like, shape (n_steps, dim), n_steps >= 0. |
required |
radius_baseline
|
Optional[int]
|
fixed radius for the local baseline window; if None (default), computed adaptively as min(20, max(3, n_steps // 3)). |
None
|
Returns:
| Type | Description |
|---|---|
VectorHealingResult
|
VectorHealingResult |
Source code in tools/dashboard_core/vector_healing.py
Not to be confused with ia_utils.vector_healing
(same name, different module) — that one has the real
median_healing/enhanced_dense_healing_hybrid implementation; this
one is the dashboard's request/response wrapper around it.