fairseq icon indicating copy to clipboard operation
fairseq copied to clipboard

BacktranslationDataset doesn't work with multiple workers

Open hxbai opened this issue 7 years ago • 5 comments

if num_workers > 0, there will be an error: AttributeError: Can't pickle local object 'SemisupervisedTranslationTask.build_model.<locals>.backtranslate_fn'

hxbai avatar Jun 13 '19 15:06 hxbai

Yeah, I'm not sure BacktranslationDataset was ever intended to be run with multiple workers since it relies on models that are on the GPU. cc @pipibjc

lematt1991 avatar Jun 14 '19 14:06 lematt1991

Thanks for reporting! I will need to find some workaround of it. For now we can only use one worker if we want to use BacktranslationDataset

pipibjc avatar Jun 14 '19 16:06 pipibjc

This issue has been automatically marked as stale. If this issue is still affecting you, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize it yet. If you have any new additional information, please include it with your comment!

stale[bot] avatar Apr 17 '22 20:04 stale[bot]

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please create a new issue with up-to-date information. Thank you!

stale[bot] avatar Apr 27 '22 23:04 stale[bot]

This is still an issue

mnoukhov avatar Aug 08 '22 17:08 mnoukhov