broadinstitute / keras-resnet

Keras package for deep residual networks
Other
300 stars 127 forks source link

Unable to serialize a resnet model to a saved model #64

Open cbodenst opened 4 years ago

cbodenst commented 4 years ago

The newest keras version allow us to save models not only as .h5 keras files, but also as saved model.

However, custom layers must be correctly declared to support this.

I.e the BatchNormalization layer should define its signature for "call" properly as: def call(self, inputs, **kwargs): instead of

def call(self, *args, **kwargs):

You can read more about this issue here: https://github.com/tensorflow/tensorflow/issues/38384