sktime / mlaut

Other
24 stars 5 forks source link

Code crashes when loading saved keras model #23

Closed ViktorKaz closed 6 years ago

ViktorKaz commented 6 years ago

There is a circular reference error when trying to load saved keras models from disk.

ViktorKaz commented 6 years ago

This was caused by a circular reference when calling predict_class() from the mlaut.estimators.nn_estimators.OverwrittenSequentialClassifier

Fixed by calling predict() and calculating the max:

predictions = Sequential.predict(self, X_test, batch_size=batch_size, verbose=verbose)
return predictions.argmax(axis=1)