From: Ralf W. Grosse-K. <rw...@cc...> - 2005-07-30 02:40:06
|
Update of /net/cci/cvs/mmtbx/mmtbx/ncs In directory boa.lbl.gov:/tmp_mnt/net/legless/scratch1/rwgk/dist/mmtbx/mmtbx/ncs Modified Files: restraints.py tst_restraints.py Log Message: group.show_operators() Index: restraints.py =================================================================== RCS file: /net/cci/cvs/mmtbx/mmtbx/ncs/restraints.py,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** restraints.py 29 Jul 2005 12:22:58 -0000 1.6 --- restraints.py 30 Jul 2005 02:39:49 -0000 1.7 *************** *** 492,495 **** --- 492,501 ---- return result + def show_operators(self, sites_cart, out=None, prefix=""): + for i_group,pair_lists in enumerate(self.members): + print >> out, prefix + "NCS restraint group %d:" % (i_group+1) + ncs_operators = pair_lists.operators(sites_cart=sites_cart) + ncs_operators.show(sites_cart=sites_cart, out=out, prefix=" ") + def show_energies_sites(self, sites_cart, Index: tst_restraints.py =================================================================== RCS file: /net/cci/cvs/mmtbx/mmtbx/ncs/tst_restraints.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** tst_restraints.py 28 Jul 2005 21:17:31 -0000 1.4 --- tst_restraints.py 30 Jul 2005 02:39:49 -0000 1.5 *************** *** 271,274 **** --- 271,280 ---- for rms in energies_sites.rms_with_respect_to_averages: assert eps_eq(rms, energies_sites_no_gradients.rms_with_respect_to_average) + out = StringIO() + groups.show_operators(sites_cart=None, out=out) + assert len(out.getvalue().splitlines()) == 98 + out = StringIO() + groups.show_energies_sites(sites_cart=None, out=out) + assert len(out.getvalue().splitlines()) == 188 def exercise(args): |