Differentiable Path Tracing by Regularizing Discontinuities