Commit 09b9fbad authored by sjjsmuel's avatar sjjsmuel

test GAP instead of flatten

the network becomes to large
parent 5b78432f
...@@ -31,7 +31,7 @@ class VGG_16(NetworkBase): ...@@ -31,7 +31,7 @@ class VGG_16(NetworkBase):
if shouldSave: if shouldSave:
base_model.save('input/vgg_base_model.h5') base_model.save('input/vgg_base_model.h5')
x = Flatten()(base_model.output) x = GlobalAveragePooling2D()(base_model.output)
x = Dense(4096, activation='relu')(x) x = Dense(4096, activation='relu')(x)
x = Dense(4096, activation='relu')(x) x = Dense(4096, activation='relu')(x)
out = Dense(self.NUM_CLASSES, activation='softmax', name='probs')(x) out = Dense(self.NUM_CLASSES, activation='softmax', name='probs')(x)
......
Markdown is supported
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