You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran into some strange behavior in CloseBipartitePairContainer when it includes pairs that are both contained in a single rigid body. When one tries to do this, the container only includes pairs formed between members of the first list and completely excludes any members from the second.
Here is a short script reproducing the error:
import IMP
import IMP.core
import IMP.atom
m = IMP.Model()
molA = IMP.atom.Molecule.setup_particle(m, IMP.Particle(m))
molB = IMP.atom.Molecule.setup_particle(m, IMP.Particle(m))
mols = [molA, molB]
for i, mol in enumerate(mols):
p1 = IMP.core.XYZR.setup_particle(IMP.Particle(m))
p2 = IMP.core.XYZR.setup_particle(IMP.Particle(m))
p1.set_coordinates(IMP.algebra.Vector3D(i, i + 1, 0.0))
p2.set_coordinates(IMP.algebra.Vector3D(i + 1, i + 1, 0.0))
p1.set_radius(1.0)
p2.set_radius(1.0)
d1 = IMP.atom.Mass.setup_particle(m, p1, 1.0)
d2 = IMP.atom.Mass.setup_particle(m, p2, 1.0)
mol.add_child(d1)
mol.add_child(d2)
rigid_mols = [IMP.atom.create_rigid_body(mol) for mol in mols]
list0 = [mol.get_child(0) for mol in mols]
list1 = [mol.get_child(1) for mol in mols]
lsc0 = IMP.container.ListSingletonContainer(m, list0)
lsc1 = IMP.container.ListSingletonContainer(m, list1)
bcp = IMP.container.CloseBipartitePairContainer(lsc0, lsc1, 5.0)
m.update()
print("Mol A:\n", lsc0.get_contents())
print("Mol B:\n", lsc1.get_contents())
print("Bipartitle container pairs:", bcp.get_contents())
The text was updated successfully, but these errors were encountered:
I ran into some strange behavior in CloseBipartitePairContainer when it includes pairs that are both contained in a single rigid body. When one tries to do this, the container only includes pairs formed between members of the first list and completely excludes any members from the second.
Here is a short script reproducing the error:
The text was updated successfully, but these errors were encountered: