Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Overview


Depending on the scene setup, V-Ray GPU might reach high VRAM consumption due to scene complexity, which might end up with an Out-Of-Mem errorAdding GPU device with more VRAM to the machine is always the best option to resolve the issue. But if that is not acceptable option you may use the following techniques to reduce the amount of VRAM used and eventually render the scene without Out-Of-Mem error.

UI Text Box
typeinfo

There are several ways to monitor GPU Memory Usage and Utilization if needed:

  • V-Ray GPU reports how much memory is used for Textures/Geometry/Light Cache/etc in the V-Ray log.
  • 3rd party utilities like MSI Afterburner and EVGA Precision provides detailed information about GPU Memory Usage and Utilization
  • Nvidia-SMI command line utility comes with Nvidia drivers installation

Floatingpagetoc

Multiexcerpt include
MultiExcerptNameUsing Chaos Cloud
PageWithExcerptMemory Usage Optimizations for CPU rendering

Using NVlink when hardware

support

supports it


The latest Nvidia technologies allows stacking Memory Amount from multiple GPU devices together. NVlink technology enables V-Ray to use GPU Memory from all NV-linked GPU devices as a single unit which makes possible rendering much more complex projects without hitting Out-Of-Mem error.

UI Text Box
typeinfo

More information about NVLink performance could be found here.

Optimizing textures


V-Ray GPU allows you to apply on-the-fly optimization to the project textures. There are three different texture modes.

Fancy Bullets
typecircle
  • Full Size Textures . This mode will not apply any optimizations to the textures and it is recommended only if projects fit in the available GPU Memory
  • Resize All Textures. This mode allows you to resize textures to smaller resolution and bit-depth which will help reducing Memory Usage
  • On Demand Mip-Mapping. This mode will force V-Ray to load textures in a very intelligent way, in the appropriate resolution and only if it is needed. The main benefits being significantly less Memory Usage and faster loading times.
UI Text Box
typeinfo

More information about On Demand Mip Mapping could be found here.

Using the GPU device with highest Memory Amount


Although V-Ray GPU is compatible with different GPU models and brands there are certain limitations in terms of Memory usage. If multiple GPU Devices are available, V-Ray GPU is limited by the GPU with the lowest amount of VRAM. 

 If Out-Of-Mem error occurs and your hardware setup consists of GPU devices with different Memory Amount, you may try excluding the GPU devices with less Memory and render the project without them. This way V-Ray will be able to fully utilize their Memory.

Multiexcerpt include
MultiExcerptNameRender in separate passes
PageWithExcerptMemory Usage Optimizations for CPU rendering

Multiexcerpt include
MultiExcerptNameOptimizing Project Geometry
PageWithExcerptMemory Usage Optimizations for CPU rendering

Export to .vrscene and render with V-Ray Standalone


Host Applications just like V-Ray need some VRAM to keep the scene open and to operate with it. Depending on scene complexity Host Application may occupy a few gigabytes of VRAM which could be very valuable for V-Ray in case there isn't enough Memory for the Rendering. Exporting the scene to a .vrscene file and Rendering rendering it with V-Ray Standalone will minimize VRAM consumption by excluding the Host Application.

Code Block
titleV-Ray Standalone command to launch V-Ray GPU rendering
vray -sceneFile="\\path\to\exported\scene.vrscene" -rtEngine=5
UI Text Box
typenote

Please note that this approach will reduce VRAM usage from the GPU devices connected to monitors. GPU devices not connected to a monitor won't benefit from it.

Multiexcerpt include
MultiExcerptNameClose other Memory Intensive Applications
PageWithExcerptMemory Usage Optimizations for CPU rendering

ui-text-box

typetip

As mentioned above, this approach will reduce VRAM usage from the GPU devices connected to monitors.

 

Using GPU Hybrid Rendering with CPU enabled only


This is not very effective approach in terms of render times since V-Ray won't benefit from using GPU devices. However if the scene is massive and there is no way to fit it into the GPU memory, it is still possible to render it with V-Ray GPU by using Hybrid Rendering with CPU enabled only.

UI Text Box
typeinfo

More information regarding Hybrid Rendering could be found here.

Using V-Ray Proxies


V-Ray Proxies is a very powerful tool which is especially useful for optimizing scenes with a lot of geometry. They are not that Memory Efficient for the GPU rendering as they are for the CPU, but they allow replacing the original geometry in the scene with simplified one. This alone may help reducing VRAM usage from the Host Application leaving more Memory for V-Ray to work with.