imagecluster.calc.get_model¶
-
imagecluster.calc.
get_model
(layer='fc2')[source]¶ Keras Model of the VGG16 network, with the output layer set to layer.
The default layer is the second-to-last fully connected layer ‘fc2’ of shape (4096,).
Parameters: layer : str
which layer to extract (must be of shape (None, X)), e.g. ‘fc2’, ‘fc1’ or ‘flatten’
Notes
base_model.summary() .... block5_conv4 (Conv2D) (None, 15, 15, 512) 2359808 _________________________________________________________________ block5_pool (MaxPooling2D) (None, 7, 7, 512) 0 _________________________________________________________________ flatten (Flatten) (None, 25088) 0 _________________________________________________________________ fc1 (Dense) (None, 4096) 102764544 _________________________________________________________________ fc2 (Dense) (None, 4096) 16781312 _________________________________________________________________ predictions (Dense) (None, 1000) 4097000