Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
Index your code
hub
/
github.com/lazyprogrammer/machine_learning_examples
/ cost
Function
cost
ann_class2/util.py:177–179 ·
view source on GitHub ↗
(p_y, t)
Source
from the content-addressed store, hash-verified
175
176
177
def
cost(p_y, t):
178
tot = t * np.log(p_y)
179
return
-tot.sum()
180
181
182
def
gradW(t, y, X):
Callers
6
main
Function · 0.90
main
Function · 0.90
main
Function · 0.90
main
Function · 0.90
benchmark_full
Function · 0.70
benchmark_pca
Function · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected