We want to support python 3 so please avoid the print statement. Also, you can display the output on stdout directly:

```
from __future__ import print_function  # at the top of the file

print("\r%s" % progress(stats), end='')
```