Predicting image class using CGAN_mnist_R example

Hi all.

I’m kind of new in this field (neural network and mxnet usage)
I have been testing the example in this link.
The code works perfectly and I’m able to generate new images using the inference part at the end of the code.

My problem here is how I can predict the image class (let say I take one of the image produced by the generator network) using this example.



You would need to train a different neural network with labelled training data for each image class you’d like to predict to do that. Alternatively, you can use a pretrained model as done in this tutorial here:

Some more examples for different model architectures are available here: