diff --git a/examples/siamese/mnist_siamese.lua b/examples/siamese/mnist_siamese.lua index 468e766c9..fd68167da 100644 --- a/examples/siamese/mnist_siamese.lua +++ b/examples/siamese/mnist_siamese.lua @@ -59,7 +59,7 @@ return function(params) function siameseLabelHook(input, dblabel) -- cosine embedding criterion requires negative samples to be -- assigned class -1 - dblabel[torch.eq(dblabel,0)]=torch.eq(dblabel,0):fill(-1) + dblabel[torch.eq(dblabel,0)]=-1 return dblabel end @@ -71,4 +71,3 @@ return function(params) labelHook = siameseLabelHook } end -