How to implement oversampling in Cifar-10?

SMOTE augments artificial examples created by interpolating neighboring data points.
I’m not sure if this makes sense in images, because as you said SMOTE will do a blending of images. I have the impression that this does not work very well, but I wanted to test it anyway because it has works in the literature that uses this techniques in images and the result is favorable.

Could you post some Papers on this topic please?
I know I’ve read some a while ago and cannot find it!

I am following this paper iin my experiments (https://arxiv.org/abs/1710.05381). This paper compares some methods to solve the problem of unbalanced classes. It does not use SMOTE but references this method. I expressed myself poorly, I’m not sure if there are works that use SMOTE, but I wanted to test SMOTE more out of curiosity, to know the behavior of this technique in images.

3 Likes

@Josiane_Rodrigues @ptrblck I am also looking to use SMOTE for image dataset. Can you let me how you used SMOTE for image dataset?

Hi :Josiane, how do you transform a tensor of images into a 2D-array ? can you elaborate more on this ?

@Josiane_Rodrigues were you able to implement SMOTE on CIFAR? Did you get better results? I am facing a similar issue: Performance of SMOTE on CIFAR10 dataset

1 Like

@ptrblck hello!
I registered this platform. 'cause I wanted let you know the result of above WeightedRandomSampler!
After I train, I will let you know. This dataset is so epic and so suitable for this.( some label have no data and some have 30 size but some have 700 size for train set )

just train : 0.47
random sample : 0.44

Hello all,

I want apply SMOTE technique for balancig minortiy classes
I got following error. Can someone help me to solve this error?

Thanks

Hello @ptrblck,

In this code, we only do over-sampling minority classes. How can we use under-sampling for majority classes?

Can you please show it with the code?

Thank you

The posted code balances the targets in each batch by using weights to sample each data point.
Are you looking for a way to sample all minority class samples once and understample the majority classes, which would then yield less samples than were defined in the Dataset?

@ptrblck. Thank you for the response. I am workingg with multiclass classification problem . I have 3 classes . Training set contain 127 images belong to first class, 141 images belong to second class, 257 images belong to third class. I need to use over-sampling and under-sampling techniques to see which technique works well for my data.