Confusion matrix for node-wise classifications
I'm hoping to output a confusion matrix for node-wise binary classification after training is complete.
Do you have a way you recommend I go about doing this? I've tried using tf.confusion_matrix where the labels input is y_test and the predictions input is the vector from model.outputs (which is coming from a modification to your evaluate function). This has it's issues though, because (I think) model.outputs is the output of an activation function and not the classification itself.
Is there a better way to go about this, or is there something I'm missing?
Scikit learn has some convenience functions for creating confusion matrices: http://scikit-learn.org/stable/modules/generated/sklearn.metrics.confusion_matrix.html
Just provide the predicted classes and the true labels. You might need to perform an argmax or max operation on the output of the GCN model to get the predicted classes (as I think the model just gives you probabilities).
Hope this helps.
Hi @Spencerkt how did you get the model outputs for just the test dataset?