Real-time clock offset prediction with an improved model