Thanks for your responsibilty.
I edited the code as below:
model = tf.keras.Sequential([
# YOUR CODE STARTS HERE
tfl.ZeroPadding2D(padding=3,input_shape=(64,64,3)),
tfl.Conv2D(kernel_size=(7,7),filters=32,strides=1),
tfl.BatchNormalization(axis=3),
tfl.ReLU,
tfl.MaxPool2D,
tfl.Flatten,
tfl.Dense(units=1,activation='sigmoid')
# YOUR CODE ENDS HERE
])
but I still get this failure:
TypeError Traceback (most recent call last)
in
----> 1 happy_model = happyModel()
2 # Print a summary for each layer
3 for layer in summary(happy_model):
4 print(layer)
5
in happyModel()
39 tfl.MaxPool2D,
40 tfl.Flatten,
—> 41 tfl.Dense(units=1,activation=‘sigmoid’)
42 # YOUR CODE ENDS HERE
43 ])
/opt/conda/lib/python3.7/site-packages/tensorflow/python/training/tracking/base.py in _method_wrapper(self, *args, **kwargs)
455 self._self_setattr_tracking = False # pylint: disable=protected-access
456 try:
→ 457 result = method(self, *args, **kwargs)
458 finally:
459 self._self_setattr_tracking = previous_value # pylint: disable=protected-access
/opt/conda/lib/python3.7/site-packages/tensorflow/python/keras/engine/sequential.py in init(self, layers, name)
140 layers = [layers]
141 for layer in layers:
→ 142 self.add(layer)
143
144 @property
/opt/conda/lib/python3.7/site-packages/tensorflow/python/training/tracking/base.py in _method_wrapper(self, *args, **kwargs)
455 self._self_setattr_tracking = False # pylint: disable=protected-access
456 try:
→ 457 result = method(self, *args, **kwargs)
458 finally:
459 self._self_setattr_tracking = previous_value # pylint: disable=protected-access
/opt/conda/lib/python3.7/site-packages/tensorflow/python/keras/engine/sequential.py in add(self, layer)
180 raise TypeError('The added layer must be ’
181 'an instance of class Layer. ’
→ 182 'Found: ’ + str(layer))
183
184 tf_utils.assert_no_legacy_layers([layer])
TypeError: The added layer must be an instance of class Layer. Found: <class ‘tensorflow.python.keras.layers.advanced_activations.ReLU’>
I am learning Keras but I have no clue how to get this issue sorted