Draft: Graph Serialization/Deserialization#65
Open
liamsemeria wants to merge 10 commits intoxtc-tools:mainfrom
Open
Draft: Graph Serialization/Deserialization#65liamsemeria wants to merge 10 commits intoxtc-tools:mainfrom
liamsemeria wants to merge 10 commits intoxtc-tools:mainfrom
Conversation
e968f5b to
1eff19b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Could be used as an interchange format for using graph display tools or other tools independent of xtc itself.
Description
Adds functionality to convert to and from a dict for xtc graphs, and to and from yaml.
One thing to note: when deserializing all list attrs are turned into tuples (since tuples need to be lists to serialize). This is fine now since there are no attrs that use lists instead of tuples, but if for some reason a new xtc op gets added that requires an attribute to be a list then it wouldn't deserialize properly. To fix this maybe the unused type hints in operators.py can be used in op_factory somehow.
For deserializing pad2d #66 is required.
TODO: