()
| 37 | |
| 38 | |
| 39 | def get_batch_data(): |
| 40 | trX, trY = load_mnist(cfg.dataset, cfg.is_training) |
| 41 | |
| 42 | data_queues = tf.train.slice_input_producer([trX, trY]) |
| 43 | X, Y = tf.train.shuffle_batch(data_queues, num_threads=cfg.num_threads, |
| 44 | batch_size=cfg.batch_size, |
| 45 | capacity=cfg.batch_size * 64, |
| 46 | min_after_dequeue=cfg.batch_size * 32, |
| 47 | allow_smaller_final_batch=False) |
| 48 | |
| 49 | return(X, Y) |
| 50 | |
| 51 | |
| 52 | def save_images(imgs, size, path): |