Hi, I am trying to use CNN_sentence to classify tweets into one of the K predefined topics. Although I am able to get the final ouput class for each tweet, I am more interested in the probability vector in the layer right before the ouput layer based on which its decided which class the tweet should belong to. eg. If I have 3 classes and the output class for a given tweet is [2], the I assume the previous layer would be dealing with a class-wise probability which could be something like [0.3 , 0.78, 0.1] for class 1, 2, 3 respectively(just an example).
[test_loss,y_pred] = test_model_all(test_set_x,test_set_y)
the variable "y_pred" gives me the final output but not the class probabilities but not class probabilities.
Can you suggest a way to get these probs ?
Hi, I am trying to use CNN_sentence to classify tweets into one of the K predefined topics. Although I am able to get the final ouput class for each tweet, I am more interested in the probability vector in the layer right before the ouput layer based on which its decided which class the tweet should belong to. eg. If I have 3 classes and the output class for a given tweet is [2], the I assume the previous layer would be dealing with a class-wise probability which could be something like [0.3 , 0.78, 0.1] for class 1, 2, 3 respectively(just an example).
[test_loss,y_pred] = test_model_all(test_set_x,test_set_y) the variable "y_pred" gives me the final output but not the class probabilities but not class probabilities. Can you suggest a way to get these probs ?