Commit c7c3970c authored by Shaoning Zeng's avatar Shaoning Zeng Committed by Taylor Robie
Browse files

fix issue 'could not satisfy explicit device' (#3641)

* fix issue 'could not satisfy explicit device'

* remove the line unrelated to fix issue
parent 32aa6563
...@@ -552,6 +552,8 @@ def main(_): ...@@ -552,6 +552,8 @@ def main(_):
# Merge all summaries together. # Merge all summaries together.
summary_op = tf.summary.merge(list(summaries), name='summary_op') summary_op = tf.summary.merge(list(summaries), name='summary_op')
# Add config to avoid 'could not satisfy explicit device' problem
sess_config = tf.ConfigProto(allow_soft_placement=True)
########################### ###########################
# Kicks off the training. # # Kicks off the training. #
...@@ -567,7 +569,8 @@ def main(_): ...@@ -567,7 +569,8 @@ def main(_):
log_every_n_steps=FLAGS.log_every_n_steps, log_every_n_steps=FLAGS.log_every_n_steps,
save_summaries_secs=FLAGS.save_summaries_secs, save_summaries_secs=FLAGS.save_summaries_secs,
save_interval_secs=FLAGS.save_interval_secs, save_interval_secs=FLAGS.save_interval_secs,
sync_optimizer=optimizer if FLAGS.sync_replicas else None) sync_optimizer=optimizer if FLAGS.sync_replicas else None,
session_config=sess_config)
if __name__ == '__main__': if __name__ == '__main__':
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment