This:
my_model.summary() Gives you something like this on the terminal:
Model: "fashion_mnist" ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┓ ┃ Layer (type) ┃ Output Shape ┃ Param # ┃ ┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━┩ │ scale_to_0_1_range (Rescaling) │ (None, 784) │ 0 │ ├─────────────────────────────────┼────────────────────────┼───────────────┤ │ hidden_1 (Dense) │ (None, 300) │ 235,500 │ ├─────────────────────────────────┼────────────────────────┼───────────────┤ │ hidden_2 (Dense) │ (None, 100) │ 30,100 │ ├─────────────────────────────────┼────────────────────────┼───────────────┤ │ output (Dense) │ (None, 10) │ 1,010 │ └─────────────────────────────────┴────────────────────────┴───────────────┘ Total params: 266,610 (1.02 MB) Trainable params: 266,610 (1.02 MB) Non-trainable params: 0 (0.00 B) If you prefer a .png:
keras.utils.plot_model(my_model, to_file='model.png', show_shapes=True, show_dtype=True, show_layer_names=True, show_layer_activations=True) Saves an image like this:

Top comments (0)