绘制的Keras模型没有给出尺寸

问题描述 投票:0回答:1

我正在尝试使用Keras绘制VGG16架构图。但是,我看到下面的图像与None,一些维度。 None是什么意思,是一个错误?

enter image description here

from keras.utils import plot_model
model = VGG19(include_top=True, weights='imagenet')
#print(model.summary())
plot_model(model, to_file='model_Vgg19.png',show_shapes=True)

我可以看到这是Keras的一个已知问题:https://github.com/keras-team/keras/issues/1877

python deep-learning keras
1个回答
4
投票

形状元组中的None维度指的是批量维度,这意味着该层可以接受任何大小的输入。例如,数据集(例如MNIST)可以具有以下形状元组(60000, 28, 28, 1),但输入层的形状将是(None, 28, 28, 1)

参考文献:

© www.soinside.com 2019 - 2024. All rights reserved.