-
Notifications
You must be signed in to change notification settings - Fork 607
Disable exported_program.__call__ #1954
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
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/1954
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit beaf9dc with merge base 98d224e ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This pull request was exported from Phabricator. Differential Revision: D53075378 |
df5981f
to
7c8d4f6
Compare
This pull request was exported from Phabricator. Differential Revision: D53075378 |
7c8d4f6
to
c2cd0ff
Compare
This pull request was exported from Phabricator. Differential Revision: D53075378 |
Summary: X-link: pytorch/pytorch#119466 `ExportedProgram` is an artifact produced by torch.export, containing the graph that is exported, along with other attributes about the original program such as the graph signature, state dict, and constants. One slightly confusing thing that users run into is that they treat the `ExportedProgram` as a `torch.nn.Module`, since the object is callable. However, as we do not plan to support all features that `torch.nn.Module`s have, like hooks, we want to create a distinction between it and the `ExportedProgram` by removing the `__call__` method. Instead users can create a proper `torch.nn.Module` through `exported_program.module()` and use that as a callable. Reviewed By: zhxchen17 Differential Revision: D53075378
c2cd0ff
to
28dce56
Compare
This pull request was exported from Phabricator. Differential Revision: D53075378 |
Summary: X-link: pytorch/pytorch#119466 `ExportedProgram` is an artifact produced by torch.export, containing the graph that is exported, along with other attributes about the original program such as the graph signature, state dict, and constants. One slightly confusing thing that users run into is that they treat the `ExportedProgram` as a `torch.nn.Module`, since the object is callable. However, as we do not plan to support all features that `torch.nn.Module`s have, like hooks, we want to create a distinction between it and the `ExportedProgram` by removing the `__call__` method. Instead users can create a proper `torch.nn.Module` through `exported_program.module()` and use that as a callable. Reviewed By: zhxchen17 Differential Revision: D53075378
28dce56
to
beaf9dc
Compare
Summary: X-link: pytorch/executorch#1954 `ExportedProgram` is an artifact produced by torch.export, containing the graph that is exported, along with other attributes about the original program such as the graph signature, state dict, and constants. One slightly confusing thing that users run into is that they treat the `ExportedProgram` as a `torch.nn.Module`, since the object is callable. However, as we do not plan to support all features that `torch.nn.Module`s have, like hooks, we want to create a distinction between it and the `ExportedProgram` by removing the `__call__` method. Instead users can create a proper `torch.nn.Module` through `exported_program.module()` and use that as a callable. Test Plan: CI Reviewed By: zhxchen17 Differential Revision: D53075378
This pull request was exported from Phabricator. Differential Revision: D53075378 |
This pull request has been merged in f739212. |
This pull request has been reverted by 40356ef. |
Summary:
X-link: pytorch/pytorch#119466
ExportedProgram
is an artifact produced by torch.export, containing the graph that is exported, along with other attributes about the original program such as the graph signature, state dict, and constants. One slightly confusing thing that users run into is that they treat theExportedProgram
as atorch.nn.Module
, since the object is callable. However, as we do not plan to support all features thattorch.nn.Module
s have, like hooks, we want to create a distinction between it and theExportedProgram
by removing the__call__
method. Instead users can create a propertorch.nn.Module
throughexported_program.module()
and use that as a callable.Reviewed By: zhxchen17
Differential Revision: D53075378