How To Time A Function Python Format Datetime