neubig/nn4nlp-code

I've got question about the code in nn4nlp-code/16-reinforce/bilstm-tagger.py

Zacharyyyy opened this issue · 0 comments

I've got a few questions about the code, so I will just list them out. And hope some of you can help.

  1. In line 166, what is "XENT"? this variable only appears once in the code.
  2. In line 106, I don't understand why the probability distribution is calculated in that way?(By the ay my
    compiler said the as_array() part is not right.)
  3. In line 109, "len(x)" is not right. It kept showing this up "TypeError: object of type '_dynet.Expression' has no len()". And I don't really know why the samples are picked this way?