Hi Sreeraj,
I understand that you have built a neural network using the “layerGraph” function. But you are not able to see the layers in your GAN network. This means that there is some issue in the layer construction itself.
Usually the first step after constructing the layers is to run the “analyzeNetwork” function on the layer graph. You can follow the below syntax to do the same:
analyzeGraph(lgraphGenerator);
For your code the output of this command comes out to be the following:
The analysis has come up with 3 errors. The errors are as follows:
- The first error occurs in the “transposedConv2dLayer”. The function requires input data which is in the form of [height, width, numChannels]. To resolve this please check the input data for the “transposedConv2dLayer”
- The missing output layer error occurs because there is an error on the last layer i.e “sigmoid”. You must use a classification layer after the sigmoid layer.
- The error on the sigmoid layer states that there is an unconnected output. For this you need to check the dimensions of the input data for sigmoid layer and also check if the sequence of layer is correct.
After resolving the above errors you should see the layers of your network without any problem
Refer to the below documentation to know more about “transposedConv2dLayer” and sigmoid layer:
- https://www.mathworks.com/help/deeplearning/ref/classificationlayer.html
- https://www.mathworks.com/help/deeplearning/ref/nnet.cnn.layer.sigmoidlayer.html
- https://www.mathworks.com/help/deeplearning/ref/transposedconv2dlayer.html
For more information about “analyzeNetwork” refer to the below documentation:
I hope this helps.