The output size of the last layer doesn't match the number of classes
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hello,
I used one pretrained network (vgg16) for my set of images. Vgg16 is trainned with 11 classes.
I want to redefine the number of classes to be 6. The problem appear at the last layer: the number of classes from the last Layer is 11, not 6.
I tried something like:
layersMine(2,1).ClassWeights = length(classNames);
layerMine(2,1).ClassNames(1:6) = classNames
How can I change the number of classes from the last layer to 6?
Can I redefine the last layer (classificationLayer)? How?
0 comentarios
Respuestas (0)
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!