That depends on a few different things. Is your 3D rendered with a gamma correction, i.e. in sRGB? Or is it pure linear light?
The recommended workflow would be something like:
log2lin your backplate scans so they are in linear light
If your 3D is already linear you can now comp the images together, if not, convert from sRGB to linear light and comp.
To look at all this (because the linear light looks very dark on a monitor) view it through a gamma of 2.2 (which it very close to a linear light -> sRGB conversion).
What you need to do when outputting these depends on the delivery media. If you’re going back to film you’re probably delivering DPXs again. In this case you should convert from linear light to log in the end with a log2lin node.
Hope it make sense!
Cheers,
David