Questions tagged [multiclass-classification]

776 questions
7
votes
3 answers

How to add a new class to an existing classifier in deep learning?

I trained a deep learning model to classify the given images into three classes. Now I want to add one more class to my model. I tried to check out "Online learning", but it seems to train on new data for existing classes. Do I need to train my…
7
votes
1 answer

More than one prediction in multi-classification in Keras?

I am learning about designing Convolutional Neural Networks using Keras. I have developed a simple model using VGG16 as the base. I have about 6 classes of images in the dataset. Here are the code and description of my model. model =…
TMS
  • 1,201
  • 1
  • 13
  • 20
7
votes
1 answer

Which is the loss function for multi-class classification in XGBoost?

I'm trying to know which loss function uses XGBoost for multi-class classification. I found in this question the loss function for logistic classification in the binary case. I had though that for the multi-class case it might be the same as in GBM…
Anabel Gómez
  • 73
  • 1
  • 2
  • 7
6
votes
0 answers

Multi-Class or Multi-Label Classification with LightGBM

I am working on a classification project that an outcome may belong to multiple classes. For example, the outcomes may belong to Class A, B, and/or C; e.g., A, B, A&B, A&C, B&C, etc. However, I want to predict the probability of a class. For…
6
votes
1 answer

What is the use of base_score in xgboost multiclass working?

I am trying to explore the working of Xgboost binary classification as well as for multi-class. In case of binary class, i observed that base_score is considered as starting probability and it also showed major impact while calculating Gain and…
6
votes
3 answers

Multi-class, multi-label, ordinal classification with sklearn

I was wondering how to run a multi-class, multi-label, ordinal classification with sklearn. I want to predict a ranking of target groups, ranging from the one that is most prevalant at a certain location (1) to the one that is least prevalent (7).…
6
votes
1 answer

SpaCy - ValueError: operands could not be broadcast together with shapes (1,2) (1,5)

In relation to the previous post on stackoverflow Model() got multiple values for argument 'nr_class' - SpaCy multi-classification model (BERT integration) in which my problem partialy have beed resolved I wanted to share the issue which comes up…
Henryk Borzymowski
  • 988
  • 1
  • 10
  • 22
5
votes
3 answers

Something wrong when implementing SVM One-vs-all in python

I was trying to verify that I had correctly understood how SVM - OVA (One-versus-All) works, by comparing the function OneVsRestClassifier with my own implementation. In the following code, I implemented num_classes classifiers in the training…
Alessandro
  • 764
  • 3
  • 8
  • 22
5
votes
1 answer

How to draw the hyperplanes for SVM One-Versus-All?

I was trying to draw the hyperplanes when SVM-OVA was performed as following: import matplotlib.pyplot as plt import numpy as np from sklearn.svm import SVC x = np.array([[1,1.1],[1,2],[2,1]]) y = np.array([0,100,250]) classifier =…
5
votes
2 answers

Calculating accuracy for multi-class classification

Consider a three class classification problem with the following confusion matrix. cm_matrix = predict_class1 predict_class2 predict_class3 ______________ ______________ ______________ Actual_class1 …
Sm1
  • 560
  • 2
  • 6
  • 24
5
votes
2 answers

Python/ML: Which methods to use for Multiclass Classification for Product Categorization?

In a pickle... I have a dataset with >100,000 observations; datasets' columns include CustomerID, VendorID, ProductID and CatNMap. Here is what it looks like: As you can see values represented in first 3 columns (CustomerID, VendorID, ProductID)…
5
votes
0 answers

ML.NET - Schema mismatch for feature column 'Features': expected Vector, got Vector

I just try to make my first ML.NET project, that I have built before with Azure ML, Visual Interface, Python and so on, but now I wanted to do it with C#. I was following this tutorial, but with a totally different dataset and purpose. The dataset…
Eve
  • 604
  • 8
  • 26
5
votes
0 answers

feature importance for each class in multiclass classification

I built a decision tree and it also gives me the feature importance for my classification. But how can I tell my program to give me the feature importance for each of my classes? To give me the overall feature importance I have this…
5
votes
1 answer

Model() got multiple values for argument 'nr_class' - SpaCy multi-classification model (BERT integration)

Hi I am working on implementing a multi-classification model (5 classes) with the new SpaCy Model en_pytt_bertbaseuncased_lg. The code for the new pipe is here: nlp = spacy.load('en_pytt_bertbaseuncased_lg') textcat = nlp.create_pipe( …
5
votes
2 answers

Python: Logistic regression max_iter parameter is reducing the accuracy

I am doing multiclass/multilabel text classification. I trying to get rid of the "ConvergenceWarning". When I tuned the max_iter from default to 4000, the warning is disappeared. However, my model accuracy is reduced from 78 to 75. from…
1
2
3
51 52