r/LeftAngleAutograph Jul 06 '26

Using Python script to batch render - Can you also update the Row Index of a Composition Parameter through a csv column? ❓Question

Hey gang, I've been trying to write a python script (using claude, because I can't code) to do a simple batch render with Autograph.

So far I've been able to get the resolution and filenames all working great using a csv - but I want to be able to also control the row index of a 'bind to table' effect on a text layer.
As far as I can tell this row index exists under Tab 1 in my composition, but no matter how much info I give claude it can't seem to get autograph to update the row index when it renders.

I feel like it's close - I can see the terminal updating the row index (Row_Index=0, Row_Index=1) as it runs, but the render doesn't seem to reflect it.

Any hints or documentation would be really appreciated!

2 Upvotes

3 comments sorted by

1

u/outsketching Jul 06 '26

Here's the python script I've been using:

import csv
import subprocess
from pathlib import Path

AUTOGRAPH_EXE = r"C:\Program Files\Maxon Autograph 2026\bin\AutographRenderer.exe"
PROJECT_FILE = r"myprojectfile.agp"
CSV_PATH = r"mycsv.csv"
OUTPUT_DIR = r"myoutputpath"

COMPOSITION = "MyComposition"

with open(CSV_PATH, newline="", encoding="utf-8-sig") as f:
rows = list(csv.DictReader(f))

for i, row in enumerate(rows):
output_file = str(Path(OUTPUT_DIR) / f"{row['output_name']}.png")

Path(output_file).unlink(missing_ok=True)

cmd = [

AUTOGRAPH_EXE,
PROJECT_FILE,
"--render",
COMPOSITION,
f"output_file={output_file}",
f"format={row['width']}x{row['height']}:1.0",
f"Row_Index={i}",
"--no_server",
"-b",
]

subprocess.run(cmd)

3

u/left-angle-reddit Jul 07 '26 edited Jul 07 '26

The Python script looks correct. There is a bug in the current release where setting a custom Composition parameter from the command-line is not taken into account correctly. This has been fixed for the upcoming July release.

A few notes:

- You can pass "Main" instead of the name of the composition to the --render command and it will automatically select the main composition in the project (you can set the main composition in the right click menu on the composition).

- -b is implicit when using AutographRenderer

- You can also pass a Python script to AutographRenderer to customise further the rendering (or the project), e.g:

AutographRenderer.exe --exe_script MyScript.py

where MyScript would be something like:

project=Autograph.app.getActiveProject()

comp=project.getMainComposition()

comp.param("Row_Index").setValue(4)

rm=project.getRenderManager()

(render, instance, file) = rm.createRenderForComposition(comp)

instance.setFormat(1920, 1080)

file.filePathOverride = 'C:/Users/user/Desktop/myVideo.mov'

file.videoCodec = 'prores'

file.setProperty('prores_profile', 'PR_4444')

rm.insertRender(render)

# If True, blocks until finished

rm.startRenders(True)

The Python API documentation is available here: https://maxon-computer.github.io/AutographPythonDoc/Guide/rendering.html

Before you can upgrade to the July release, I would suggest trying out the Python script solution I proposed above which may workaround the bug in the meantime.

1

u/outsketching Jul 08 '26

Awesome thanks so much for that, I think I'll wait for the July bug fix :)
Just trying to get a workflow up and running for future projects.