Open t04925yy opened 4 years ago
I'm sorry that I was using old version. Tensorflow2.2 version worked.
Yes, that _Merge
is not supported in keras
Edit That RandomWeightAverage function to this...( TF 2.4 works!!! )
class RandomWeightedAverage(tf.keras.layers.Layer):
def __init__(self, batch_size):
super().__init__()
self.batch_size = batch_size
def call(self, inputs, **kwargs):
alpha = tf.random_uniform((self.batch_size, 1, 1, 1, 1))
return (alpha * inputs[0]) + ((1 - alpha) * inputs[1])
def compute_output_shape(self, input_shape):
return input_shape[0]
Trouble about
from keras.layers.merge import _Merge
at second line in MuseGan.py. It seems that_Merge
is no longer supported in Keras.Will you update this file?