예제 #1
0
def compute_predictions(sess, x, preds_op, images, batch_size):
    images = images[:100]
    preds = run_batches(sess, preds_op, [x], [images], batch_size)
    print(preds)
예제 #2
0
def compute_logits(sess, x, logits_op, images, batch_size):
    images = images[:100]
    logits = run_batches(sess, logits_op, [x], [images], batch_size)
    for l in logits:
        print(l)
예제 #3
0
def compute_predictions(sess, x, preds_op, images, batch_size):
    # images = images[:100]
    return run_batches(sess, preds_op, [x], [images], batch_size)
예제 #4
0
def evaluate(sess, x, y, pred_op, images, labels, batch_size):
    preds = run_batches(sess, pred_op, [x], [images], batch_size)
    acc = np.sum(preds == labels) / len(labels)
    print("accuracy: %0.04f" % acc)
예제 #5
0
def compute_logits(sess, x, logits_op, images, batch_size):
    # images = images[:100]
    return run_batches(sess, logits_op, [x], [images], batch_size)