imp icon indicating copy to clipboard operation
imp copied to clipboard

Add an IMP.atom.get_leaves(hier) which is aware of representations

Open cgreenberg opened this issue 8 years ago • 0 comments

Currently the only way to get ALL leaves of all representations is a bit clunky, you have to use selection:

selB = IMP.atom.Selection(hsel,resolution=IMP.atom.ALL_RESOLUTIONS,
                                  representation_type=IMP.atom.BALLS)
selD = IMP.atom.Selection(hsel,resolution=IMP.atom.ALL_RESOLUTIONS,
                                  representation_type=IMP.atom.DENSITIES)
return list(set(selB.get_selected_particles() + selD.get_selected_particles()))

Would be nice to have a quick function to do this.

cgreenberg avatar May 08 '16 22:05 cgreenberg