Time Delay Function In Python Definition Range