PyTorch-Beam-Search-Decoding icon indicating copy to clipboard operation
PyTorch-Beam-Search-Decoding copied to clipboard

Score function

Open matgreco opened this issue 5 years ago • 1 comments

Hi,

Thank's for this work. It's really usefull.

Why you defined the score function as (line 66)??

self.logp / float(self.leng - 1 + 1e-6) + alpha * reward

Can you explain this definition?

Thank's, Best

matgreco avatar Dec 24 '19 20:12 matgreco

maybe it's length normalization

Doragd avatar Aug 04 '20 05:08 Doragd