Round Tensor to x decimal places

No, the rounding function is a step function and almost everywhere differentiable as explained in this post.
However, since it’s a step function the gradient will be zero almost everywhere, so it’s not really usable in training the model.

1 Like