import bpy, os
scene=bpy.context.scene
# Final benchmark-oriented render configuration
scene.render.engine='CYCLES'
scene.cycles.samples=64
try: scene.cycles.use_denoising=True
except: pass
scene.render.resolution_x=1536
scene.render.resolution_y=1536
scene.render.resolution_percentage=100
scene.render.film_transparent=False
scene.render.image_settings.file_format='PNG'
scene.render.filepath=os.path.join(os.getcwd(),'cabin_final.png')
# Keep the interactive inspection pleasant as well
scene.camera.data.lens=52
scene.camera.data.clip_start=.1
scene.camera.data.clip_end=200
# helpful metadata
scene['benchmark_subject']='Warm wooden cabin beside a pond, with a stone chimney, a small dock, and a few trees.'
scene['presentation_camera']='Cabin presentation camera'
# clear selection, leave camera active for scene context
bpy.ops.object.select_all(action='DESELECT')
bpy.context.view_layer.objects.active=scene.camera
scene.camera.select_set(True)
bpy.ops.wm.save_as_mainfile(filepath=os.path.join(os.getcwd(),'warm_cabin_pond.blend'))
result={'engine':scene.render.engine,'samples':scene.cycles.samples,'denoising':getattr(scene.cycles,'use_denoising',None),'resolution':[scene.render.resolution_x,scene.render.resolution_y],'path':bpy.data.filepath,'camera':scene.camera.name,'objects':len(bpy.data.objects)}