小编use*_*401的帖子

函数调用堆栈:keras_scratch_graph 错误

我正在重新实现一个 text2speech 项目。我正面临一个函数调用堆栈:解码器部分的keras_scratch_graph错误。网络架构来自 Deep Voice 3 论文。

我在 Google Colab 上使用来自 TF 2.0 的 keras。下面是解码器 Keras 模型的代码。

y1 = tf.ones(shape = (16, 203, 320))
def Decoder(name = "decoder"):
    # Decoder Prenet
    din = tf.concat((tf.zeros_like(y1[:, :1, -hp.mel:]), y1[:, :-1, -hp.mel:]), 1)
    keys = K.Input(shape = (180, 256), batch_size = 16, name = "keys")
    vals = K.Input(shape = (180, 256), batch_size = 16, name = "vals")
    prev_max_attentions_li = tf.ones(shape=(hp.dlayer, hp.batch_size), dtype=tf.int32)
    #prev_max_attentions_li = K.Input(tensor = prev_max_attentions_li)
    for i …
Run Code Online (Sandbox Code Playgroud)

python nlp keras tensorflow tensorflow2.0

12
推荐指数
2
解决办法
2万
查看次数

标签 统计

keras ×1

nlp ×1

python ×1

tensorflow ×1

tensorflow2.0 ×1