Reset counters when starting a new file