Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RuntimeError: DataLoader worker (pid(s) 3954) exited unexpectedly #330

Open
pratikchhapolika opened this issue Mar 3, 2023 · 0 comments

Comments

@pratikchhapolika
Copy link

nlpaug version: 1.1.11

Mac OS

import nlpaug.augmenter.word as naw

text = 'The quick brown fox jumped over the lazy dog'
back_translation_aug = naw.BackTranslationAug(from_model_name='facebook/wmt19-en-ru', to_model_name='facebook/wmt19-ru-en',batch_size=2,force_reload=True)
print(back_translation_aug.augment(text))
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/nlpaug/base_augmenter.py", line 98, in augment
    result = action_fx(clean_data)
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/nlpaug/augmenter/word/back_translation.py", line 70, in substitute
    augmented_text = self.model.predict(data)
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/nlpaug/model/lang_models/machine_translation_transformers.py", line 39, in predict
    src_translated_texts = self.translate_one_step_batched(texts, self.src_tokenizer, self.src_model)
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/nlpaug/model/lang_models/machine_translation_transformers.py", line 58, in translate_one_step_batched
    for batch in tokenized_dataloader:
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 521, in __next__
    data = self._next_data()
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 1186, in _next_data
    idx, data = self._get_data()
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 1152, in _get_data
    success, data = self._try_get_data()
  File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 1003, in _try_get_data
    raise RuntimeError('DataLoader worker (pid(s) {}) exited unexpectedly'.format(pids_str)) from e
RuntimeError: DataLoader worker (pid(s) 3954) exited unexpectedly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant