mailr18566 - /branches/frame_order_testing/specific_fns/frame_order.py


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

Header


Content

Posted by edward on February 22, 2013 - 14:15:
Author: bugman
Date: Fri Feb 22 14:15:13 2013
New Revision: 18566

URL: http://svn.gna.org/viewcvs/relax?rev=18566&view=rev
Log:
Big set of fixes for the frame order analysis.

RDC and PCS data for the non-moving domain are now not used in the analysis.  
This was not a problem
during development as the test models had no RDC and PCS data for the 
non-moving domain.  Now the
spin_loop() and interatom_loop() methods are called with the moving domain ID 
string as the
selection argument.  This avoids all non-moving domain data, as should happen 
for the analysis.


Modified:
    branches/frame_order_testing/specific_fns/frame_order.py

Modified: branches/frame_order_testing/specific_fns/frame_order.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_testing/specific_fns/frame_order.py?rev=18566&r1=18565&r2=18566&view=diff
==============================================================================
--- branches/frame_order_testing/specific_fns/frame_order.py (original)
+++ branches/frame_order_testing/specific_fns/frame_order.py Fri Feb 22 
14:15:13 2013
@@ -239,15 +239,16 @@
 
         # Array of data types.
         list = []
+        domain_id = cdp.domain[self._domain_moving()]
 
         # RDC search.
-        for interatom in interatomic_loop():
+        for interatom in interatomic_loop(selection1=domain_id):
             if hasattr(interatom, 'rdc'):
                 list.append('rdc')
                 break
 
         # PCS search.
-        for spin in spin_loop():
+        for spin in spin_loop(selection=domain_id):
             if hasattr(spin, 'pcs'):
                 list.append('pcs')
                 break
@@ -628,9 +629,10 @@
 
         # Initialise.
         atomic_pos = []
+        domain_id = cdp.domain[self._domain_moving()]
 
         # Store the atomic positions.
-        for spin, spin_id in spin_loop(return_id=True):
+        for spin, spin_id in spin_loop(selection=domain_id, return_id=True):
             # Skip deselected spins.
             if not spin.select:
                 continue
@@ -729,9 +731,9 @@
                 raise RelaxError("The spectrometer frequency for the 
alignment ID '%s' has not been set." % align_id)
 
             # Spin loop over the domain.
-            id = cdp.domain[self._domain_moving()]
+            domain_id = cdp.domain[self._domain_moving()]
             j = 0
-            for spin in spin_loop(id):
+            for spin in spin_loop(selection=domain_id):
                 # Skip deselected spins.
                 if not spin.select:
                     continue
@@ -799,9 +801,10 @@
         unit_vect = []
         rdc_const = []
         absolute = []
+        domain_id = cdp.domain[self._domain_moving()]
 
         # The unit vectors and RDC constants.
-        for interatom in interatomic_loop():
+        for interatom in interatomic_loop(selection1=domain_id):
             # Get the spins.
             spin1 = return_spin(interatom.spin_id1)
             spin2 = return_spin(interatom.spin_id2)
@@ -875,8 +878,8 @@
             absolute.append([])
 
             # Interatom loop over the domain.
-            id = cdp.domain[self._domain_moving()]
-            for interatom in interatomic_loop(id):
+            domain_id = cdp.domain[self._domain_moving()]
+            for interatom in interatomic_loop(domain_id):
                 # Get the spins.
                 spin1 = return_spin(interatom.spin_id1)
                 spin2 = return_spin(interatom.spin_id2)
@@ -1275,9 +1278,9 @@
                 pcs_flag = True
 
             # Spin loop over the domain.
-            id = cdp.domain[self._domain_moving()]
+            domain_id = cdp.domain[self._domain_moving()]
             pcs_index = 0
-            for spin in spin_loop(id):
+            for spin in spin_loop(domain_id):
                 # Skip deselected spins.
                 if not spin.select:
                     continue
@@ -1296,7 +1299,7 @@
 
             # Interatomic data container loop.
             rdc_index = 0
-            for interatom in interatomic_loop(id):
+            for interatom in interatomic_loop(domain_id):
                 # Get the spins.
                 spin1 = return_spin(interatom.spin_id1)
                 spin2 = return_spin(interatom.spin_id2)
@@ -1650,10 +1653,10 @@
         """
 
         # The moving domain ID.
-        id = cdp.domain[self._domain_moving()]
+        domain_id = cdp.domain[self._domain_moving()]
 
         # Loop over the interatomic data containers for the moving domain 
(for the RDC data).
-        for interatom in interatomic_loop(id):
+        for interatom in interatomic_loop(selection1=domain_id):
             # Get the spins.
             spin1 = return_spin(interatom.spin_id1)
             spin2 = return_spin(interatom.spin_id2)
@@ -1668,7 +1671,7 @@
                 yield ['rdc', interatom.spin_id1, interatom.spin_id2, 
align_id]
 
         # Loop over the spin containers for the moving domain (for the PCS 
data).
-        for spin, spin_id in spin_loop(id, return_id=True):
+        for spin, spin_id in spin_loop(selection=domain_id, return_id=True):
             # Skip deselected spins.
             if not spin.select:
                 continue




Related Messages


Powered by MHonArc, Updated Fri Feb 22 15:00:01 2013