Skip to content

Instantly share code, notes, and snippets.

View jacobbubu's full-sized avatar

Rong Shen jacobbubu

  • Li Auto.
  • Beijing, China
View GitHub Profile
@jacobbubu
jacobbubu / blender-multi_gpu.markdown
Created January 7, 2017 02:53 — forked from Fweeb/blender-multi_gpu.markdown
Rendering in Blender on a machine with multiple GPUs

Rendering in Blender on a machine with multiple GPUs

So here's the premise: For scenes that take around a minute or less to render, performance is actually worse if you render on all of the cards with a single instance of Blender. This is because (AFAIK) there's a bit of additional time necessary to collect the render results from each card and stitch them together. That time is a fixed short duration, so it's negligible on larger/longer render jobs. However, on shorter render jobs, the 'stitch time' has a much more significant impact.

I ran into this with a machine I render on that has 4 Quadro K6000s in it. To render animations, I ended up writing a few little scripts to facilitate launching 4 separate instances of Blender, each one tied to one GPU. Overall rendertime was much shorter with that setup than one instance of Blender using all 4 GPUs.

The setup works basically like this. In my .blend file, I embed 4 text files, batch-render0.py, batch-render1.py, batch-render2.py, and `batch-rende