bert icon indicating copy to clipboard operation
bert copied to clipboard

in the function "get_masked_lm_output", why set the output weights the same as the input embeddings?

Open quincyliang opened this issue 8 years ago • 2 comments

quincyliang avatar Nov 05 '18 08:11 quincyliang

This is fairly standard in terms of training a language model. For one thing, OpenAI GPT also did it, and we wanted to make our model exactly comparable to theirs. But in general it's a way of significantly reducing the number of parameters while improving the results (or at least, it improves results on small LM tasks like Penn TreeBank. It probably doesn't improve results here, but it doesn't hurt and makes the number of parameters much smaller).

jacobdevlin-google avatar Nov 05 '18 18:11 jacobdevlin-google

Same question, Thank you!

guotong1988 avatar Nov 07 '18 05:11 guotong1988