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

martinate.sh can't handle martini3 itp files #30

Open
OLaprevote opened this issue May 30, 2021 · 0 comments
Open

martinate.sh can't handle martini3 itp files #30

OLaprevote opened this issue May 30, 2021 · 0 comments

Comments

@OLaprevote
Copy link

Using martini3 forcefield as provided on cgmartini.nl and specifying it in martinate.sh creates empty .itp files (like martini_v3.0_ions.itp) instead of copying the right files (like path/to/martini_v300/martini_v300_ions_v1.itp. It also doesn't include martini_v300_solvents_v1.itp in the topology .top file, which is problematic given it contains martini3 water beads.

Example of command: martinate.sh -f 2oar.pdb -fetch opm --insane-d=5 --insane-sol=W -martinize /path/to/martinize2 -ffdir /path/to/martini_v300 -cg martini3001, as written in martini3 paper

martini.itp is the only one well copied.

My personal quick fix was to write a small script outside of martinate.sh:

cp $input_dir/martini_v300/martini_v3.0.0{,_ions_v1,_phospholipids_v1,_sugars_v1,_solvents_v1}.itp .

sed -i -e 's/martini.itp/martini_v3.0.0.itp/' \
    -e 's/martini_v3.0_sugars/martini_v3.0.0_sugars_v1/' \
    -e 's/martini_v3.0_lipids/martini_v3.0.0_phospholipids_v1/' \
    -e '9i #include\ "martini_v3.0.0_solvents_v1.itp"\n' \
    -e 's/martini_v3.0_ions/martini_v3.0.0_ions_v1/' \
    2oar-cg.top

(It is possible to do this with two expressions instead of five with sed, but I was too lazy to search how.)

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

No branches or pull requests

1 participant