Questions tagged [multiclass-classification]

776 questions
3
votes
0 answers

Why does OvO and OvR return the same result?

I'm using scikit-learn's roc_auc_score() function for a multiclass classification problem. With iris which has three labels (and another dataset), I'm getting the exact same output when I use one-vs-one and one-vs-rest. Does anyone know why this is…
3
votes
0 answers

Why is MSE loss working better for multi-class classification problem than categorical crossentropy?

I have built a model with multiple heads, some doing regression and some classification. I then sum up all the losses in a weighted manner to backpropagate. For the classification heads, I use the one-hot encoding approach, and code takes argmax on…
3
votes
0 answers

HuggingFace BertForMaskedLM: Expected input batch_size (3200) to match target batch_size (16)

Im working on a Multiclass Classification (Bengali Language Sentiment Analysis) on a pretrained Huggingface (BertForMaskedLM) model. When the error occured I knew I have to change the label(output) size to match the input. But do not know how. Im…
3
votes
1 answer

Which Loss function & Metrics is more suitable for multi-label classification? Binary or Categorical cross-entropy and Why?

According to my knowledge(please correct me if I'm wrong), Multi-label classification(mutually inclusive) i.e., samples might have more than 1 correct values (for example movie genre, disease detection, etc). Multi-Class classification(mutually…
3
votes
1 answer

Best Loss Function for Multi-Class Multi-Target Classification Problem

I have a classification problem and I don't know how to categorize this classification problem. As per my understanding, A Multiclass classification problem is where you have multiple mutually exclusive classes and each data point in the dataset…
3
votes
1 answer

Turning a Multiclass Classifier into a Hierarchical Multiclass Classifier

I am using an e-commerce dataset to predict product categories. I use the product description and supplier code as features, and predict the product category. from sklearn import preprocessing from sklearn.feature_extraction.text import…
Snow
  • 1,058
  • 2
  • 19
  • 47
3
votes
0 answers

Multiclass Text Classification Cannot Detect OutOfBound. (Critical Issue of Chatbot Application)

TL;DR When implementing chatbot application, the first task is to detect intent for user's input text. This is a typical Multiclass Text Classification. Intent is class and the number of class to detect is finite. Lots of utterances(examples) is…
3
votes
1 answer

XGboost objectives: Is there a way to do Multi label (NOT multiclass ) classification?

Relatively simple question. Looking at the objective documentation for xgboost, I see "multi:softmax" and "multi:softprob", but both are mutliclass which will only output one class. Is there any way to predict multiple labels using xgboost or would…
3
votes
1 answer

Multiclass semantic segmentation model evaluation

I am doing a project on multiclass semantic segmentation. I have formulated a model that outputs pretty descent segmented images by decreasing the loss value. However, I cannot evaluate the model performance in metrics, such as meanIoU or Dice…
3
votes
1 answer

Random Forest Classifier Batch Learning Python Dimension Error

I have a large dataframe with around a million records and 19 features (+1 target variable). Since I was unable to train my RF classifier due to memory error (it's a multi-class classification with around 750 classes) hence I resorted to batch…
3
votes
3 answers

Correct way of one-hot-encoding class labels for multi-class problem

I have a classification problem with multiple classes, let's call them A, B, C and D. My data has the following shape: X=[#samples, #features, 1], y=[#samples,1]. To be more specific, the y looks like this: [['A'], ['B'], ['D'], ['A'], ['C'],…
3
votes
1 answer

Multiclass classification: probabilities and calibration

I'm working on a multiclass classification problem with different classifiers, working with Python and scikit-learn. I want to use the predicted probabilities, basically to compare the predicted probabilities of the different classifiers for a…
3
votes
1 answer

How to calculate precision, recall in multiclass classification problem after each epoch during training?

I am using Tensorflow 1.15.0 and keras 2.3.1.I'm trying to calculate precision and recall of six class classification problem of each epoch for my training data and validation data during training. I can use the classification_report but it works…
3
votes
1 answer

Can OneVsRestClassifier be used to produce individual binary classifier models in Python Scikit-Learn?

I am reading the documentation of Scikit-learn's OneVsRestClassifier(), link. It looks to me that, the OneVsRestClassifier first binarizes the multiple classes into binary classes, then train the model, and repeat for each of the classes. Then at…
KubiK888
  • 4,377
  • 14
  • 61
  • 115
3
votes
0 answers

How to use lightGBM in multi-classification problem whose target has multi-labels

I get a multi-class classification problem that the samples can have more than one labels. So I want to know how to use lightGBM in such multi-class classification problems. For examples, the target is as follows: id label1 label2 label3 label4…
Bowen Peng
  • 1,635
  • 4
  • 21
  • 39