Skip to content

Commit b89484d

Browse files
committed
Dates, getting nan_to_num order right
1 parent 348541e commit b89484d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ free to fork and modify the code.
1111

1212
MIT License
1313

14-
Copyright (c) 2012-2013 Michael Nielsen
14+
Copyright (c) 2012-2015 Michael Nielsen
1515

1616
Permission is hereby granted, free of charge, to any person obtaining
1717
a copy of this software and associated documentation files (the

src/network2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ def fn(a, y):
5151
to the correct value (0.0).
5252
5353
"""
54-
return np.nan_to_num(np.sum(-y*np.log(a)-(1-y)*np.log(1-a)))
54+
return np.sum(np.nan_to_num(-y*np.log(a)-(1-y)*np.log(1-a)))
5555

5656
@staticmethod
5757
def delta(z, a, y):

0 commit comments

Comments
 (0)