How to render some of view layers only (instead of single or all of them)
If you have several layers, every layer has an "Use for Rendering" option. Tick this on all the layers you want and untick all you do not need. That's it.



The python property is ViewLayer.use, which you can access for each layer per data-block: bpy.data.scenes["Scene"].view_layers["LayerName"].use or per scene in context: bpy.context.scene.view_layers["LayerName"].use.