can anyone pls help on where my mistake is ?
i did use Dense(1)(x) for the last output but still error as below
TypeError Traceback (most recent call last)
in
----> 1 model2 = alpaca_model(IMG_SIZE, data_augmentation)
in alpaca_model(image_shape, data_augmentation)
27
28 # data preprocessing using the same weights the model was trained on
—> 29 x = preprocess_input(x)
30
31 # set training to False to avoid keeping track of statistics in the batch norm layer
/opt/conda/lib/python3.7/site-packages/tensorflow/python/keras/applications/mobilenet_v2.py in preprocess_input(x, data_format)
500 @keras_export(‘keras.applications.mobilenet_v2.preprocess_input’)
501 def preprocess_input(x, data_format=None):
→ 502 return imagenet_utils.preprocess_input(x, data_format=data_format, mode=‘tf’)
503
504
/opt/conda/lib/python3.7/site-packages/tensorflow/python/keras/applications/imagenet_utils.py in preprocess_input(x, data_format, mode)
117 else:
118 return _preprocess_symbolic_input(
→ 119 x, data_format=data_format, mode=mode)
120
121
/opt/conda/lib/python3.7/site-packages/tensorflow/python/keras/applications/imagenet_utils.py in _preprocess_symbolic_input(x, data_format, mode)
261 “”"
262 if mode == ‘tf’:
→ 263 x /= 127.5
264 x -= 1.
265 return x
TypeError: unsupported operand type(s) for /=: ‘Sequential’ and ‘float’