-
Notifications
You must be signed in to change notification settings - Fork 28
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
Select model feature in process_density_map script #150
Conversation
…script Using process_density_map select_model it is now possible to select a best-fitting model from the MD trajectory: 1. Using a 10-frame window RMSF is calculated for each atom 2. RMSF is converted to B-factors and saved in a PDB file 3. A map is simulated from a model using gemmi library: the simulated map accounts for atomic scattering factors and B-factors determined in the previous step 4. Optionally a mask is created from the model to exclude the solvent signal in the experimental map 5. Experimental and simulated map are compared using real-space cross-correlation or integrated FSC (iFSC, as defined by Wang et al doi:10.7554/eLife17219). The model with the best CC or iFSC is symlinked. In addition map/model FSC plots are generated for each PDB file The script cryofold2_setup is a command-line adaptation of CryoFold2 tutorial (https://github.com/ccccclw/meld/blob/master/docs/tutorial/cryofold_tutorial/setup_cryofold.py)
This looks cool, but I'm a bit leery of the gemmi dependency. How easy is it to install? Is it packaged through conda, etc? It would be great if we can figure out how to make it an optional dependency that's only needed for cryoEM. |
On 06/06/2023 22:53, Justin MacCallum wrote:
This looks cool, but I'm a bit leery of the gemmi dependency. How easy
is it to install? Is it packaged through conda, etc? It would be great
if we can figure out how to make it an optional dependency that's only
needed for cryoEM.
—
Reply to this email directly, view it on GitHub
<#150 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ADR3YEW6TDXOBR2AVSZETJTXJ6KEVANCNFSM6AAAAAAY4R4JM4>.
You are receiving this because you authored the thread.Message ID:
***@***.***>
gemmi is a python package (wrapping some C++ code). It can be easily
installed via pip or conda, so this should not be a problem.
Any other tool that can use atomic scattering factors to simulate an
electron density map from a model will be more challenging to install
(e.g. phenix or Refmac). But I think it is a very important feature to
have at hand compared to simulating EM maps from models using plain
gaussians.
But I agree, it is easier to keep it as an optional dependency (like
mdtraj or mrcfile, I guess). For instance, gemmi can be imported only
when the script "process_density_map" is run with mode "select_model".
Shall I edit my pull request accordingly?
|
I missed that there were conda-forge binaries. Can you add those to the packaging requirements and then we'll test that everything works. |
Sure, but where do I find the packaging requirements file? Is it somewhere in the CI section? Or should I just place the requirement in |
Well, the first place would be in the CI/testing configuration. Have a look at |
Add python dependencies for process_density script: - mdtraj - gemmi - mrcfile - matplotlib - progressbar2
OK, just updated It would be great to have the newest version of meld available in conda-forge, installation from source was not trivial for me. Maybe it would also help to add the python dependencies to |
Yes, can you add this to the dependencies in setup.py? Can you also add this to We should probably cut a new release. It's fairly straightforward, but I just need to find the time. |
…he MD time calculation
This is a limitation of the PDB file format enforced by `mdtraj` when writing trajectory PDB
OK, all done. I also fixed a bug in the script |
It is now possible to set density weighting in cryofold2_setup; temperature settings (ramp between replicas, alphamin/max) are added and properly described in the CLI help
@jlmaccal , apologies for bugging you, just wanted to check on the status of this PR, is there anything else that prevents it from getting merged? |
Just some merge conflicts in process_density_map. Can you resolve them? |
…some functions in process_density_map
@jlmaccal , thanks for a swift response! I've just fixed the merge conflicts |
Implements an improved map/model comparison and also provides an easy way to select a good-fitting single model from a trajectory (for downstream model building). A new dependency is added in this case:
gemmi
, which is a robust (and fast) library to handle PDB and MRC files (see https://gemmi.readthedocs.io/en/latest/)In addition, the cryofold2 tutorial code is converted into a simple command-line script
cryofold2_setup
. This way the user can try the workflow on any data.To test run the following commands with the CryoFold2 tutorial data (https://github.com/maccallumlab/meld/tree/master/docs/tutorial/cryofold_tutorial)
The outputs are written to a new subfolder
Postprocess
:Postprocess/best_model.pdb
: Auto-selected modelPostprocess/plot/rmsd.png
: RMSD to the starting model during the simulation; use to judge convergencePostprocess/plot/cc_ifsc.png
: Real-space CC and iFSC between the experimental map and MD trajectory models; use to select the best modelPostprocess/plot/fsc_step_???.png
: Map/model FSC plots for corresponding MD steps