Clear Filters
Clear Filters

Hi, when running the following code, I encountered the following error:

1 view (last 30 days)
Error using nnet.internal.cnn.util.validateLayersForLayerGraph>iAssertUniqueAndNonEmptyLayerNames (line 45)
Layer names in layer array must be nonempty.
Error in nnet.internal.cnn.util.validateLayersForLayerGraph (line 33)
iAssertUniqueAndNonEmptyLayerNames(larray, existingLayers);
Error in nnet.cnn.LayerGraph>iValidateLayers (line 556)
larray = nnet.internal.cnn.util.validateLayersForLayerGraph(larray, existingLayers);
Error in nnet.cnn.LayerGraph/replaceLayer (line 420)
larray = iValidateLayers(larray, existingLayers);
Error in dazuoye (line 51 )
net = replaceLayer(net,"encoderImageInputLayer", ...
My code is as follows:
net = encoderDecoderNetwork(inputSize,encoder,decoder, ...
LatentNetwork=bridgeLayers, ...
SkipConnections="concatenate", ...
FinalNetwork=finalLayers);
net = layerGraph(net);
net = replaceLayer(net,"encoderImageInputLayer", ...
imageInputLayer(inputSize,Normalization="zerocenter"));

Answers (1)

Cris LaPierre
Cris LaPierre on 29 Nov 2023

Categories

Find more on Sequence and Numeric Feature Data Workflows in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!