(inputs_shape)
| 20 | # speed up computation, so we use identity here. |
| 21 | # see tf.nn.sparse_softmax_cross_entropy_with_logits() |
| 22 | def get_model(inputs_shape): |
| 23 | ni = Input(inputs_shape) |
| 24 | nn = Dropout(keep=0.8)(ni) |
| 25 | nn = Dense(n_units=800, act=tf.nn.relu)(nn) |
| 26 | nn = Dropout(keep=0.8)(nn) |
| 27 | nn = Dense(n_units=800, act=tf.nn.relu)(nn) |
| 28 | nn = Dropout(keep=0.8)(nn) |
| 29 | nn = Dense(n_units=10, act=tf.nn.relu)(nn) |
| 30 | M = Model(inputs=ni, outputs=nn, name="mlp") |
| 31 | return M |
| 32 | |
| 33 | |
| 34 | MLP = get_model([None, 784]) |
no test coverage detected
searching dependent graphs…