fix: downsample 3D surface for browser fallback #50

Merged
ykp merged 1 commit from fix/plotly-downsample into main 2026-10-07 10:26:33 +02:00
Owner

The browser fallback (PR #49) sends the full 41x4096 correlation surface to plotly.js, which tries to create 327K triangles in WebGL. This causes RangeError: Array buffer allocation failed on plotly-4.1.1.min.js:2008.

Fix: downsample the code-phase axis to at most 200 bins before serializing the figure to HTML. The max value per bin is kept so the correlation peak remains visible. The PNG rendering path (tkinter) is unaffected.

The browser fallback (PR #49) sends the full 41x4096 correlation surface to plotly.js, which tries to create 327K triangles in WebGL. This causes RangeError: Array buffer allocation failed on plotly-4.1.1.min.js:2008. Fix: downsample the code-phase axis to at most 200 bins before serializing the figure to HTML. The max value per bin is kept so the correlation peak remains visible. The PNG rendering path (tkinter) is unaffected.
fix: downsample surface data for browser HTML fallback
All checks were successful
ci / test (3.14) (pull_request) Successful in 1m48s
ci / test (3.12) (pull_request) Successful in 1m55s
ci / test (3.9) (pull_request) Successful in 2m35s
ci / testgnss (3.12) (pull_request) Successful in 2m31s
ci / testgnss (3.14) (pull_request) Successful in 2m24s
ci / testgnss (3.9) (pull_request) Successful in 2m41s
4e8e1511d1
The full 41x4096 correlation surface creates 327K triangles in
plotly's WebGL renderer, causing 'Array buffer allocation failed'
in plotly.js. Downsample the code-phase axis to at most 200 bins
(keeping the max value per bin to preserve peak visibility).
ykp merged commit 1bc79515b6 into main 2026-10-07 10:26:33 +02:00
ykp deleted branch fix/plotly-downsample 2026-10-07 10:26:33 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
ykp/gengnss!50
No description provided.