logoalt Hacker News

Show HN: XY – A Fast, composable, GPU-accelerated interactive plotting library

87 pointsby apetuskeytoday at 3:54 PM32 commentsview on HN

Comments

hantusktoday at 8:31 PM

Check out mosaic from uwdata which works on top of Observable plot

Or plotly-resampler which works on top of plotly and uses the rust package tsdownsample to aggregate on the 4pixels per pixel shown level (to make antialias work)

the grammar of graphics approach really is a great abstraction, and I'd love to see xy work in that direction

show 1 reply
kaststoday at 4:39 PM

I’m not convinced GPU acceleration is a meaningful advantage for most charting use cases. Most dashboards don’t render enough data for it to matter. Once a chart is dense enough for rendering to become the bottleneck, it normally is already be too crowded to be meaningful. Zooming can justify supporting larger datasets, but sampling/viewport culling and level of detail often avoid drawing unnecessary points...

show 6 replies
raychistoday at 8:32 PM

Interesting approach to large scale visualisation. Moving reduction into Rust and sending screen bounded data to WebGL seems much more sensible than pushing millions of raw points into the browser. How does it perform with real time updates? I am assuming it is much more performant? Any plans for a prod deployment?

show 1 reply
ahnstoday at 6:45 PM

Interesting; how do the examples compare to datashader?

Edit: for my use cases, I use napari (~1e7-8 points) if I need true interactivity; otherwise, datashader/holoviz, or even just fast-histogram's 2D histograms work.

For extremely large point clouds, these caveats[0] still apply. It irks me when people make dense scatterplots without any indication of just how dense some portions are.

Still, if it can indeed handle 1e10 points, that's pretty impressive.

[0]: https://datashader.org/user_guide/Plotting_Pitfalls.html

HoneySpoonstoday at 6:44 PM

This is awesome, can easily see this becoming a standard library. Can't wait for the 3D and volume visualizations.

adhamitoday at 5:05 PM

it's possible to render data out-of-core with XY, allowing it to render the entirety of OpenStreetMaps (that's 10,742,674,832 nodes!) with sub-second pan/zooms. it's a bit difficult to host online but you can try it out locally: https://github.com/reflex-dev/xy/tree/main/examples/osm

NickyHeCtoday at 4:29 PM

been stuck on matplotlib for centuries, academia loves such a change

show 1 reply
kl01today at 6:54 PM

how does this stack up to evilcharts? my main use case is mapping out data onto frontend, and there are a lot of great libraries out there

show 1 reply
pcpliutoday at 5:00 PM

I misread it as ‘Chatting’ library and I was so confused on the GitHub page.

Love rust as the impl.

airstriketoday at 4:35 PM

> XY is an extremely fast, interactive, customizable Python charting library for the web

show 1 reply
farhan99today at 4:03 PM

Great, Rust and Tailwind CSS two of my favorite things in one.

kl01today at 5:38 PM

absolutely fantastic.

ranger_dangertoday at 4:44 PM

> written in Rust

> XY is an extremely fast, interactive, customizable Python charting library

which is it?

show 2 replies
cozzydtoday at 4:42 PM

no support for native GUI?

show 1 reply
kl01today at 5:38 PM

super cool!