[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[IMP-dev] Recovering of restraints from a model




Recovering restraints (after optimization) from a model in python has an unexpected behaviour. This code fails:

for i in range(model.get_number_of_restraints()):
        r = model.get_restraint(i)
        print "checking restraint ...",r.get_name()
        pairs = r.get_connected_pairs()


All the restraints in the model are connectivity restraints, but I obtain:

raise AttributeError(name)
AttributeError: get_connected_pairs

Same thing if the restraint is EM2DRestraint when accessing non-inherited members.

Is there another way to access the restraints when the optimization has finished?

--
Javier Velazquez
Postdoc at Salilab, UCSF
1700 4th st. Byers Hall, office 503