Sampling with FSMTForConditionalGeneration
Hi, I’m looking to perform some English to German translation usingFSMTForConditionalGenerationmodel (loading pretrained model fromfacebook/wmt19-en-de). The current documentation only mentions decoding using beam search, but I was wondering if it’s also possible to perform sampling for decoding? I read the blog post herehttps://huggingface.co/blog/how-to-generateand it talks about sampling-based decoding with thegeneratemethod. But I wasn’t sure if the same is possible withFSMTForConditionalGenerationmodel. Can I also passdo_sample=Trueandtemperature=<value>toFSMTForConditionalGeneration'sgeneratemethod to perform sampling with specific temperature?
2020-12-24T07:36:00Z
Yes,generatemethod is common for all generative models so you can do sampling with FSMT as well.