質問編集履歴

1

不足コードの追加

2019/03/04 08:26

投稿

Yhaya
Yhaya

スコア439

test CHANGED
File without changes
test CHANGED
@@ -11,6 +11,10 @@
11
11
 
12
12
 
13
13
  # 学習に使ったモデル
14
+
15
+ 訓練データはKaggleのMNISTのデータを使っています。
16
+
17
+
14
18
 
15
19
  ```python
16
20
 
@@ -154,6 +158,18 @@
154
158
 
155
159
 
156
160
 
161
+ saver = tf.train.Saver()
162
+
163
+
164
+
165
+ with tf.Session() as sess:
166
+
167
+ saver.restore(sess, './my_model_final.ckpt')
168
+
169
+ pred = logits.eval(feed_dict={X: X_train})
170
+
171
+
172
+
157
173
  result = np.argmax(pred, axis=1)
158
174
 
159
175
  ```