4
Tensorflow有以下功能:TensorFlow:Hadamard产品::我如何得到这个?
tf.matmul
,它乘两个向量,并产生一个标量。
不过,我需要做到以下几点:
# dense dim: (?,227)
dense_part = tf.nn.relu(some stuff here)
# softmax matrix dim: (?,227,19) or (?,19,227) or (?,227,227), where I
# ....can slice the last dim down to (?,227,19)
softmax_matrix = tf.matmul(dense_part,softmax_weight_variable)
然而,有什么我可以为了与矩阵乘法来完成这个设置softmax_weight_variable来。我需要使用“张量产品”(也称为“外部产品”...),但该功能似乎没有实现。
如何在TensorFlow中实现Hadamard(单元)乘法和外积?
真棒,谢谢 – bordeo