Skip to content

Commit 7c5bfb9

Browse files
committed
changed tests to save to keras format.
1 parent 273f914 commit 7c5bfb9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

keras_mdn_layer/tests/test_mdn.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,6 @@ def test_save_mdn():
3737
model.add(keras.layers.Dense(N_HIDDEN, batch_input_shape=(None, 1), activation='relu'))
3838
model.add(mdn.MDN(1, N_MIXES))
3939
model.compile(loss=mdn.get_mixture_loss_func(1, N_MIXES), optimizer=keras.optimizers.Adam())
40-
model.save('test_save.h5', overwrite=True, save_format="h5")
41-
m_2 = keras.models.load_model('test_save.h5', custom_objects={'MDN': mdn.MDN, 'mdn_loss_func': mdn.get_mixture_loss_func(1, N_MIXES)})
40+
model.save('test_save.keras', overwrite=True)
41+
m_2 = keras.models.load_model('test_save.keras', custom_objects={'MDN': mdn.MDN, 'mdn_loss_func': mdn.get_mixture_loss_func(1, N_MIXES)})
4242
assert isinstance(m_2, keras.Sequential)

0 commit comments

Comments
 (0)