Calculates the rounding of a tensor.