Guest User

Untitled

a guest
Sep 23rd, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. model = keras.Sequential([
  2. keras.layers.Flatten(input_shape=(14, 14)),
  3. keras.layers.Dense(128, activation=tf.nn.relu),
  4. keras.layers.Dense(64, activation=tf.nn.relu),
  5. keras.layers.Dense(32, activation=tf.nn.relu),
  6. keras.layers.Dense(16, activation=tf.nn.relu),
  7. keras.layers.Dense(8, activation=tf.nn.relu),
  8. keras.layers.Dense(2, activation=tf.nn.softmax)
  9. ])
  10. model.compile(optimizer=tf.train.AdamOptimizer(),
  11. loss='sparse_categorical_crossentropy',
  12. metrics=['accuracy'])
Add Comment
Please, Sign In to add comment