-
Notifications
You must be signed in to change notification settings - Fork 217
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
Remove unwrap_tensor_subclass
#462
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/ao/462
Note: Links to docs will display an error until the docs builds have been completed. ❗ 1 Active SEVsThere are 1 currently active SEVs. If your PR is affected, please view them below: ❌ 1 New Failure, 1 Unrelated FailureAs of commit 5e79ca8 with merge base 39b02de ( NEW FAILURE - The following job has failed:
FLAKY - The following job failed but was likely due to flakiness present on trunk:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
@pytorchbot merge |
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Merge failedReason: PR #462 has not been reviewed yet |
Summary: `unwrap_tensor_subclass` is incorporated in export stack natively after pytorch/pytorch#127431 so we can remove this workaround now Test Plan: python test/quantization/test_quant_api.py python test/integration/test_integration.py Reviewers: Subscribers: Tasks: Tags:
"""Unwraps (nested) tensor subclass in the model to plain tensors | ||
This is a workaround to make a model with tensor subclass to work with `torch.export.export` | ||
and `torch.aot_compile`, we hope this can be integrated into compile stack soon | ||
tracking issue: https://github.com/pytorch/ao/issues/345 |
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.
oh @jerryzh168 I think you still need this logic.
To clarify, there are two separate PRs/issues:
(1) nested subclass support here: pytorch/pytorch#127431. This PR allows for "nested wrapper subclasses at the graph boundaries", so e.g. we now support DTensor(Float8Tensor) as a graph input to torch.compile
).
(2) what I think is relevant to this PR, is that we eventually want to take the parametrization logic you have here and upstream it directly into export so it can happen automatically and you don't need to do it manually before exporting / running AOTI. This is not currently fixed, but I recently filed a tracker issue for it (with a float8 repro) here: pytorch/pytorch#129682. @tugsbayasgalan is going to be picking it up soon.
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.
ah I see, OK I can wait until pytorch/pytorch#129682 is resolved as well
Is this still in the roadmap? |
yeah, this is going to be unblocked/fixed by pytorch/pytorch#141941 |
I think that it is merged right? |
Summary:
unwrap_tensor_subclass
is incorporated in export stack natively after pytorch/pytorch#127431 so we can remove this workaround nowTest Plan:
python test/quantization/test_quant_api.py
python test/integration/test_integration.py
Reviewers:
Subscribers:
Tasks:
Tags: