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

Support torch.vmap #563

Open
zihaozou opened this issue Feb 19, 2025 · 1 comment
Open

Support torch.vmap #563

zihaozou opened this issue Feb 19, 2025 · 1 comment

Comments

@zihaozou
Copy link

Currently, GSplat supports single-scene, multi-camera rendering in parallel. However, in some cases, we need to render multiple scenes with multiple cameras in parallel, such as for deformable scenes. A simple approach is to use a for loop, but a better option is to use torch.vmap, which enables parallelism for unbatched operations.

However, to use vmap with a custom torch.autograd.Function, we need to make a small adjustment. As specified here, we simply need to override an additional static method, setup_context, in the custom Function class.

If you're interested, I can help create a PR.

@maturk
Copy link
Collaborator

maturk commented Feb 19, 2025

I would be interested in seeing how to do this, or a small demo :)

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

No branches or pull requests

2 participants