Cast to int for python 3