This is an automated email from the ASF dual-hosted git repository.
zhasheng pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git
The following commit(s) were added to refs/heads/master by this push:
new d09f68a Update lstm_crf.py (#14865)
d09f68a is described below
commit d09f68af364bae7b959925cdaf2c8f63e0153903
Author: Maoge <[email protected]>
AuthorDate: Fri May 3 11:10:46 2019 -0700
Update lstm_crf.py (#14865)
Fix the typo.
---
example/gluon/lstm_crf/lstm_crf.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/example/gluon/lstm_crf/lstm_crf.py
b/example/gluon/lstm_crf/lstm_crf.py
index 011dcfb..6cdc6e9 100644
--- a/example/gluon/lstm_crf/lstm_crf.py
+++ b/example/gluon/lstm_crf/lstm_crf.py
@@ -118,7 +118,7 @@ class BiLSTM_CRF(Block):
self.transitions.data()[to_scalar(tags_array[idx+1]),
to_scalar(tags_array[idx])] +
feat[to_scalar(tags_array[idx+1])]
score = score + self.transitions.data()[self.tag2idx[STOP_TAG],
-
to_scalar(tags.array[int(tags_array.shape[0]-1)])]
+
to_scalar(tags_array[int(tags_array.shape[0]-1)])]
return score
def _viterbi_decode(self, feats):