I have a question on a classification problem in machine learning using the log_loss function in scikit-learn.
from sklearn.ensemble import RandomForestClassifier
classifier = RandomForestClassifier()
classifier.fit(Xtrain, ytrain)
soft = classifier.predict_proba(Xtest)[:,1]
log_loss = log_loss(ytest, soft)
I would to compute the log loss but an error appears :
'numpy.float64' object is not callable
I think that this problem may come from the fact that there is some 0 in the vector soft. But I do know to solve this problem ?
s = 0
for x in soft : 
    if x == 0 : 
        s+=1
print(s)
>> 17729
Thanks in advance
 
     
    