回答編集履歴

1

d

2019/08/15 05:49

投稿

tiitoi
tiitoi

スコア21956

test CHANGED
@@ -1,4 +1,4 @@
1
- numpy 同様、演算 * は要素ごとの積になるので、行列積 (matrix multiplication) を計算したい場合は `tf.matmul` をお使いください。
1
+ numpy 同様、演算 * は要素ごとの積になるので、行列積 (matrix multiplication) を計算したい場合は `tf.matmul` または `@` 演算子をお使いください。
2
2
 
3
3
 
4
4
 
@@ -22,6 +22,8 @@
22
22
 
23
23
  y = tf.matmul(tf.reshape(x, (3, 1)), W)
24
24
 
25
+ # y = tf.reshape(x, (3, 1)) @ W でもよい。
26
+
25
27
 
26
28
 
27
29
  with tf.Session() as sess: