santi-pdp/segan

why cann't concat (x0 and diff) (tf版本问题,concat的参数位置换了)

353xiong opened this issue · 0 comments

def pre_emph(x, coeff=0.95):
x0 = tf.reshape(x[0], [1,])
diff = x[1:] - coeff * x[:-1]
# print(x.shape)
# print(x0.shape)
# print(diff.shape)
concat = tf.concat(0, [x0, diff])
return concat

concat = tf.concat(0, [x0, diff])

ValueError: Dimension 0 in both shapes must be equal, but are 1 and 16383. Shapes are [1] and [16383].
From merging shape 0 with other shapes. for 'device_0/concat/concat_dim' (op: 'Pack') with input shapes: [1], [16383].