Commit aefc4ec7 authored by Matt Harvey's avatar Matt Harvey
Browse files

Dont freeze the new dense layers.

Showing with 1 addition and 2 deletions
+1 -2
......@@ -74,10 +74,9 @@ def get_model(weights='imagenet'):
def freeze_all_but_top(model):
"""Used to train just the top layers of the model."""
print(model.summary())
# first: train only the top layers (which were randomly initialized)
# i.e. freeze all convolutional InceptionV3 layers
for layer in model.layers:
for layer in model.layers[:-2]:
layer.trainable = False
# compile the model (should be done *after* setting layers to non-trainable)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment