Closed zfyu closed 5 years ago
Hi @zfyu, sorry to tell you that, but you can't! Theoretically you could, but you would need to modify the tensorflow crf implementation so that the dynamic decoding keeps track of the top k at every recurrence step.
Thank you for your suggestion. @guillaumegenthial
how to get top-k best candidate sequences when using CRF for decoding in tensorflow?
Hi, maybe you can consider re-implement the n-best output algorithm mentioned in this tool by yourself, https://taku910.github.io/crfpp/
@createmomo Thank you very much. I'll try it. BTW, I found that I read your blog "CRF Layer on the Top of BiLSTM - 1" a few days ago. What a coincidence! It is very helpful!
how to get top-k best candidate sequences when using CRF for decoding in tensorflow?