From a full data-transport audit at b0f8780.
Today: _finite_sel correctly consults zone-map null_count first (python/xy/_payload.py:352-362), but _log_visible_mask (_payload.py:364-380) — called unconditionally from _emit_line (:422) and _emit_scatter (:466-470) — then recomputes isfinite(xv) & isfinite(yv) plus np.all(mask): ~3-4 full O(N) passes per trace per build that are provably all-true when null_count == 0 and neither axis is log.
Proposed fix: guard with if null_count or x_log or y_log: before building the mask; return the no-mask fast path otherwise. Pure CPU win on every direct build of every line/scatter trace; one-line-ish change plus tests.
From a full data-transport audit at b0f8780.
Today:
_finite_selcorrectly consults zone-mapnull_countfirst (python/xy/_payload.py:352-362), but_log_visible_mask(_payload.py:364-380) — called unconditionally from_emit_line(:422) and:466-470) — then recomputes_emit_scatter(isfinite(xv) & isfinite(yv)plusnp.all(mask): ~3-4 full O(N) passes per trace per build that are provably all-true whennull_count == 0and neither axis is log.Proposed fix: guard with
if null_count or x_log or y_log:before building the mask; return the no-mask fast path otherwise. Pure CPU win on every direct build of every line/scatter trace; one-line-ish change plus tests.