Store counters in batches. Better logging of times