Residue rotation and UA translation axes for terminal residues - #416
Residue rotation and UA translation axes for terminal residues#416ioanaapapa wants to merge 21 commits into
Conversation
…d atoms + average of all other heavy atoms in resid
harryswift01
left a comment
There was a problem hiding this comment.
Thank you for sending these changes through! I think this is a really good improvement, and it’s great to see the terminal residue handling becoming more robust and independent of atom indexing. I’ve just left a few comments around some small technical and maintainability points. If you’re able to have a look through them and let me know what you think, that would be great. Overall, I think this is looking really good and is very close to being ready to go in!
| code convention). | ||
| - If bonded to other residues: | ||
|
|
||
| - If bonded to only one other residue: |
There was a problem hiding this comment.
I wonder if it might be worth splitting the different cases into their own helper functions and calling them from the if statements? This function is getting quite large now, and there’s a fair bit of conditional logic to follow. I think separating the cases out could make the overall flow a bit clearer and easier to maintain as the logic grows.
There was a problem hiding this comment.
This is a good idea as it would make the code easier to follow.
|
@harryswift01 Thank you, Harry! I will make the changes. |
…ed from get_residue_axes and get_UA_axes
Summary
Terminal residue axes are no longer dependent on atom indices. The edge atom (i.e. heavy atom bonded to neighbour residue) is chosen alongside the average position of heavy atoms bonded to the edge atom and average position of all other heavy in the residue as the three points used for determining the axes. The centre of rotation (at res level)/translation (at UA level) and axes are then computed from the three points similar to the case of non-terminal residues.
Changes
Terminal residue treatment was changed
Edge cases have been introduced
Tests for terminal residues and edge cases
Documentation
get_residue_axes and get_UA_axes structure change
Impact