You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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
The text was updated successfully, but these errors were encountered:
nlpaug version: 1.1.11
Mac OS
The text was updated successfully, but these errors were encountered: