mailr12463 - /branches/bmrb/specific_fns/model_free/bmrb.py


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

Header


Content

Posted by edward on January 31, 2011 - 15:07:
Author: bugman
Date: Mon Jan 31 15:07:25 2011
New Revision: 12463

URL: http://svn.gna.org/viewcvs/relax?rev=12463&view=rev
Log:
The number of spins is now constructed from the 's2' var if 'data_ids' does 
not exist.

This allows v2.1 model-free saveframes to be read.


Modified:
    branches/bmrb/specific_fns/model_free/bmrb.py

Modified: branches/bmrb/specific_fns/model_free/bmrb.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bmrb/specific_fns/model_free/bmrb.py?rev=12463&r1=12462&r2=12463&view=diff
==============================================================================
--- branches/bmrb/specific_fns/model_free/bmrb.py (original)
+++ branches/bmrb/specific_fns/model_free/bmrb.py Mon Jan 31 15:07:25 2011
@@ -116,8 +116,14 @@
             if 'global_chi2' in keys:
                 setattr(cdp, 'chi2', data['global_chi2'])
 
+            # The number of spins.
+            if data['data_ids']:
+                N = len(data['data_ids'])
+            elif data['s2']:
+                N = len(data['s2'])
+
             # Loop over the spins.
-            for i in range(len(data['data_ids'])):
+            for i in range(N):
                 # Generate a spin ID.
                 spin_id = 
mol_res_spin.generate_spin_id(res_num=data['res_nums'][i], 
spin_name=data['atom_names'][i])
 




Related Messages


Powered by MHonArc, Updated Mon Jan 31 15:20:02 2011