I might need some help with implementing an specific regularization term for the loss function. It does however not have a gradient and I wonder if there is any way of changing