Difficulty utilizing pretrained "pix2Pix" GAN implementation using Deep Network Designer

29 vues (au cours des 30 derniers jours)
Hi there
I am attempting to implement a pretrained "Pix2Pix" GAN that was trained using tensorflow/Keras example:
after (tensorflow) training I saved the model for the Generator to the required model.h5 file.
In Matlab:
import the layers and weights
lgraph=importKerasLayers(modelfile,'ImportWeights',true,"OutputLayerType","regression")
have also attempted the above without the regression layer but the following still occurs:
Using the Deep Network Designer I import lgraph from the workspace and then export with pretrained parameters - unless I am mistaken the weights and biases should be as was trained in Tensorflow?
Exectute the live scripts that Deep Network Designer generated to create the Lgraph with Weights,Biases etc
however once I create the generator from the lgraph:
Generator=assembleNetwork(lgraph)
and then pass an input image (correctly sized, normalized etc) through the generator
Y=predict(Generator,dlPic)
the output appears to return an unchanged input image?
Am I missing any important aspects?
Is it necessary to define the discriminator, loss functions etc if I only wish to utilize the pretrained Generator architecture?
Any assistance would be GREATLY appreciated!

Réponses (0)

Catégories

En savoir plus sur Deep Learning Toolbox dans Help Center et File Exchange

Produits


Version

R2019b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by