Why do we process all minibatches in an epoch?

Tiny detail:

We don’t have to process all mini batches of underlying data in every epoch (please see this topic)

See this link for more onsteps_per_epoch parameter.