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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Fix issues with pytorch 1.13 on MacOs #151

Merged
merged 4 commits into from Dec 17, 2022
Merged

[WIP] Fix issues with pytorch 1.13 on MacOs #151

merged 4 commits into from Dec 17, 2022

Conversation

lsickert
Copy link
Collaborator

Description

This PR fixes issues that exist in PyTorch v1.13 on MacOS related to the following issues in PyTorch: 88049 88826

The current workaround is it to revert to PyTorch 1.12.1 and disable the use of the mps device on MacOS, but the issues should be fully resolved in PyTorch 1.13.1 (Release Tracker) which is scheduled to be GA by Dec 15th.

Related Issue

150

Type of Change

  • 馃摎 Examples / docs / tutorials / dependencies update
  • 馃敡 Bug fix (non-breaking change which fixes an issue)
  • 馃 Improvement (non-breaking change which improves an existing feature)
  • 馃殌 New feature (non-breaking change which adds functionality)
  • 馃挜 Breaking change (fix or feature that would cause existing functionality to change)
  • 馃攼 Security fix

Checklist

  • I've read the CODE_OF_CONDUCT.md document.
  • I've read the CONTRIBUTING.md guide.
  • I've updated the code style using make codestyle.
  • I've written tests for all new methods and classes that I created.
  • I've written the docstring in Google format for all the methods and classes that I used.

@lsickert lsickert added the bug Something isn't working label Dec 12, 2022
@lsickert lsickert linked an issue Dec 12, 2022 that may be closed by this pull request
@lsickert lsickert linked an issue Dec 16, 2022 that may be closed by this pull request
@lsickert
Copy link
Collaborator Author

@gsarti I updated Pytorch 1.13.1 and the installation issues on macOS are now fully resolved. However, not all of the issues with MPS are fixed by 1.13.1 and some of the tests are still failing. So I left the workaround of hardcoding the device to CPU on MPS devices in the code and added a comment about this. I would suggest merging this branch and closing the associated bug ticket and I will open a new issue to track the remaining issues with MPS as I think there is not much we can currently do until newer PyTorch versions might fix the remaining issues.

@gsarti
Copy link
Member

gsarti commented Dec 16, 2022

Checked the changes, could you justify why setting python3 instead of 3.8 in the pre-commit config? Apart from that, LGTM!

Copy link
Member

@gsarti gsarti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good for merging as temporary MPS fix

@lsickert
Copy link
Collaborator Author

Checked the changes, could you justify why setting python3 instead of 3.8 in the pre-commit config? Apart from that, LGTM!

Sorry, that was just meant temporarily to make things more comfortable during development as I am usually not on 3.8 anymore and sometimes forget to switch the version between different projects. I can revert it back to 3.8, but since the code will be checked against the different versions on GitHub anyways maybe we could just leave it like that?

@gsarti gsarti merged commit a54cb58 into main Dec 17, 2022
@gsarti gsarti deleted the fix-macos-issues branch February 24, 2023 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: MPS not working properly on pytorch 1.12
2 participants