Solved the history length problem with larger granularity time