adding the batching of the data