Last active
October 14, 2017 10:49
-
-
Save hagerty/a62b37b5d32ab076ad85f1d3798ea845 to your computer and use it in GitHub Desktop.
Training CosmiQNet using Tensorflow
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with tf.Session(config=tf.ConfigProto(log_device_placement=True)) as sess: | |
sess.run(ginit) | |
global_step = 0 | |
for i in range(layers): | |
for step in range(FLAGS.max_layer_steps): | |
global_step += 1 | |
random_input8, random_input3, random_label = GetRandomInput( labels, im_raw8, im_raw3, FLAGS.batch_size, FLAGS.ws, scale) | |
sess.run(label_optimizer[i],feed_dict={x8: random_input8, x3: random_input3, label_distance: random_label}) | |
for step in range(5*FLAGS.max_layer_steps): | |
global_step += 1 | |
random_input8, random_input3, random_label = GetRandomInput( labels, im_raw8, im_raw3, FLAGS.batch_size, FLAGS.ws, scale) | |
sess.run(full_label_optimizer[i],feed_dict={x8: random_input8, x3: random_input3, label_distance: random_label}) | |
gsaver.save(sess, './checkpoint/boundary_'+str(i)) | |
gsaver.save(sess, './checkpoint/boundary') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment