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

Comments #460

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

Comments #460

wants to merge 2 commits into from

Conversation

fgrunewald
Copy link
Member

@fgrunewald fgrunewald commented Sep 6, 2022

This PR implements comment reading and annotation for the itp-reader. It also makes apply_rubber_band label the rubber bands. This PR partially addresses #452 and related issues. With Martini3 it is not possible to distinguish the rubber-bonds from normal bonds via the type. Therefore it is safer to label them with a comment which can be picked up by the meta argument of the interactions. This enables to use the itp-reader to actually draw bonds in VMD and other packages.

@pckroon
Copy link
Member

pckroon commented Nov 23, 2022

As an alternative, should LineParser.parse call the line methods with arguments line, lineno, comment instead of creating the current_comment attribute? Bit more invasive, but maybe it makes the resulting API cleaner?

@fgrunewald
Copy link
Member Author

@pckroon that can be done! And then to solve the problem of Chris you could think of annotating the ss-sequence in the atom types section of the itp file as comment rather than trying to parse a header string like so:

[ moleculetype]
protein 1
[ atoms ]
1 P2 ALA 1 ... ; ss_code

Citations I'm not in favour of parsing form the itp file

@pckroon
Copy link
Member

pckroon commented Nov 23, 2022

Sounds like a reasonable idea. Also note that annotating beads is not exclusive with putting the SecStruct string in the header. The latter is useful when you want to invoke martinize again with the same secstruct.
Assuming we want to annotate atoms with comments about the node in question, do we want to pick a sane format (json?) and just write them all?

Citations I'm not in favour of parsing form the itp file

Sure. And there's indeed a difference between parsing and interpreting.

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

Successfully merging this pull request may close these issues.

2 participants