Why should we choose ‘linear’ output instead of sigmoid output if it’s binary classification problem and not linear regression for function alpaca_model?
This is the output of the autograder block:
[‘InputLayer’, [(None, 160, 160, 3)], 0]
[‘Sequential’, (None, 160, 160, 3), 0]
[‘TensorFlowOpLayer’, [(None, 160, 160, 3)], 0]
[‘TensorFlowOpLayer’, [(None, 160, 160, 3)], 0]
[‘Functional’, (None, 5, 5, 1280), 2257984]
[‘GlobalAveragePooling2D’, (None, 1280), 0]
[‘Dropout’, (None, 1280), 0, 0.2]
[‘Dense’, (None, 1), 1281, ‘linear’]
and this latest layer ( [‘Dense’, (None, 1), 1281, ‘linear’] ) is giving an error if I choose a sigmoid activation function.
Could anybody explain why?
Thanks in advance!