Skip to content

Commit

Permalink
Fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
unnonouno committed Jan 25, 2018
1 parent 273fb42 commit 566eab2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/memnn/memnn.py
Expand Up @@ -67,7 +67,7 @@ def position_encode(embed, sentences):

# To avoid 0/0, we use max(length, 1) here.
# Note that when the length is zero, its embedding is always zero and
# is igrenod.
# is ignored.
length = xp.maximum(
xp.sum((sentences != 0).astype('f'), axis=-1), 1)
length = length.reshape((length.shape + (1, 1)))
Expand Down

0 comments on commit 566eab2

Please sign in to comment.