def _accumulated_batches_reached(self):
    return (((self.trainer.batch_idx + 1) % self.trainer.accumulate_grad_batches) == 0)
def _accumulated_batches_reached(self):
    return (((self.trainer.batch_idx + 1) % self.trainer.accumulate_grad_batches) == 0)