<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Exchange Server">
<!-- converted from text/enriched --><style><!-- .EmailQuote { margin-left: 1pt; padding-left: 4pt; border-left: #800000 2px solid; } --></style>
</head>
<body>
Greetings!<br>
<br>
I am currently out of office, with limited access to emails, till August the 30th.<br>
Please contact support@giotto.ai for technical issue concerning Giotto Platform.<br>
Otherwise, I will reply to your email as soon as possible upon my return.<br>
<br>
With best regards,<br>
<br>
Matteo<br>
<br>
<br>
On 27 Jul 2021, at 11:31, Sole Galli via scikit-learn <scikit-learn@python.org> wrote:<br>
<br>
<div class="EmailQuote"><font color="black">Thank you!<br>
<br>
I was confused because in the multiclass documentation it says that for those estimators that have multiclass support built in, like Decision trees and Random Forests, then we do not need to use the wrapper classes like the OnevsRest.<br>
<br>
Thus I have the following question, if I want to determine the PR curves or the ROC curve, say with micro-average, do I need to wrap them with the 1 vs rest? Or it does not matter? The probability values do change slightly.<br>
<br>
Thank you!<br>
<br>
<br>
<br>
<br>
<br>
‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐<br>
<br>
On Tuesday, July 27th, 2021 at 11:22 AM, Guillaume Lemaître <g.lemaitre58@gmail.com> wrote:<br>
<br>
</font><font color="#14A0C2">On 27 Jul 2021, at 11:08, Sole Galli via scikit-learn scikit-learn@python.org wrote:<br>
<br>
Hello community,<br>
<br>
Do I understand correctly that Random Forests are trained as a 1 vs rest when the target has more than 2 classes? Say the target takes values 0, 1 and 2, then the model would train 3 estimators 1 per class under the hood?.<br>
</font><font color="#453BCD"><br>
Each decision tree of the forest is natively supporting multi class.<br>
<br>
</font><font color="#14A0C2">The predict_proba output is an array with 3 columns, containing the probability of each class. If it is 1 vs rest. am I correct to assume that the sum of the probabilities for the 3 classes should not necessarily add up to 1? are
they normalized? how is it done so that they do add up to 1?<br>
</font><font color="#453BCD"><br>
According to the above answer, the sum for each row of the array given by `predict_proba` will sum to 1.<br>
<br>
According to the documentation, the probabilities are computed as:<br>
<br>
The predicted class probabilities of an input sample are computed as the mean predicted class probabilities of the trees in the forest. The class probability of a single tree is the fraction of samples of the same class in a leaf.<br>
<br>
</font><font color="#14A0C2">Thank you<br>
<br>
Sole<br>
<br>
scikit-learn mailing list<br>
<br>
scikit-learn@python.org<br>
<br>
<a href="https://mail.python.org/mailman/listinfo/scikit-learn">https://mail.python.org/mailman/listinfo/scikit-learn</a><br>
</font><font color="black">_______________________________________________<br>
scikit-learn mailing list<br>
scikit-learn@python.org<br>
<a href="https://mail.python.org/mailman/listinfo/scikit-learn">https://mail.python.org/mailman/listinfo/scikit-learn</a><br>
</font></div>
</body>
</html>