-
Notifications
You must be signed in to change notification settings - Fork 0
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
Simplify properties #9
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me. Are you going to add the serializer to this PR?
Yes, here it is. I currently define |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried the serialization and deserialization pair, which works nicely. One practical thing we'll need is partial/sequential deserialization from a serialized data file because the file would be too large to deserialize in one go. I assume some interface like the following:
data = Deserializer("data.h5")
# Sequential deserialization
for structure in data
# Do something
end
# Partial deserialization
for id in some_id_list
structure = data[id] # Or multiple ids if it is more efficient
# Do something
end
This can be done in a separated pull request.
Great idea with the lazy deserialization type. I might also try a corresponding "Serializer" with e.g. a |
Closes #8
I did a little more than simplifying the properties, adding an
atoms
field toProteinStructure
, and removing thebackbone
field fromProteinChain
. This is breaking and intended to be pushed with a version that easily serializes to HDF5.Could use some more unit tests.