New answers tagged

1

Keras has some accuracy metrics for multiclass neural networks. CategoricalAccuracy Top K Categorical Accuracy Sparse Top K Categorical Accuracy There are some others if you want to implemented from scratch. Taken from: https://www.sciencedirect.com/science/article/abs/pii/S0306457309000259 These work for most problems rather nicely combined with a good ...


0

You are mixing various concepts: $L = \frac{1}{2N}\sum^{N}_{i=1}(e_i)^2$ is used only for regression problem and not for binary classification because MSE fits very well when your target distribution is normal You can use the latter formula for binary classification but will works really bad because your target data distribution is a Bernoulli, not Normal. ...


1

Use f1_score instead of the classification report: from sklearn.metrics import f1_score ... print('f1_score', f1_score(xgb_results, y_test))


1

As you say, scale_pos_weight works for two classes (binary classification). weight can be used for three or more classes. The parameter goes into the xgb.DMatrix function and must contain one value for each observation. Example: library(xgboost) data(iris) # We'll predict Species label = as.integer(iris$Species)-1 iris$Species = NULL # Split the data for ...


3

Generally lower recall means that the system is too strict, i.e. it predicts an instance as positive only when it has clear indications in the features that it's indeed a positive. As a consequence, it misses the true positive instances for which the indications are not so clear. But when looking at macro-recall it's more complex: it depends primarily on how ...


1

Your calculation is correct, but you forgot to ask yourself one question: why should we consider "red" as the positive class? Precision and recall can be calculated for every class (i.e. considering the current class as positive), as opposed to accuracy. So if we take "blue" as positive we get: precision = NaN (because there's 0 ...


0

If both the tasks consolidated classes set is small,using the multi-output network will be useful. But if your consolidated classes set is very large then I would suggest you go with different networks. Personally, I would prefer to train individual models as it is hard to optimize multi-output networks.


0

I posted the same question on the Catboost github (issues) page and got an answer. The link can be found here: https://github.com/catboost/catboost/issues/1447 Answer: Class weights and weights in WKappa are different. Calculation of WKappa metric consists of two steps: Confusion matrix calculation - here object and class weights are used. WKappa ...


0

No - AUC (Area Under Curve) can not be used directly to assess the performance of multi-class classification. If you want to use AUC, it is necessary to binarize the output. Either each class as to be compared against each other class or 1 class versus the rest.


Top 50 recent answers are included