Convert timestamps to numbers for subtraction