Loss Function for Logistic Regression

The reason we were not reaching the optimal solution using perceptron and even sigmoid because points are being selected randomly and each…