fix
parent
24375b392b
commit
757946c078
|
@ -488,6 +488,7 @@ class eNoseTrainer:
|
|||
df.to_excel(f"{model_file}.search.xlsx", index=False)
|
||||
|
||||
self.logger.info(f"Training Model {model_id} with {study.best_params}")
|
||||
|
||||
early_stopping = keras.callbacks.EarlyStopping(monitor='loss', patience=5, restore_best_weights=True, min_delta=0.0003)
|
||||
best_model.fit(X_train, Y_train, epochs=epochs, batch_size=best_batch_size, verbose=1, callbacks=[early_stopping])
|
||||
|
||||
|
@ -578,7 +579,8 @@ class eNoseTrainer:
|
|||
df.to_excel(f"{model_file}.search.xlsx", index=False)
|
||||
|
||||
self.logger.info(f"Training Model {model_id} with {study.best_params}")
|
||||
early_stopping = keras.callbacks.EarlyStopping(monitor='loss', patience=5, restore_best_weights=True)
|
||||
|
||||
early_stopping = keras.callbacks.EarlyStopping(monitor='loss', patience=5, restore_best_weights=True, min_delta=0.0003)
|
||||
best_model.fit(X_train, Y_train, epochs=epochs, batch_size=best_batch_size, verbose=1, callbacks=[early_stopping])
|
||||
|
||||
best_model.save(f"{model_file}.keras")
|
||||
|
|
Loading…
Reference in New Issue