def test_logistic_regression_predict(self, get_binary_classification_data):
     X, y = get_binary_classification_data
     clf = LogisticRegression(epochs=100, learning_rate=0.01, checkpoint=10)
     clf.fit(X,y)
     y_pred = clf._predict(X)
     assert y_pred.shape == (y.shape[0],), "y_pred has wrong shape for binary problem"                
     y_pred = clf.predict(X)        
     score = clf.score(X,y)
     assert y_pred.shape == (y.shape[0],), "y_pred has wrong shape for binary problem"
     assert score > 0.3, "Accuracy below 0.3"
     assert score < 1, "Accuracy is greater than or equal to 1"
costs = history.epoch_log['train_cost']
# ---------------------------------------------------------------------------- #
#                            LEARNING CURVE                                    #
# ---------------------------------------------------------------------------- #
#%%
# Learning Curve
data = go.Scatter(x=np.linspace(0, len(costs), len(costs)),
                  y=costs,
                  mode='lines',
                  line=dict(color='steelblue'))
layout = go.Layout(title='Wisconsin Breast Cancer Dataset Learning Curve',
                   xaxis_title="Epochs",
                   yaxis_title='Cross-Entropy Cost',
                   height=400,
                   width=800,
                   showlegend=False,
                   margin=dict(l=10, r=10, t=40, b=10),
                   template='plotly_white')
fig = go.Figure(data=data, layout=layout)
#fig.show()
po.plot(fig, filename="./content/figures/breast_cancer.html", auto_open=False)
# ---------------------------------------------------------------------------- #
#                            EVALUATE                                          #
# ---------------------------------------------------------------------------- #
#%%
# Evaluate
intercept = clf.intercept
coef = clf.coef
score = clf.score(X_test, y_test)
print(score)
#%%