- Highlights
- Backwards Incompatible Changes
- Deprecations
- New Features
- Improvements
- Bug fixes
- Performance
- Documentation
- Developers
- Security
TODO
For more details about these highlighted features, you can look at the release blogpost. Below are the full release notes for this release.
[Example] New interface for GraphTransformObserver to enable Node Level provenance tracking (#144277)
We now track a mapping between the nodes in the pre-grad and post-grad graph. See the issue for an example frontend to visualize the transformations. To update your GraphTransformObserver subclasses, instead of overriding on_node_creation and on_node_erase, there are new functions get_node_creation_hook, get_node_erase_hook, get_node_replace_hook and get_deepcopy_hook. These are registered on the GraphModule member of the GraphTransformObserver upon entry and exit of a with block
Version 2.6.0
class MyPrintObserver(GraphTransformObserver):
def on_node_creation(self, node: torch.fx.Node):
print(node)Version 2.7.0
class MyPrintObserver(GraphTransformObserver):
def get_node_creation_hook(self):
def hook(node: torch.fx.Node):
print(node)
return hookUsers should use the dynamo=True option on torch.onnx.export.
Version 2.6.0
torch.onnx.dynamo_export(model, *args, **kwargs)Version 2.7.0
torch.onnx.export(model, args, kwargs=kwargs, dynamo=True)