CallBacks
callback的作用是在训练模型时,能够记录中间参数或者提前停止训练等操作的函数
CallBack种类
重写callback
class MyCallback(tf.keras.callbacks.Callback):
def __init__(self):
pass
def on_train_begin(self, logs=None):
print("on train begin")
def on_train_end(self, logs=None):
print("on train end")