+2 votes
in Machine Learning by (73.8k points)
recategorized by

I am using scikit-learn's roc_auc_score() to compute AUC-ROC score. But this function is giving error : ValueError: Found input variables with inconsistent numbers of samples: [2666, 10]

Here is my code:

roc_auc_score(self.data.labels,self.predictions)

1 Answer

+1 vote
by (348k points)
selected by
 
Best answer

The size of self.data.labels is 2666 whereas the size of self.predictions is 10. Due to different size of two variables, you are getting the error. Look into your code to determine why the size of self.predictions is 10. Once you fix that, this error should not come.


...