Prints a summary of a model.

model Keras model instance.
line_length Total length of printed lines (e.g. set this to adapt the display to different terminal window sizes).
positions Relative or absolute positions of log elements in each line. If not provided, defaults to [0.3, 0.6, 0.70, 1.].
print_fn Print function to use. It will be called on each line of the summary. You can set it to a custom function in order to capture the string summary. It defaults to print (prints to stdout).
expand_nested Whether to expand the nested models. If not provided, defaults to False.
show_trainable Whether to show if a layer is trainable. If not provided, defaults to False.
layer_range List or tuple containing two strings, the starting layer name and ending layer name (both inclusive), indicating the range of layers to be printed in the summary. The strings could also be regexes instead of an exact name. In this case, the starting layer will be the first layer that matches layer_range[0] and the ending layer will be the last element that matches layer_range[1]. By default (None) all layers in the model are included in the summary.