guides/writing_your_own_callbacks.py/EarlyStoppingAtMinLoss/on_train_end
class EarlyStoppingAtMinLoss:    def on_train_end(self, logs=None):
        if self.stopped_epoch > 0:
            print(f"Epoch {self.stopped_epoch + 1}: early stopping")