#keras.utils.vis_utils模块提供了画出Keras模型的函数(keras版本2.0.2以上)
pip install graphviz pip install pydotplus
import pydotplus import keras.utils keras.utils.vis_utils.pydot = pydotplus keras.utils.plot_model(your_model_name, to_file='model.png', show_shapes=True)

plot_model接收两个可选参数:

  • show_shapes:指定是否显示输出数据的形状,默认为False
  • show_layer_names:指定是否显示层名称,默认为True
 

相关文章:

  • 2022-01-20
  • 2021-10-14
  • 2021-12-12
  • 2022-12-23
  • 2022-12-23
  • 2021-11-23
  • 2022-12-23
  • 2021-05-31
猜你喜欢
  • 2021-08-06
  • 2021-07-14
  • 2021-08-04
  • 2022-12-23
  • 2022-12-23
  • 2021-04-04
  • 2021-05-25
相关资源
相似解决方案