Cycles VRAM Usage Optimizations?

Hi, I’m working on an animation using Cycles and I’m curious to know if anyone can tell me what parts of a scene normally use the most VRAM and how the VRAM is used, so I can optimize the scene properly if it ends up using too much VRAM. As far as I understand the VRAM usage of the geometry is completely linear (so if you double the vertices it will use twice the amount of VRAM), but what about textures and materials? Will doubling the resolution of the textures double the VRAM usage of the textures too?

Also, what part of the scene normally consume the highest percentage of the total VRAM that’s used?

Textures are allocated in GPU RAM, almost 1-to-1, no MIPMAP data just single base layer. Geometry(actually, triangles with some precomputed data to speedup calcs,) stored in complex hierarhy structure, BVH. Nobody can predict how big BVH will be looking at scene triangles number, as it very depend in scene geometry. Shaders are stored as linked graph of nodes, and every triangle have integer index to that list. Most problem is BVH, as in some cases it can split geometry and make extra triangles.

You barely can do anything to optimise it. Just keep triangle number moderate, same for texture size.

Thanks, so if a scene is too big just simplify textures and triangles wherever possible without sacrificing too much quality. If the scene still uses too much VRAM just shave off whatever you can afford to or buy a GPU with more VRAM.

Exactly. You could also reuse textures and/or mix them with procedurals, alter them with HSV/Curves nodes etc. to lower memory consumption for textures and for geometry try to use instances where possible.