Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GPU Quadmesh support #861

Merged
merged 4 commits into from
Jan 19, 2020
Merged

GPU Quadmesh support #861

merged 4 commits into from
Jan 19, 2020

Conversation

jonmmease
Copy link
Collaborator

This PR adds support for aggregating quadmesh glyphs using cuda. The cuda codepath is invoked when the data backing the provided xarray.DataArray is a cupy.ndarray.

I'm seeing 20-50x speedups in both the rectilinear and curvilinear cases.

Here are some examples: https://anaconda.org/jonmmease/gpu_quadmesh_pr/notebook

Copy link
Member

@jbednar jbednar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fabulous! Looks good to me, for what I can see. A release is planned for tomorrow or soon thereafter, so I won't merge now, but let me know when it's ready and I'll merge after release.

@philippjfr
Copy link
Member

Wow! Great stuff, looking forward to trying this, the PR to add support for this in HoloViews should only be a couple of lines.

@jonmmease
Copy link
Collaborator Author

Tests passing now, so this is good-to-go from my end

@philippjfr
Copy link
Member

I certainly wouldn't mind to announce this along with the other GPU support in HoloViews 1.13.0.

@jonmmease
Copy link
Collaborator Author

FWIW, I'm starting to look at GPU support for raster, but that's going be much more involved and not ready for a while. So, I'd say go ahead with releasing Quadmesh support (whenever that is) separately from raster.

@jbednar
Copy link
Member

jbednar commented Jan 17, 2020

Would it be possible to run a benchmark where you convert a raster to a quadmesh and compare GPU quadmesh vs. CPU raster? That might be a speedup already, and then we can wait for the real raster speedup when it's ready.

@jonmmease
Copy link
Collaborator Author

Would it be possible to run a benchmark where you convert a raster to a quadmesh and compare GPU quadmesh vs. CPU raster?

Sure, that's a good idea.

@jonmmease
Copy link
Collaborator Author

Unfortunately there's not much benefit (at least on my workstation). The raster implementation is parallelized well on the CPU and is much faster than the single threaded quadmesh implementation.

The GPU quadmesh is about on par with the raster (with a factor of 2 either way depending on input size).

@jbednar
Copy link
Member

jbednar commented Jan 17, 2020

Good to know, thanks! It's always interesting to see how hardware and algorithm choice interact to give the final performance on any particular problem.

@jbednar jbednar added this to the 0.10.0 milestone Jan 19, 2020
@jbednar jbednar merged commit 59b540b into master Jan 19, 2020
@jbednar jbednar deleted the gpu_quadmesh branch January 19, 2020 17:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants