Skip to content

Commit

Permalink
Merge pull request #2 from npinto/patch-1
Browse files Browse the repository at this point in the history
Update generic/MalisCriterion.c
(Fixed gradient sign?)
  • Loading branch information
clementfarabet committed Aug 9, 2012
2 parents d3106c8 + 1596af9 commit a35ce8f
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion generic/MalisCriterion.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,6 @@ static int nn_(MalisCriterion_forward)(lua_State *L)
// -ve example pairs
// Sq-Sq loss is used here
dl = max(0.0,conn_data[minEdge]-0.5+margin);
dl *= -1;
loss += 0.5*dl*dl*nPair;
dloss_data[minEdge] += dl*nPair;
if (conn_data[minEdge] > 0.5) { // an error
Expand Down

0 comments on commit a35ce8f

Please sign in to comment.