Updated code to mesh with get_weights returning a dict and new tf code (#187)

* Updated code to mesh with get_weights returning a dict and new tf code

* Added tf.global_variables_initalizer to hyperopt example as well

* Small fix.

* Small name change.
This commit is contained in:
Wapaul1
2017-01-07 14:25:45 -08:00
committed by Robert Nishihara
parent 0ac2abee51
commit c45342e39d
2 changed files with 6 additions and 5 deletions
+1 -1
View File
@@ -71,7 +71,7 @@ def train_cnn_and_compute_accuracy(params, steps, train_images, train_labels, va
# Do the training and evaluation.
with tf.Session() as sess:
# Initialize the network weights.
sess.run(tf.initialize_all_variables())
sess.run(tf.global_variables_initializer())
for i in range(1, steps + 1):
# Fetch the next batch of data.
image_batch = get_batch(train_images, i, batch_size)