Batching code done
Batches working