question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

VegaLite rendering in notebook is very slow

See original GitHub issue

The following Julia code renders a 1000-point VegaLite scatter plot in 5+ seconds, or ~50 seconds for 10000-points. The Julia runtime is instantaneous, it is the render part which is slow. This slow render makes it very cumbersome to use VegaLite for visualization in notebooks

using VegaLite

npoints = 10000
[(; x = rand(), y = rand(), z = rand()) for _ in 1:npoints] |>
@vlplot(
    :point,
     x=:x,
     y=:y
)
Screen Shot 2021-11-02 at 16 18 05

In comparison, rendering the same 10000-point plot in a recent Chromium browser takes less than 2 seconds.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
pablosanjosecommented, Nov 30, 2021

Thanks for following up on this!

Very interesting question, I should have checked: the delay is also present in a jupyter notebook in the browser (both Vivaldi and Firefox). Same timings in macos, much slower than simply displaying the plot in the browser (i.e. running the command in the OP from a Julia REPL).

So this means the problem is not in the vscode jupyter integration. Feel free to close this then.

1reaction
DonJayamannecommented, Nov 18, 2021

I’m sorry for not getting back to you on this, I’ll be looking into this today.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Display of VegaLite plot is super slow on macos, fast on ...
It occurs both in a classic notebook ui and in jupyterlab. Under Windows there is no issue, the display is fast and agile....
Read more >
Display Troubleshooting — Altair 4.2.0 documentation
Notebook: VegaLite 4 object​​ This means that you have enabled the mimetype renderer. and rerun the cell with the chart.
Read more >
Why is Julia's graphics system so slow? - Performance
From what I can tell, it appears the slowness comes from VSCodeServer 's SVG rendering facilities. It is indeed more noticeable for scatter ......
Read more >
Stardust: Accessible and Transparent GPU Support for ...
While GPU-based rendering can drastically improve performance, that paradigm has a steep learning curve, usually requiring expertise in the ...
Read more >
Blog - QuantStack
HTML5 <canvas> based renderer for Matplotlib in Pyodide ... Jupyter notebooks are a great tool for practitioners of scientific computing from the research ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found