keras/src/trainers/data_adapters/py_dataset_adapter.py/PyDatasetAdapter/on_epoch_end
class PyDatasetAdapter:    def on_epoch_end(self):
        if self.enqueuer:
            self.enqueuer.stop()
        self.py_dataset.on_epoch_end()