Delete Iterations via Python?

Wherever you see these lines in the Autodesk sample script:

for iteration in batch_group.batch_iterations:
flame.delete(iteration, confirm=False)

You could change it to:

for iteration in batch_group.batch_iterations[:-5]:
flame.delete(iteration, confirm=False)

This will prevent it from deleting the last 5 iterations in a batch group as it runs the delete loop.

Mike

3 Likes