change the index of batches