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

pytorch warning using translate method #22

Open
Ohswedd opened this issue Jun 30, 2021 · 1 comment
Open

pytorch warning using translate method #22

Ohswedd opened this issue Jun 30, 2021 · 1 comment

Comments

@Ohswedd
Copy link

Ohswedd commented Jun 30, 2021

Code

text2text.Handler(["Marco ate a red apple at the restaurant yesterday with his friends."], src_lang="en").translate(tgt_lang='ru')

Warning:

/usr/local/lib/python3.7/dist-packages/torch/_tensor.py:575: UserWarning: floor_divide is deprecated, and will be removed in a future version of pytorch. It currently rounds toward 0 (like the 'trunc' function NOT 'floor'). This results in incorrect rounding for negative values.
To keep the current behavior, use torch.div(a, b, rounding_mode='trunc'), or for actual floor division, use torch.div(a, b, rounding_mode='floor'). (Triggered internally at  /pytorch/aten/src/ATen/native/BinaryOps.cpp:467.)
  return torch.floor_divide(self, other)

Running on google collab.

@artitw
Copy link
Owner

artitw commented Jul 1, 2021

We can look into addressing the deprecation warning. In the meantime, the functionality should not be affected. Feel free to let us know if you experience otherwise.

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

2 participants