I use a Keras EfficientNetB7 and transfer learning to solve a binary classification problem. I use tf.keras.layers.Dense(1, activation="sigmoid")(x) for my final layer.
My labels are encoded as the following for the model.fit():
[[1.]
[1.]
[0.]
[1.]
...
[1.]
[1.]
[0.]]
My question is about the output of the model.predict(). For example, if the output is [[0.09122807]], does this mean that the prediction is class 1. or 0.?
Initially, I assumed it would have been class 0. but my model predicts the opposite of this assumption. In some stackoverflow posts, I saw that the output should be used 1 - p where p is the probability of class 1.
There is conflicting information on the net; hence, wanted to ask your guidance.