Skip to main content

Questions tagged [class-imbalance]

Questions referring to classifiers or classifying problems where some of the classes in the data are under-represented.

Filter by
Sorted by
Tagged with
0 votes
0 answers
20 views

Improving Recall and Precision of the Minority Class with XGBoost to Maximize Profits in Unbalanced Data

The company is interested in identifying profitable customers who are likely to purchase a ticket when given a promotional offer. My goal is to build a model to predict whether a customer will buy a ...
ster111's user avatar
1 vote
1 answer
63 views

Using a regression model, is it possible to precisely predict "outlier" results based on a highly imbalanced dataset?

Title. I have a dataset that's highly imbalanced, say the output variable I want to predict is restricted within the range from 0 to 1, but almost all of the datapoints sit around 0.7-0.9, while my ...
Yuuya's user avatar
  • 31
0 votes
0 answers
14 views

Impact of Adding Imbalanced Data on Model Performance for Different Groups

Suppose I initially have a dataset with 50 samples of type A and 50 samples of type B, each with several features. I built a neural network model using this data and recorded the prediction accuracy ...
Mickly's user avatar
  • 1
1 vote
0 answers
38 views

Class imbalance for binary classification tasks

I am looking to train a binary classifier. Most of my experience so far has been with generative models, not classifiers, so I am wondering with respect to training data, what is a good ratio of 0 and ...
Wigeon's user avatar
  • 11
4 votes
0 answers
59 views

How do you know that your classifier is suffering from class imbalance?

Inspired by @Dave's question "Why does data science see class imbalance as a problem for supervised learning when statistics does not?", I am re-posting a question I posed on the stats SE to ...
Dikran Marsupial's user avatar
0 votes
1 answer
25 views

Fixing class imbalance vs Over-detecting in test data

In my experiences, binary classifiers tend do better in terms of F1 scores when the class imbalance is at least reduced. However, this leads to over-predicting in the test data. (Thought) Example: If ...
yurnero's user avatar
  • 131
3 votes
2 answers
465 views

Preserving / fixing class imbalance

Suppose that I have 2 collection $A$ and $B$ of unlabeled animals that are either dogs or cats. The dogs in $A$ and the dogs in $B$ are not necessarily identical, other than the fact that they are ...
yurnero's user avatar
  • 131
2 votes
1 answer
37 views

Techniques for solving the problem with an unbalanced data set

I am trying to solve a problem with an unbalanced data set. I have two classes, one is for patients with risk (1), the other for patients without risk (0). I have a larger number of patients without ...
Naty's user avatar
  • 21
1 vote
0 answers
105 views

Using SMOTE Train Model and Optimal Cutoff on Unbalanced Test Data

My original dataset has a binary dependent variable with 3% of the values being one. First, I split the original dataset into training and testing sets using an 80-20 split. Since it includes both ...
CraigS's user avatar
  • 11
0 votes
0 answers
27 views

Extremely Imbalanced and Gapped Dataset in Regression Problem

Currently I am working with a biological dataset with a range of 0-to-1 to do a multi-task regression with Deep Learning. However, this dataset has an empty gap in the range 0 to 0.2 (however there ...
Abdullah Faqih's user avatar
0 votes
0 answers
24 views

Is balancing imbalanced validation set for retraining model after hyperparameter tuning required?

The following are basic steps to modelling, but would like to ask in the case of imbalanced data, is balancing of train dataset required when retraining model on train + validation set after ...
curious-24-7's user avatar
0 votes
0 answers
8 views

What is the Near-Miss Version 3 undersampling algorithm?

I understand version 1 and version 2 of the Near Miss undersampling algorithm, as described here. However, I don't understand version 3 of this algorithm. I'll appreciate an explanation.
Evan Aad's user avatar
  • 175
0 votes
1 answer
18 views

Class imbalance problem in binary classification of ecg and eeg data. I am cross posting it here from stackExchange as per a user suggestion

I have attached the link to the stack overflow question page under. In short it is a Class imbalance problem in binary classification of ecg and eeg data. https://stackoverflow.com/questions/78232398/...
Shanthanu's user avatar
0 votes
0 answers
24 views

Multiclass PyTorch neural net is stuck predicting 1 class, even with "simple" dataset

I'm trying to predict a class of some data, and am struggling. So, to debug I created a simple test dataset, yet I am having the same issues. I've tried adding weighting, and lastly adding a column ...
Russ's user avatar
  • 1
0 votes
0 answers
8 views

What are the drawbacks of utilizing sample weights in classification tasks?

In classification tasks, especially when dealing with unbalanced data, using sample weights can be beneficial. However, it's not always the default choice in ML libraries like AutoGluon ...
jsn's user avatar
  • 1
-1 votes
1 answer
36 views

How to deal with a heavily imbalanced test dataset?

Both my train data and test data were imbalanced. So I tried SMOTE for training. Before Smote: ...
GrGr11's user avatar
  • 1
1 vote
0 answers
33 views

How to solve imbalanced dataset oversampling problem in multi labels-classes instance segmentation task?

I want to use models YOLOv7-seg for instance segmentation of tree species in images. There are 26 species of trees, and each image may contain multiple species. There is a distinction between dominant ...
yuga555's user avatar
  • 11
0 votes
0 answers
30 views

PR-AUC vs F1 vs Balanced Accuracy

I'm trying to create a Random Forest Classifier for selecting ~ 700 features. I have a highly imbalanced dataset to select features from. There are significantly fewer positive cases (1%) compared ...
user155775's user avatar
1 vote
0 answers
44 views

Scaling imbalanced binary features

I am interested in a discussion in encoding and scaling categorical features, notably imbalanced categorical features. The context is neural networks (gbdts should handle this easily). It is known ...
Lucas Morin's user avatar
  • 2,309
1 vote
0 answers
52 views

Bad metrics results by strong class imbalance in Credit card classification

Hi i'm currently in the process of writing my bachelor's thesis and stuck at a some steps. I've developed a few ML-Model (XGBoost, (Balanced) Random Forest, ElasticNet,...) on an extreme imbalanced ...
user159373's user avatar
0 votes
0 answers
31 views

CNN segmentation models: class weights specification on IoU metric

I am building a MANet model using pytorch lightning. For getting the model I use the library segmentation models. As my objective is to do binary semantic segmentation, during the test phase I ...
Alessandro Pistola's user avatar
15 votes
2 answers
707 views

Why does data science see class imbalance as a problem for supervised learning when statistics does not?

Why does data science see class imbalance as a problem in supervised learning when statistics says it is not? Data science seems to seem class imbalance as problematic and needing special techniques ...
Dave's user avatar
  • 3,980
1 vote
1 answer
56 views

How to balance labeled datas and then carry out execution with a certain ratio?

I'm building a binary classification model using a neural network, with python and the libraries tensorflow and keras. For that I have an unequal amount of labeled data: Around 2'000'000 labeled with <...
user155518's user avatar
0 votes
0 answers
19 views

How should I design the CNN for classifying the relation between 2 texts (multiple classes)

So I have a task to classify the relation between 2 texts (4 classes possible) and one of the requirements is to preprocess them with TfidfVectorizer or CountVectorizer. Since every sample has 2 ...
giza2001s's user avatar
1 vote
1 answer
50 views

How does oversampling or undersampling approch is going to help during the testing on real time data?

We have a dataset with class A as 10% only and Class B as 90% . Let say we did undersampling or oversampling on training data and we made 50% of class A and 50% of class B. But in reality the data ...
XGB's user avatar
  • 15
0 votes
1 answer
204 views

Random Forest overfitting to unbalanced data set

I am working on an unbalanced classification problem. I have have 2000 points which are positive, and 6000 points as -ve (chosen randomly from 100k universe of -ve points universe). Although I have ~...
Gupta's user avatar
  • 75
0 votes
0 answers
16 views

Why is my Histogram Gradient Boosting Classifier model still producing type II error? How can I reduce the type II error?

Type 2 error and how to hypertune or feature engineer a solution for it I trial and tested different techniques and kept the structure which made the most sense to me. But still my model confusion ...
bitebytebit's user avatar
0 votes
0 answers
24 views

What was used before data augmentation (e.g. SMOTE) to train ML models on imbalanced data? Please provide citations

I am seriously curious on how imbalance data was treated in machine learning and statistical learning before modern time data augmentation solutions such as SMOTE appeared. Please provide citations ...
Full Array's user avatar
0 votes
0 answers
14 views

Highly unbalnced text data giving very low matrics

I have an unbalanced multi-class banking text data with around 76 classes. Classes are badly distributed such as one class which is combination of 240 other different categories, represents 50% of ...
Remrem's user avatar
  • 1
0 votes
0 answers
29 views

What can I do when validation data and test data has different distribution in imbalance classification?

I am building classification model for bio (scRNA) data. Datasets in this field, for example, dataset A has 1, 2 classes, dataset B has 2, 3 classes kind of that. So I integrated datasets for training ...
containletters's user avatar
0 votes
0 answers
87 views

SMOTE-NC not working, Error: Pandas output does not support sparse data

I want to get my SMOTENC to work, but i've been failing successfully ...
user155410's user avatar
0 votes
0 answers
13 views

What is the prior mu in Heterogeneous Graph Transformer?

I am reading https://arxiv.org/pdf/2003.01332.pdf and do not understand what the prior (\mu) is supposed to be. I also found their implementation on github, but it is still not clear to me. For ...
Servus's user avatar
  • 101
0 votes
0 answers
27 views

Binary classification using xgboost

Why when adding new features in my ADS for a binary classification using XGBOOST my score and uplift has decreased ? What is the best way to treate categorical features or other features in order that ...
Warda_IDRIS's user avatar
0 votes
0 answers
18 views

Balancing imbalanced classes for TF2 object detection

I have a large set of images with 6 classes where the class distribution is imbalanced. Looked into balancing it by adding weight for each class but as I read in tensorflow docs the weight property is ...
Gautam's user avatar
  • 101
0 votes
1 answer
149 views

Is there a way to focus mainly on high precision when fitting a tree model?

I have a dataset with 95% false and 5% true labels, some 200000 samples overall, I'm fitting a LightGBM model. I mainly need to focus on high precision and have low number of false positives, I don't ...
Fireant's user avatar
0 votes
2 answers
240 views

How to improve accuracy on a single class out of 3 classes in model

I am training a classification model with 3 classes using a deep neural network. The classes have been resampled and balanced. I have around 600000 samples... equally distributed. The dataset is also ...
Fr_nkenstien's user avatar
0 votes
3 answers
108 views

Reduce false positives having imbalanced data

I'm using a DNN-48 having the following scenario: Features: 8 (48 at the end because I generate conditional sequences of 6 elements each) Classes: Y=0 (90%), Y=1 (10%) Precision and recall are good ...
Gabriel's user avatar
0 votes
2 answers
161 views

what is a random prediction for class imbalanced data? How can I check if my model is predicting randomly?

Say if you have a balanced dataset, with two classes, if the classification model that we’re training doesn’t learn anything ( suppose the data is random ), the model’s output would be 50% first class ...
ZEINab Sadeghian's user avatar
0 votes
0 answers
20 views

Is there a way to artificially manipulate a dataset in order to replace it for one that gives good results?

I'm trying to artificially create a dataset for pure educative reasons but I want it to be based in one particular dataset, the problem is that this original dataset don't make good predictions even ...
Stefanni Germanotta's user avatar
0 votes
0 answers
20 views

How would you treat imbalanced training data, and you don't know how test data distribution looks like in deep learning?

I posted this question on another place, but I want to get many tips, so I post here too. I am building deep learning classification model in bioinformatics. I made training dataset by merging 12 ...
containletters's user avatar
6 votes
2 answers
2k views

Determining whether a dataset is imbalanced or not

Is there a practical threshold to determine whether a dataset is imbalanced or not? i.e. we should packages like imbalanced-learn to do some kind of adjustment like ...
Yandle's user avatar
  • 231
0 votes
2 answers
264 views

Is there any rationale for performing SMOTE-ENN before train-test-split?

I have created a classification model for predicting data, and the problem is that the two classes are highly imbalanced I have a problem. I have created a classification model for predicting data, ...
Hello is me's user avatar
2 votes
2 answers
1k views

Some simple questions about confusion matrix and metrics in general

I will first tell you about the context then ask my questions. The model detects hate speech and the training and testing datasets are imbalanced (NLP). My questions: Is this considered a good model? ...
Maxi's user avatar
  • 89
5 votes
1 answer
339 views

Are imbalanced data problems solvable? [closed]

I am working as a data scientist for the past 2 years where I have worked on problems related to binary classification, revenue prediction etc. In the past two years, I have had 2 problems that ...
The Great's user avatar
  • 2,585
5 votes
3 answers
246 views

Reproducible examples where balancing the training data demonstrably improves accuracy

I asked this question on the Statistics SE, but there were no answers, even when a modest bonus was available, so I am asking here to see if any examples can be given. I have been looking into the ...
Dikran Marsupial's user avatar
0 votes
2 answers
383 views

Interpretation of evaluation metrics for an imbalanced dataset

I am currently dealing with a classification problem for a massively imbalanced dataset. More specifically, it is a fraud detection dataset with around 290k rows of data, with distribution of 99.8% ...
Hai Nguyen's user avatar
1 vote
1 answer
959 views

I used SMOTE-ENN to balance my dataset and it improved the performance metrics, but how can I be sure it's not overfitting?

The models were evaluated using 10-fold cross validation. foldCount = StratifiedKFold(10, shuffle=True, random_state=1) The models in question are XGBoost. ...
Tariq's user avatar
  • 15
1 vote
2 answers
186 views

Class Imbalance in Dataset of Images

When dealing with an imbalanced dataset, I have been taught to oversample on only the train samples and not the entire dataset to avoid overfitting, however this was for structured text based data in ...
osmans's user avatar
  • 11
1 vote
1 answer
409 views

Stratifed time series split with the same imbalance ratio

I am recently working on an imbalanced binary classification problem where the data is time ordered. I would like to validate my model using training/validation splits that have the same imbalance ...
Moataz Chouchen's user avatar
1 vote
1 answer
24 views

Movement in cohorts

I am working on a user sales data which gets updated week over week. Based on the sales done in each week, the user is categorized in segment A, B or C. This means size of each segment could change ...
Sham's user avatar
  • 31

1
2 3 4 5
12