Skip to content
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

More intuitive interface to serialize objects to dict #448

Open
andrrizzi opened this issue Nov 8, 2019 · 0 comments
Open

More intuitive interface to serialize objects to dict #448

andrrizzi opened this issue Nov 8, 2019 · 0 comments

Comments

@andrrizzi
Copy link
Contributor

For now, the serialization system is based on calling directly __getstate__ and __setstate__. We should add to_dict and from_dict methods.

Note that many objects have __get/setstate__ methods that accept arguments that can be used to improve performance (e.g. SamplerState.__getstate__(ingore_velocities=False)) and should have an equivalent argument in to/from_dict.

See also #407.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant