-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Labels
Description
Use a context manager to create new journals which can be serialized as json. It can be replayed and recreate the graph.
@track_changes
def name(self, value):
...
will create Action("name", <traceback>) in the object meta, also serialized into metadata_props
class Action:
id: int
type: str
field: Literal["INIT", "UPDATE", "ADD_NODE", ...]
value: Any
call_stack: str
timestamp: int
Ref:
https://github.com/pytorch/pytorch/blob/main/torch/fx/passes/graph_transform_observer.py