README.md 2.83 KB
Newer Older
samuel hanot's avatar
samuel hanot committed
1
2
3
4
5
6
7
8
9
10
# recursive_gmconvert

Implements divide-and-conquer gmm computation as in [1].

## dependencies

EMAN2 (blake.bcm.edu/emanwiki/EMAN2), used to compute the FSC.

gnuplot (www.gnuplot.info/)

Riccardo  PELLARIN's avatar
Riccardo PELLARIN committed
11
## installation
samuel hanot's avatar
samuel hanot committed
12
13
14
15
16
17

1. clone the repository or download the zip and extract it (we refer to the root of the source tree as `SRC_DIR`).
2. compile gmconvert: `cd ${SRC_DIR}/gmconvert/src ; make ; cd -`
3. if you need to run some commands before executing the scripts, place them in modules.sh

## usage:
samuel hanot's avatar
doc    
samuel hanot committed
18

samuel hanot's avatar
samuel hanot committed
19
```
samuel hanot's avatar
samuel hanot committed
20
${SRC_DIR}/recursive_gmconvert.sh -f map_filename -t threshold -n num_gaussians -N num_iterations [-i first_iteration] [-s]
samuel hanot's avatar
samuel hanot committed
21
```
samuel hanot's avatar
samuel hanot committed
22

samuel hanot's avatar
samuel hanot committed
23
### Required arguments:
samuel hanot's avatar
samuel hanot committed
24

samuel hanot's avatar
samuel hanot committed
25
`-f map_filename`: the file name of the input EM map
samuel hanot's avatar
samuel hanot committed
26

samuel hanot's avatar
samuel hanot committed
27
`-t threshold`: the density threshold
samuel hanot's avatar
samuel hanot committed
28

samuel hanot's avatar
samuel hanot committed
29
`-n num_gaussians`: number of gaussians per sub-process
samuel hanot's avatar
samuel hanot committed
30

31
32
`-0 num_gaussians0`: number of gaussians for first iteration

samuel hanot's avatar
samuel hanot committed
33
`-N num_iterations`: number of recursion levels
samuel hanot's avatar
samuel hanot committed
34

samuel hanot's avatar
samuel hanot committed
35
### Optional arguments:
samuel hanot's avatar
samuel hanot committed
36

samuel hanot's avatar
samuel hanot committed
37
`-i first_iteration`: initial recursion level (defaults to 1)
samuel hanot's avatar
samuel hanot committed
38

samuel hanot's avatar
samuel hanot committed
39
`-s`: enable serial mode
samuel hanot's avatar
samuel hanot committed
40

samuel hanot's avatar
samuel hanot committed
41
`-h`: display this message
samuel hanot's avatar
samuel hanot committed
42

samuel hanot's avatar
samuel hanot committed
43
44
45
Unless you enable serial mode (`-s` flag), all the scripts assume that you are running a cluster with the `slurm` queuing system.

### Output:
samuel hanot's avatar
samuel hanot committed
46

samuel hanot's avatar
samuel hanot committed
47
48
49
50
The script creates a sub-directory (called `i`) for each recursion level `i`, and the output files are called `i/i.gmm` and `i_imp.gmm`.
`i/i.gmm` contains the gmm in `gmconvert` format, and `i_imp.gmm` contains the gmm in `IMP` format (the conversion is handeld by `gmconvert2imp.sh`), which can be read in IMP using `IMP.isd.gmm_tools.decorate_gmm_from_text` function.


samuel hanot's avatar
samuel hanot committed
51
52
## other scripts:

samuel hanot's avatar
doc    
samuel hanot committed
53
`get_maps.sh` is used to run a batch of `recursive_gmconvert.sh` on a list of emdb entries read from standard input. It will fetch the data from the emdb and run the divide-and-conquer GMM calculation.
samuel hanot's avatar
samuel hanot committed
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72

Example 1: `get_maps.sh -n 2 -N 2 -s <<< 1883`
Example 2: `get_maps.sh -n 2 -N 2 -s < input.txt`

In example 2, `input.txt` contains one emdb entry per line.

### Required arguments:

`-n num_gaussians`: number of gaussians per sub-process

`-N num_iterations`: number of recursion levels

### Optional arguments:

`-s`: enable serial mode

`-h`: display this message


samuel hanot's avatar
samuel hanot committed
73
74
75
76
77
78
79
## References

[1] Bayesian multi-scale modeling of macromolecular structures based on cryo-electron microscopy density maps

Samuel Hanot, Massimiliano Bonomi, Charles H Greenberg, Andrej Sali, Michael Nilges, Michele Vendruscolo, Riccardo Pellarin

doi: https://doi.org/10.1101/113951
Riccardo  PELLARIN's avatar
Riccardo PELLARIN committed
80
81
82
83
84
85
86

[2] Multiple subunit fitting into a low-resolution density map of a macromolecular complex using a gaussian mixture model. 

Kawabata, T. , Biophys J 2008 Nov 15;95(10):4643-58.

http://www.cell.com/biophysj/fulltext/S0006-3495%2808%2978604-1

Riccardo  PELLARIN's avatar
Riccardo PELLARIN committed
87
[3] EMAN2: an extensible image processing suite for electron microscopy. 
Riccardo  PELLARIN's avatar
Riccardo PELLARIN committed
88

Riccardo  PELLARIN's avatar
Riccardo PELLARIN committed
89
90
G. Tang, L. Peng, P.R. Baldwin, D.S. Mann, W. Jiang, I. Rees & S.J. Ludtke. 

samuel hanot's avatar
samuel hanot committed
91
(2007) J Struct Biol. 157, 38-46. PMID: 16859925