I agree that programmatically, it would make more sense to simply include the delta value as an additional parameter in both the functional and module versions of Smooth_L1. I have made a new commit based on the comments. Many thanks!