Batch Renders

_images/batch_diagram.png

Batches let you run multiple renders in a sequence automatically. These render jobs can use different scenes and settings that override the ones set in the scene.

Simply add and setup some render jobs, then click the Start Batch button to run the batch.

Step-by-step Workflow

  1. Start by adding a new render job (click the + button in the batch panel)
  2. Give it a name by changing the name property or double-clicking it’s name in the list
  3. Select a scene to render, if you leave it blank it will use the current one
  4. Optionally select a camera or specific view layer to use
  5. Set an output path for your job. This path must be different from other jobs, if you leave it blank the path set in the output panel will be used. Remember you can’t have two jobs with the same path though.
  6. Optionally set custom overrides for the job. See the Custom Overrides section to learn more.
  7. Repeat for each render job you want to include
  8. Optionally set batch settings by clicking the triangle icon next to the start button
  9. Click the Start batch button to start the batch rendering
  10. Kick back and relax :)

Render+ will switch to “Running Mode”. In this mode the job currently rendering will be automatically selected in the list and you will be able to see it’s progress and status below. You can click the X button to cancel that specific render job.

When the batch is finished the title of the panel will change to “Finished”. You can then select jobs again and check their finished and render times. When you want to go back to normal click the “close” button.

Under the hood

Render+ uses a small python application in the background called the Batch Server to manage renderjobs. The batch server communicates with the Render+ addon through a port via http. The addon takes care of starting the server, starting the batch, querying it’s status, and shutting down the server once the batch is done.

The batch server is queried every 2 seconds (by default) when running a batch. You can change this via the preferences.


Render+ uses the port 7777 by default. If you are having trouble starting batches, make sure you are not running another program that uses that port at the same time. You can also change the port number in the addon preferences.


Render job tabs

_images/batch_main.png

Scene Tab

Setting Description
Name An identifier for this render job
Scene Scene to use
Camera Camera to use (leave blank to use the current active camera)
World World to use (leave blank to use the current active world)
View Layer Use only a specific view layer (leave blank to use all enabled)
Animation Render an animation instead of a still image
Custom Frame Render a specific frame (for stills)
Frame Range Render a specific frame range (for animations)
Use External Use an external blend file
Blend File File path of the blend file to use for this job (when using external)

Render tab

Setting Description
Output File path to save to
Custom Size Image Size for this job in pixels
File Format Image/Video format to use
Samples Use a different number of samples to render (Cycles only)
Render Device Render using the CPU or choose a GPU (Cycles only)
Render Section Render only a part of the image
Threads Use a specific number of CPU threads

Some file formats may not be compiled in your version of Blender. Render+ will tell you when you select one of them.


If you set samples or threads to 0, Render+ will use the settings you have set in the scene. The same applies if you set Render  Device to “Default”.

Below the output setting you will also find the Show output folder button. Clicking this button will open the folder where the rendered image will be saved.

Toggling Render Section will show the coordinates of the section, as well as the Get from Viewport button. If you have a border render set (:kbd:Ctrl+B in camera view), you can get it’s coordinates automatically by clicking that button.

Custom tab

In this tab you can setup custom overrides for the render job. See Custom Overrides Below.

Custom Overrides

_images/batch_override.png

With custom overrides you can change the value of any property in the scene. All you need is the data path to the property and set the new value in the data column.

Custom Overrides can be used to change specific things for a render job, like color management settings, rig properties, enabling/disabling lights and more.

Click the + button to add a custom override and the - button to remove it. Clicking on the name of a Custom Override lets you change it, while toggling the checkbox next to them disables/enables them (just like in the render jobs list).

Below the new and remove buttons you will find the copy button. Clicking Copy will copy the data value to all render jobs, while adding the override to those that don’t have it. You can use this button to quickly set an override for the entire batch (for instance, setting a custom cycles sampling value).


Note that Render+ doesn’t check for value types or valid ranges, double check your data is valid! Also, don’t forget to add quotes to your strings (eg. “my_string”)


What are data paths?

All properties in Blender are organized in different modules and objects. Properties inside objects can be accessed with the dot syntax like so, bpy.module.object.property. Properties can be objects, or collections of objects and properties.

For an in-depth explanation and examples check the [Blender documentation] (http://www.blender.org/api/blender_python_api_2_72_0/info_api_reference.html)

Finding the data path

Data paths for all overrides are relative to bpy.context.scene. This makes it easier to find the path for a property, since you can simply right-click on any property and select Copy Data Path. You can then go into the data path input and paste it there (Ctrl+v).

If you’re modifying a scene property you don’t have to add anything else, but if the property comes from an object in the scene, you’ll have to add “objects[OBJECT_NAME].” before the path you pasted. Change ‘OBJECT_NAME’ to the name of the object you’re getting the property from.

Override examples

render.engine = ‘CYCLES’

Set render engine to Cycles


objects[‘Lamp’].hide_render = True

Hide object called “Lamp” for render |


objects[‘Cube’].material_slots[‘Material’].material = bpy.data.materials[‘New_mat’]

Set “New_mat” as material for “Cube” object

Global Settings

_images/batch_settings.png

Global settings are options that affect the batch or all the render jobs in it. To see the settings click the gear icon next to Start Batch.

Setting Description
Global Size Set a single size for all render jobs
Global Percentage Set a size percentage for all render jobs
Ignore Render Border Check to disable the render border setting for all jobs.
Overwrite Overwrite existing render files or skip them
Write log Files Write a log file for each job. If disabled, output will go into the terminal.
Write RSS File Check to write information to a RSS file (see below for more)
Use Terminal Run the batch inside a terminal
Power Off Suspend or shutdown the computer when the batch is done
Notifications Notify using the desktop, a sound or email

Log files are stored in the same folder as the rendered files. They are named “[OUTPUT_name]_log.txt“.

Global Size will ignore size percentages (set in the dimensions panel) and use the same size for all jobs.

The Terminal used for the Batch can be customized in the addon preferences.

The notifications system is the same as for single renders. Check out the notifications section in Main settings for more info.

Actions

_images/batch_actions.png

The actions tab let you setup commands to run before the batch starts and after it finishes. You can also run commands before and after each render job.

RSS

RSS is a format used to publish updates on dynamic content like blogs or podcasts. A RSS document is often called a “feed” or “channel”. These feeds can be read using web browsers, web sites, desktop applications, mobile apps and more.

Render+ can generate RSS feeds with information about running batches. You can use these feeds to monitor progress of any number of batches remotely.

To enable it first click the gear button next to the “Start Batch” button to see the global settings. Then check the “Write RSS File” checkbox and select a location to put the file in.

Render+ includes an item for each render job with information about it. The very first item in the list is a summary of the progress of the batch.

You can put the file anywhere in your computer if you intend to watch it only on your PC. If you want to monitor remotely you will have to put the feed in a publicly shared directory, like the Dropbox folder. Any folder that is visible from the web will be OK, all you need is the URL to access the file. You can see this file in your browser.

If you’re into customizing your desktop you could use an application like Geektool (Mac) or Conky (Linux) to show the RSS feed right over your wallpaper. KDE (Linux) also has support widgets to show RSS feeds.

For a (long) list of RSS readers check Wikipedia

Options menu

You can move render jobs up or down using the arrow buttons. Click the three-lines icon to access the following options.

Option Description
Duplicate Clone the selected render job
Move to Top/Bottom Move the current render job to the top or bottom
Enable/Disable all Enable or disable all jobs
Remove all render jobs Clear the batch list
Change output paths Change output paths on all render jobs

Change output paths

This option lets you change the output path of all render jobs at once.

This is done by first setting a Base Directory. This will be the base folder for all renders.

Next you can select what Sub directories to create (or not). You can organize renders into different directories by their scene, camera or view layer.

Next you can select the base filename and its suffixes. The base file name can be anything you want (as long as it is a valid file name). You can add up to three suffixes to it: Camera, Scene, or Renderlayer. Suffixes are added after an underscore like this: “my-render_camera”.

You can see a sample of an output path using the data from the first render job at the end. Once you are happy with the resulting outputs, click the Change Outputs button to set them.

Note that you can undo this action.

Previous Batch Results

If you keep Blender open while running a batch, you can access a log of the previous batch once it has finished.

Once the batch is complete, click the menu button next to the renderjob list and look for the Previous Batch Results button.

You can check out the start, finish and total rendertimes for the batch and for each job. You can also see some statistics about the batch including the average rendertime and the slowest and fastest renderjob.

External Render Jobs

External render jobs render scenes from other blend files. They are marked with a file icon in the batch list. You can make any render job use an external blend file by toggling the “use external” checkbox.

You can leave the output path blank in external jobs, Render+ will use the output from the blend file. This way you can set different paths in each blend file, and then have the batch process use them automatically.

You can also select multiple blend files and create render jobs for them automatically by using the “Add External Blends” option in the batch menu.

Scripting

You may be interested in scripting to extend R+ to fit your own needs better. You can find everything batch related in bpy.context.scene.renderplus.batch. These are the properties contained in it:

Property Description
jobs List of render jobs
index Int, Index of the currently selected job in the ui
use_rss Boolean, True to write a RSS file
rss_path String, Filepath for RSS file
write_logs Boolean, True to write log files
use_global_size Boolean, True to force a specific size
global_size_x Int, horizontal global size in pixels
global_size_y Int, vertical global size in pixels
ignore_border Boolean, True to disable render border

Each job in the list contains the following properties:

  • name
  • scene
  • layer
  • camera
  • enabled
  • size_custom
  • size_x
  • size_y
  • animation
  • frame_custom
  • frame_still
  • frame_start
  • frame_end
  • output
  • use_external
  • blend_file (only set if use_external is True)
  • overrides

Animation, size_custom and frame_custom are booleans used to enable or disable settings.

You can add new jobs with bpy.context.scene.renderplus.batch.jobs.add(). Use the python console to know more.

You can also import Render+ modules and inspect them in the python console:

>>> import renderplus
>>> import renderplus.stats
>>> renderplus.stats.is_animation()
True
>>> help(renderplus.stats.is_running)
Help on function is_animation in module renderplus.stats:
 is_animation()
    Detect if we are rendering an animation.

You may also want to run Blender from a console or terminal to watch the output. Check the manual to launch blender from a terminal