SankhaSubhra / GAMO

Generative Adversarial Minority Oversampling
GNU General Public License v3.0
31 stars 10 forks source link

How can I give an rgb imgaes as input? #2

Open Hyeonjeong2385 opened 4 years ago

Hyeonjeong2385 commented 4 years ago

I'm trying to transform network a little bit to give an rgb 3 dimensional images as inputs and bigger size of ones than current input size(28,28).

But I don't know how to adjust the arguments. Could you help me..?

SankhaSubhra commented 4 years ago

Unfortunately, you cannot use the current code for RGB images. However, the code can be easily modified to cater for you need.

  1. Update the fashion_mnist_net.py file to change the input convolution layer parameters (for example in fMnistGamoConvCreate() edit ip1 accordingly).
  2. Change any reshape and/or Input in the main file as per necessity.

Moreover, you may check the supplementary document of the paper published in ICCV 2019 from the CVF repository to know the network architectures used for RGB images of varying resolutions.

Hyeonjeong2385 commented 4 years ago

I tried to train the classifier who has 2 classes with 3 channel (rgb) input data. I put the input image size 28283 yet, and I didn't modified the net inside except the input shape

But I got the weird training process like below. I don't know what happened. Is it because of overfitting or lack of parameters?

Hyeonjeong2385 commented 4 years ago

image

The performance suddenly occurs [0, 1] continuously. What should I do?

SankhaSubhra commented 4 years ago

This is quite unusual indeed, as the minority class is suddenly getting a 0 tpr. To be honest this behaviour is new to me too and I need to know a bit more before attempting to explain the situation. Over-fitting may be a possible reason here, as the system was working fine up to a certain number of steps.
I can suggest a rerun to make sure if the incident can be reproduced. Also, can I ask you to please share your data with me, so I can attempt to reproduce the incident myself, and suggest a possible remedy?

Hyeonjeong2385 commented 4 years ago

Thank you so much! I used cats_and_dogs data from kaggle. I modified the data format to the same as existing input format, and I attached the zip file. And.. Could I ask you to share your code for the different size and 3 channel input , so that I could attempt to solve this problem with you, please? But I don't mind even if you can't to do. cats_and_dogs_test_rgb.zip