1
$\begingroup$

I have a CNN architecture that works well on 32x32x3 images. Can I use that same architecture for a data set made up of 28x28x1 images? (Both data sets have 10 classes). If this is possible, what changes would I need to make to the architecture I have?

$\endgroup$
0
$\begingroup$

One way is to redesign your CNN architecture to fit your new data input. However, if you want to use the current model you have, you should:

(1) Retraining: Re-train the model with new data set images

(2) Reshape new images: You should add a pre-processing layer to convert 28x28x1 images to 32x32x3 images. This could be done by replicating a single channel in other two channels and adding boundaries to your images. This deformation process should be the same on all new input images.

$\endgroup$
  • $\begingroup$ If I were to retrain the model with the new data set images I would have some tensor dimension errors right? $\endgroup$ – brubrudsi Nov 14 at 2:24
  • $\begingroup$ That actually depends what all layers you have and how you have connected them as well imo. $\endgroup$ – Aditya Nov 14 at 4:22
  • $\begingroup$ @brubrudsi If you retrained the model you need to change the input shape in the first layer to avoid such errors. $\endgroup$ – serali Nov 14 at 8:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.