Both should work fine.
If you see issues with modifying inplace values needed for gradient computation, you can swap them to use the out of place versions.
Oh so does this mean that inplace may cause some trouble in back-propagation? I ask this almost all codes of ResNet including the Pytorch official release always set the inplace flag as true, maybe to save memory usage.
Thankyou