Commit f4148788 authored by W.D.R.P. Sandeepa's avatar W.D.R.P. Sandeepa

Merge branch 'it18218640' into 'master'

create model folder and ModelCheckpoint

See merge request !97
parents 203f9019 880597f3
...@@ -105,6 +105,9 @@ def main(): ...@@ -105,6 +105,9 @@ def main():
input_shape = (X_train.shape[1], X_train.shape[2], X_train.shape[3],) input_shape = (X_train.shape[1], X_train.shape[2], X_train.shape[3],)
model = build_model(input_shape, LEARNING_RATE) model = build_model(input_shape, LEARNING_RATE)
# check Point
checkpoint = ModelCheckpoint('models/model-{epoch:03d}.h5', monitor='val_loss', save_best_only=True, mode='auto')
# train the model # train the model
history = model.fit(X_train, y_train, epochs=EPOCHS, batch_size=BATCH_SIZE, validation_data=(X_validation, y_validation)) history = model.fit(X_train, y_train, epochs=EPOCHS, batch_size=BATCH_SIZE, validation_data=(X_validation, y_validation))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment