This commit is contained in:
jakubknczny 2021-05-16 16:02:00 +02:00
parent b60408e2e8
commit c815688698

View File

@ -36,14 +36,14 @@ def prepare_train_model(learning_rate, _run):
model.compile( model.compile(
loss=tensorflow.keras.losses.BinaryCrossentropy(), loss=tensorflow.keras.losses.BinaryCrossentropy(),
optimizer=tensorflow.keras.optimizers.Adam(lr=learning_rate), optimizer=tensorflow.keras.optimizers.Adam(learning_rate=learning_rate),
metrics=[tensorflow.keras.metrics.BinaryAccuracy()]) metrics=[tensorflow.keras.metrics.BinaryAccuracy()])
history = model.fit(X_train, Y_train, epochs=2, validation_data=(X_valid, Y_valid)) history = model.fit(X_train, Y_train, epochs=2, validation_data=(X_valid, Y_valid))
model.save('grid-stability-dense.h5') model.save('grid-stability-dense.h5')
_run['history'] = history _run['history'] = str(history)
@ex.main @ex.main
def my_main(learning_rate): def my_main(learning_rate):