Distributed Rendering with Pachyderm

The Why

Seriously guys, “Frames win games” ~ Nvidia

The How

NAME            TYPE SIZE     
/gallardo.blend file 794.8KiB
It’s definetly neccasary to break out emacs and modify some py scripts

The Splitter

pachctl create pipeline -f splitter.json --build --username <YourDockerUsernameHere>
NAME                TYPE SIZE
/gallardo/000000000 file 118B
/gallardo/000000001 file 118B
/gallardo/000000002 file 118B
/gallardo/000000003 file 118B
/gallardo/000000004 file 118B
/gallardo/000000005 file 118B
/gallardo/000000006 file 118B
/gallardo/000000007 file 118B
/gallardo/000000008 file 118B
/gallardo/000000009 file 119B
{
"jobId": "gallardo",
"frame": "1",
"outFilename": "f-######",
"file": "/pfs/blends/gallardo.blend"
}
One does not simply count the number of times I say “render” in this article

The Renderer

pachctl create pipeline -f renderer.json --build --username <YourDockerUsernameHere>
NAME                   TYPE SIZE
/gallardo/f-000001.png file 947.3KiB
/gallardo/f-000002.png file 962.5KiB
/gallardo/f-000003.png file 932.9KiB
/gallardo/f-000004.png file 1.016MiB
/gallardo/f-000005.png file 1.03MiB
/gallardo/f-000006.png file 915.5KiB
/gallardo/f-000007.png file 937.6KiB
/gallardo/f-000008.png file 1.027MiB
/gallardo/f-000009.png file 1011KiB
/gallardo/f-000010.png file 1015KiB
pachctl get file -r renderer@master:/gallardo -o .
Simple frame rendering
Sensing a pattern with my articles now, aren’t we?

The Here We Go Again

Step 1: The Map

pachctl create pipeline -f splitter.json --build --username <YourDockerUsernameHere>
NAME                TYPE SIZE 
/gallardo/000000000 file 222B
/gallardo/000000001 file 224B
... more files here ...
/gallardo/000000398 file 231B
/gallardo/000000399 file 231B

Step 2: The Renderer

pachctl create pipeline -f renderer.json --build --username <YourDockerUsernameHere>
NAME                           TYPE SIZE
/gallardo/f-000001-x-0-y-0.png file 32.71KiB
/gallardo/f-000001-x-0-y-1.png file 32.71KiB
/gallardo/f-000001-x-0-y-2.png file 32.71KiB
... more files here ...
/gallardo/f-000010-x-7-y-2.png file 17.16KiB
/gallardo/f-000010-x-7-y-3.png file 17.16KiB
/gallardo/f-000010-x-7-y-4.png file 4.189KiB

Step 3: The Reduce

  1. Merge all the X tiles together horizontally to form broader X tiles
  2. Merge all the broad X tiles together vertically from the step above to form the final frame
  3. Stash the frame in the merger repo under it’s respective frame number
pachctl create pipeline -f merger.json --build --username <YourDockerUsernameHere>
NAME                 TYPE SIZE
/gallardo/000001.png file 982.8KiB
/gallardo/000002.png file 821.6KiB
/gallardo/000003.png file 923.3KiB
/gallardo/000004.png file 1.068MiB
/gallardo/000005.png file 1.135MiB
/gallardo/000006.png file 950.3KiB
/gallardo/000007.png file 848.6KiB
/gallardo/000008.png file 1.137MiB
/gallardo/000009.png file 1018KiB
/gallardo/000010.png file 1.119MiB
Split tile rendering
Make friends first, make sales second, make containers third. In no particular order.

Final Thoughts

Special Thanks

--

--

Helping you with your challenges related to complex data processing, data transformations, scalable data pipelines, and data versioning.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Lokesh Poovaragan

theycallmeloki.com, Developer Advocate at Dra.gd, loves Cake and all things pertaining to remarkable Developer Experience