mailr22628 - in /trunk: ./ test_suite/shared_data/frame_order/cam/generate_base.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on April 03, 2014 - 19:31:
Author: bugman
Date: Thu Apr  3 19:31:33 2014
New Revision: 22628

URL: http://svn.gna.org/viewcvs/relax?rev=22628&view=rev
Log:
Merged revisions 22039-22040 via svnmerge from 
svn+ssh://bugman@xxxxxxxxxxx/svn/relax/branches/double_rotor

........
  r22039 | bugman | 2014-01-21 11:43:21 +0100 (Tue, 21 Jan 2014) | 7 lines
  
  Reintroduced the distribution PDB file creation to the frame order test 
data generation script.
  
  This is the generate_base.py script in the 
test_suite/shared_data/frame_order/cam directory.  The
  ability to create the distribution.pdb file was long lost in this script, 
and can now be activated
  using the DIST_PDB class variable.
........
  r22040 | bugman | 2014-01-22 11:19:22 +0100 (Wed, 22 Jan 2014) | 6 lines
  
  The Frame Order test data generation base script now loads all structures 
before rotating them.
  
  This allows the progress printout to function correctly by not having any 
user function printouts
  as the rotations are occurring.
........

Modified:
    trunk/   (props changed)
    trunk/test_suite/shared_data/frame_order/cam/generate_base.py

Propchange: trunk/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu Apr  3 19:31:33 2014
@@ -1 +1 @@
-/branches/double_rotor:1-21950,22022-22023
+/branches/double_rotor:1-21950,22022-22023,22039-22040

Modified: trunk/test_suite/shared_data/frame_order/cam/generate_base.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/test_suite/shared_data/frame_order/cam/generate_base.py?rev=22628&r1=22627&r2=22628&view=diff
==============================================================================
--- trunk/test_suite/shared_data/frame_order/cam/generate_base.py       
(original)
+++ trunk/test_suite/shared_data/frame_order/cam/generate_base.py       Thu 
Apr  3 19:31:33 2014
@@ -48,6 +48,9 @@
     PIVOT = array([ 37.254, 0.5, 16.7465])
     COM = array([ 26.83678091, -12.37906417,  28.34154128])
 
+    # The PDB distribution flag.
+    DIST_PDB = False
+
     def run(self, save_path=None):
         """Generate the distribution and alignment data.
         
@@ -178,6 +181,14 @@
         sys.stdout.write("\n\nRotating %s states:\n\n" % self.N)
 
         # Load N copies of the original C-domain.
+        if self.DIST_PDB:
+            # Loop over the N states.
+            for i in range(self.N):
+                # Load the structure for the PDB distribution.
+                self.interpreter.structure.read_pdb('1J7P_1st_NH.pdb', 
dir=self.path, set_mol_name='C-dom', set_model_num=i+1)
+
+        # Loop over the N states.
+        self.interpreter.off()
         for i in range(self.N):
             # Print out.
             self._progress(i)
@@ -202,6 +213,10 @@
             # The frame order matrix component.
             self.daeg += kron_prod(self.R, self.R)
 
+            # Rotate the structure for the PDB distribution.
+            if self.DIST_PDB:
+                self.interpreter.structure.rotate(R=self.R, 
origin=self.PIVOT, model=i+1)
+
         # Print out.
         sys.stdout.write('\n\n')
 
@@ -211,6 +226,11 @@
         # Write out the frame order matrix.
         file = open(self.save_path+sep+'frame_order_matrix', 'w')
         print_frame_order_2nd_degree(self.daeg, file=file)
+
+        # Write out the PDB distribution.
+        self.interpreter.on()
+        if self.DIST_PDB:
+            self.interpreter.structure.write_pdb('distribution.pdb', 
compress_type=2, force=True)
 
 
     def _print_axis_system(self):




Related Messages


Powered by MHonArc, Updated Thu Apr 03 19:40:02 2014