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 Memory Estimation #156

Open
guystoppi opened this issue Oct 4, 2022 · 1 comment
Open

GPU Memory Estimation #156

guystoppi opened this issue Oct 4, 2022 · 1 comment

Comments

@guystoppi
Copy link

When I make my scene too complicated, the NVISII renderer runs out of GPU memory. Obviously, this is inevitable, but it would be nice if I could get the size of a scene in memory before I call nvisii.render() so I can try to reduce the memory usage.

Is there already something I can call that estimates the GPU memory usage?

@natevm
Copy link
Collaborator

natevm commented Oct 4, 2022

Hm, good question.

At the moment we don’t have a good way to report this. It is an interesting thing to consider, but would be a lot of work to add…

In general, memory goes to:

  • textures
  • meshes
  • acceleration structures
  • component arrays

Textures and meshes you can compute, because you know how many vertices and indices a mesh uses, or how many pixels a texture has.

Component arrays are pre allocated, but the sizes of these allocations can be reduced depending on your workload using the optional parameters to nvisii.initialize.

Acceleration structures are a bit more difficult. In general, an acceleration structure will be 2-4X larger than the mesh being “accelerated” for ray traversal. But it depends on a lot of variables…

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