Beispiel #1
0
 def testTrainMnistMultitower(self):
     with tf.Graph().as_default():
         # Ensure model training doesn't crash.
         convnet.train_mnist_multitower(data_dir=None,
                                        num_epochs=1,
                                        num_towers=2,
                                        use_fake_data=True)
Beispiel #2
0
def main(argv):
  _ = argv

  if FLAGS.num_towers > 1:
    convnet.train_mnist_multitower(
        FLAGS.data_dir, num_epochs=200, num_towers=FLAGS.num_towers)
  else:
    convnet.train_mnist_single_machine(FLAGS.data_dir, num_epochs=200)
def main(unused_argv):
  _ = unused_argv
  assert FLAGS.num_towers > 1
  devices = ["/gpu:{}".format(tower_id) for tower_id in range(FLAGS.num_towers)]
  convnet.train_mnist_multitower(
      FLAGS.data_dir,
      num_epochs=200,
      num_towers=FLAGS.num_towers,
      devices=devices)
 def testTrainMnistMultitower(self):
   with tf.Graph().as_default():
     # Ensure model training doesn't crash.
     convnet.train_mnist_multitower(
         data_dir=None, num_epochs=1, num_towers=2, use_fake_data=True)