During creating VAE model throws exception “you should implement a `call` method.”
问题 I want to create VAE(variational autoencoder). During model creating it throws exception. When subclassing the Model class, you should implement a call method. I am using Tensorflow 2.0 def vae(): models ={} def apply_bn_and_dropout(x): return l.Dropout(dropout_rate)(l.BatchNormalization()(x)) input_image = l.Input(batch_shape=(batch_size,28,28,1)) x = l.Flatten()(input_image) x = l.Dense(256,activation="relu")(x) x = apply_bn_and_dropout(x) x = l.Dense(128,activation="relu")(x) x = apply_bn