From 103dbd05972802af2cf93d68fd2b8bc1e279d3d3 Mon Sep 17 00:00:00 2001 From: Wasim Shaikh <78263417+ALKRIS-55@users.noreply.github.com> Date: Wed, 14 Feb 2024 01:18:45 +0530 Subject: [PATCH] Issue 1269 : accuracy_score() function updated --- learning4e.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/learning4e.py b/learning4e.py index 12c0defa5..5669c453e 100644 --- a/learning4e.py +++ b/learning4e.py @@ -910,7 +910,7 @@ def weighted_replicate(seq, weights, n): def accuracy_score(y_pred, y_true): assert y_pred.shape == y_true.shape - return np.mean(np.equal(y_pred, y_true)) + return np.mean(y_pred == y_true) def r2_score(y_pred, y_true):
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: