AWS Thinkbox Discussion Forums

Custom Plugin: Multiple Iterations Per Job

I made my own custom deadline plug in. Currently, I’m iterating on a range based on an integer provided by the plugin file. Each iteration is a task. This is based on the setting Frames=(my iteration range) and setting chunkSize=1.

This works fine atm, but I am going to need to split each of those iterations into a “subtask” for each task.

So, for example, say I have a frames=0-5 with a chunkSize=2 and I want to iterate this 3 times. So the monitor would get 9 tasks

task-00 frames 0-1 iteration-0
task-01 frames 2-3 iteration-0
task-02 frames 4-5 iteration-0
task-03 frames 0-1 iteration-1
task-04 frames 2-3 iteration-1
task-05 frames 4-5 iteration-1
task-06 frames 0-1 iteration-2
task-07 frames 2-3 iteration-2
task-08 frames 4-5 iteration-2

Where does deadline figure out the number of tasks? Where can I modify my plugin to implement this?
Thanks

Up your chunk size and you’ll get a bigger range between GetStartFrame() and GetEndFrame().

I suppose the best example of what you’re trying to do what we ship in Deadline is tile rendering animations. In some apps, we break the sequences’ tiles into tasks and each task has a frame range it’ll render through. In that case, we don’t really use the frame range for its intended purpose and use it instead as a tile index.

You could do the same here and either divide and floor the frame number by the task to be done, or do the fancy thing and chain jobs together.

operation = int(frame / iteration)
frame = frame % iteration

I’m a much bigger fan of chaining jobs together for this, but it depends on what your timeline is to get results.

Thanks for the response Edwin,
After evaluating the job needs, it was easier just to break it up into multiple jobs with dependencies. The use of tiles is interesting though.
Cheers

Welcome!

Privacy | Site terms | Cookie preferences