I built a Keras model with a custom layers, and it was saved to a .h5
file by the callback ModelCheckPoint
.
When I tried to load this model after
From the answer of "LiamHe commented on Sep 27, 2017" on the following issue: https://github.com/keras-team/keras/issues/4871.
I met the same problem today : ** TypeError: init() missing 1 required positional arguments**. Here is how I solve the problem : (Keras 2.0.2)
def get_config(self):
config = super().get_config()
config['pool_size'] = # say self._pool_size if you store the argument in __init__
return config