1

How to get the number of floating-point operations performed by a Keras model in python?

Model.summary() only provides the number of trainable and non-trainable parameters. Can anyone plz tell me how to get the flop count for a keras model?

My model definition is:

model.add(Dense(32, input_dim=train.shape[1], activation='relu'))

model.add(Dense(len(label_list), activation='softmax'))

for me,

train_shape[1] = 128 label_list = 60

4

0 回答 0