How to round a number to nearest integer using python
My actual code:
print( "Loss ~ " + str( loss_final ))
Now I am trying to round the number to nearest integer, so I modified my code to:
print( "Loss ~ " + round(str( loss_final )))
But it always giving me error:
TypeError: type str doesn't define __round__ method
Any solution for this??