lfw: Output accuracy.

This commit is contained in:
Brandon Amos 2016-01-11 08:11:37 -05:00
parent 6a5d95d451
commit 46251db1e2
1 changed files with 4 additions and 2 deletions

View File

@ -175,8 +175,10 @@ def classifyExp(workDir, pairs, embeddings):
accuracies.append(accuracy)
f.write('{}, {:0.2f}, {:0.2f}\n'.format(
idx, bestThresh, accuracy))
f.write('\navg, {:0.4f} +/- {:0.4f}\n'.format(np.mean(accuracies),
np.std(accuracies)))
avg = np.mean(accuracies)
std = np.std(accuracies)
f.write('\navg, {:0.4f} +/- {:0.4f}\n'.format(avg, std))
print(' + {:0.4f}'.format(avg))
def getAUC(fprs, tprs):