application_vnd.jupyter.stderr_output_1.png
from tensorflow.keras import Model

from tensorflow.keras import layers

from tensorflow.keras.applications.inception_v3 import InceptionV3

from tensorflow.keras.applications.inception_v3 import InceptionV3
from tensorflow.keras import layers
pre_trained_model = InceptionV3(input_shape=(256, 256, 3), include_top=False, weights=None)
for layer in pre_trained_model.layers:
    layer.trainable = False

pre_trained_model.summary()

last_layer = pre_trained_model.get_layer('mixed7')
last_output = last_layer.output

from tensorflow.keras.optimizers import RMSprop
from tensorflow.keras import Model
x = layers.Flatten()(last_output)
x = layers.Dense(1024, activation='relu')(x)
x = layers.Dropout(0.2)(x)
x = layers.Dense(1, activation='sigmoid')(x)
model = Model(pre_trained_model.input, x)
model.summary()