Some modification to Temporal histogram