Skip to content

Commit 94e63cd

Browse files
Chipe1norvig
authored andcommitted
changed mean boolean error (aimacode#325)
* changed mean boolean error * Update learning.py
1 parent b2458ca commit 94e63cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

learning.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def manhattan_distance(predictions, targets):
3333

3434

3535
def mean_boolean_error(predictions, targets):
36-
return mean([(p != t) for p, t in zip(predictions, targets)])
36+
return mean(int(p != t) for p, t in zip(predictions, targets))
3737

3838
# ______________________________________________________________________________
3939

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

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:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy