-
Notifications
You must be signed in to change notification settings - Fork 412
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
In case of MPS device also copy batch to CPU #3105
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR!
I think there's a minor error -- once fixed looks good to me! Please feel free to rerequest when this is merged
63d407a
to
3d3c6d0
Compare
Hm... labels can be a complex type so directly calling to seems to fail tests |
To ensure compatibility with I hope this is not a breaking change, it felt a bit more natural to modify the labels outside of this method as well but there may be reasons for doing it there that I am unaware of. In addition |
What does this PR do?
This PR fixes an issue when using MPS device and composer's classifier. When computing metrics,
outputs
is copied to the cpu but notbatch
which creates some downstream error.What issue(s) does this change relate to?
Fixes #3094
Before submitting
pre-commit
on your change? (see thepre-commit
section of prerequisites)