Math and a Blender Render Farm

So, while setting up a local render farm, the question dawned on me if I use my desktop, my wife’s desktop, and her laptop as members of my render farm, how long should it take to do a routine render?

Case in point, my current project has several renders that are 700 frames long. My desktop can render one of those frames in 5.43 seconds. My wife’s desktop in about the same time. Her laptop does a frame in 11 seconds.

Using the House Painter Formula,
t = time it will take all the computers to complete a 700 frame render.
My desktop = 5.43 * 700 = 3801 seconds to complete the render
Wife’s desktop = 5.43 * 700 = 3801 seconds as well.
Wife’s laptop = 11 * 700 = 7700 seconds
So 1/t = 1/3801 + 1/3801 + 1/7700
So 1/t = 0.0002630887 + 0.0002630887 + 0.0001298701
So 1/t = 0.0006560475
Invert = t = 1524 seconds
1524/60 seconds = 25.4

(About 25.4 minutes)

Why would the formula include all 700 frames for each unit of the farm? The two desktops will render more frames than the laptop, and none will render all 700.

Well, the way the “House Painter Formula” works is to use the rate all parties complete a given task in. So in my case, the given task is 700 frames. It is how quickly a computer can do a task that determines its speed.

I still don’t know that once all three computers do a task, how many frames each computer rendered.

Any ideas, anyone?

Just render the first frame on each computer and do the math. I recently suggested a place be put into this forum for ppl to post jobs they need help rendering, so that we could say render 50 frames and post links to the finished frames. Everyone here should have a dropbox or some other cloud service. Seems a pretty simple thing to me. I wouldn’t mind helping ppl out with a few hours of rendering.

That’s where I’m stuck at. Referencing my first post, my computer and my wife’s desktop both render a frame at about 5.43 seconds each. Her laptop does one at about 11 seconds. So what is the math that says how many of the 700 frames each computer did in the 25.4 minutes?

take the total task time, 24 minutes and some seconds, and divide it by the time it takes a particular computer to do one frame. That will tell you how many frames that particular computer will do in the allotted time.

Give yourself a bit of overlap when assigning frames to each computer, in case some of the frames take more or less time than your test frames.

So , according to your post, if I divide 25.4 minutes by 5.43 seconds, I get 4.67, whatever that number means. So how many frames did my computer render of the 700 frames?

I stand corrected. You’re absolutely right. If my total render time takes 25.4 minutes and I multiply it by 60 seconds, I get 1524 seconds. Then I divide 1524 by 5.43 seconds, I get 280 frames. So my wife’s and my desktop would render 280 frames each. Now comes her laptop. It renders a frame in 11 seconds, so I divide that by 1524, I get 138 frames. So the “BrentNewton Theorem” states: 280 + 280 + 138 = 698. Close enough for the overlap you mentioned.

tn/60= estimated time to render where t is time needed to render 1 frame and n is the total number of frames being rendered, and you divide by 60 to convert from seconds to minutes. The reason for the variables is that these numbers will be different on each machine. If the laptop renders at 11 sec/frame then the math would look like 11sec * 100/60= 18mins This is if you set 100 frames to render. You are going to want to optimize by having the 2 faster computers render 2x as many frames as the laptop as the laptop takes 2x as long to render. 291 on both computers and the remaining 118 on the laptop. So your total time is:
(t
n/60)= render time for machine 1
(tn/60)= render time for machine 2
(t
n/60)= render time for machine 3

Oops I didn’t read all the posts before posting. Seems you figured this out on ur own.

Then how did it wind up getting called the “BrentNewton Theorem”? According to Brent, you need to know how many frames you are going to render on each machine before you begin. He says

t*n/60= estimated time to render where t is time needed to render 1 frame and n is the total number of frames being rendered, and you divide by 60 to convert from seconds to minutes
but it’s obvious from his example that he means the total frames alloted to each machine

the math would look like 11sec * 100/60= 18mins This is if you set 100 frames to render

so according to the BrentNewton Theorem you need to know how many frames you are going to render on each machine in order to figure out how many frames to render on each machine.

He throws out some plausible numbers 291 frames on each computer, and 118 on the laptop, (based on the questionable math that 291 is 118 times 2… but whatever) and follows up with a formula to calculate total render time

t(tn/60)+(tn/60)+(t*n/60)=Total time.

which, if you plug his numbers in, looks like

(5.43291/60)+(5.43291/60)+(118*11/60)=(26.25 min)+(26.25 min)+(21.6 min)=74 minutes= Total time.

74 minutes? Really? When the House Painter method (which is correct, by the way) already tells you the total time is only 24 minutes and some change?

Tommyknocker45, some friendly advice: don’t ask Brent math questions, he’s no good at it.

and BrentNewton, please don’t give people math advice, you’re no good at it.

5.43*700= 63mins. Oh… I see what you did. You forgot that all those times are running concurrently. So it only takes 26mins to finish the whole render. Sorry that was actually my mistake. My bad. You could shave a couple minutes off by putting more on the laptop. I didn’t bother to do the math very well. Duned’it in me head, I did. Yeah you don’t add the render times from each computer obviously.

Oh and this is just basic math. If I thought about it though I bet I could work out a formula that will tell you exactly how many frames to put on each machine and how long it will take to render the whole job no matter how many there are or what their differences. I’ll think on that.

you figure out how many frames to render on each machine by looking at each machines render time. If one machine renders a frame at 5secs and another at 8secs, then you are going to give the one that renders at 8sec less. In this particular case the laptop rendered at nearly 2x the time so I just divided the total frames by 3 (for the 3 machines) and then did a quick and inaccurate mental calculation to give the 2 faster machines 2x as many frames. I’m pretty sure I explained all this in a post above, so I can deduce that Orinoco is just fucking with me by being purposefully obtuse.

You see what I did? It was your formula, Brent.

So your total time is: (tn/60)+(tn/60)+(t*n/60)=Total time.

That has one meaning, and one meaning alone. I didn’t “forget” that these times are running concurrently. The formula, YOUR formula, says: add them up. Period.

You don’t have to spend a lot of time thinking about a formula to figure out how many frames to put on each machine, it’s already outlined in the first post (it is the classic House Painter problem), which tells you how long the whole job takes, and then it is indeed simple math to divide the total time by the time each machine takes to render a frame to get the frames to be assigned to each machine.

If this isn’t clear to you, it’s not because I am being purposefully obtuse, or because I’m fucking with you. It’s because your seat-of-the-pants quick and dirty calculations aren’t up to doing relatively simple problems like this.

As I said, please don’t give people math advice. You aren’t any good at it. I’m not trying to bust your chops, Brent, but seriously, don’t give up the day job to teach math.

My bad I didn’t even read the house painter post part. I may have gotten a bit carried away trying to appear smarter than I actually am in my previous posts. I don’t think my math was flawed though. Just obvious mistake on my part. That house painters math still doesn’t show you how many frames to put into each machine. Should I edit my post so as not to confuse anyone reading it? I don’t know what the proper protocol is for such things. I edited my previous post so it’s not as wrong anymore. Don’t worry you have documented my mistake in your posts Orinoco. No one is going mistakenly think I’m good at math.

I meant to call it the “Orinco Theorem”. I apologize.

Of course, the render farm takes a blender file and loads it to all three computers and all three computers render all the images at the same time. The rendered images are all saved to a folder on a mapped hard drive all the computers can access. So my computer starts rendering frame one. My wife’s desktop starts to render, detects frame one is already being rendered, so starts to render frame two, etc.

So in a perfect world, this worked until all the frames were rendered.

Unfortunately, my wife’s desktop would stop rendering for no apparent reason. But I discovered, that if I told it to start rendering at for instance frame 420, the remaining computers would just be getting to frame 419 just as my wife’s desktop reached frame 700.

I just needed to know what frame to start her computer rendering at, and the “Orinco Theorem” solves all my issues. Good work gurus!

Yeah I’ve not yet been able to get the network render to work correctly. But honestly I haven’t tried very hard. I just copy my blend file to each computer and set them to render different chunks of the animation then collect them when its done. Not as elegant as a netrenderer but it works with none of the headaches.

I once had a whole classroom full of computers running 3DSMax to myself for a few hours after class before the building closed, and most of the day on Saturday if I had a project to work on. Unfortunately it wasn’t set up as a render farm at all. So I’d spend the afternoon trucking my thumb drive from computer to computer, checking on renders, fixing stuff and re-rendering, and adding sound tracks and effects to finished shots. Such fun.

Looks like there isn’t much point connecting my boxes and laptop with a render server, then. That’s ok. I still have my thumb drive.

Then I humbly suggest:

Ira Krakow’s Free Blender 3D Render Farm Tutorial (cf.) http://www.youtube.com/watch?v=mJWFRFystJU

It’s basically your set up and the one I like using, plus you don’t have to collect anything. All the frames are saved to the same location you want them to.

@Orinco, I like the fact all the frames are rendered to the same location when the render farm is set up.