Author: bugman
Date: Tue Nov 11 17:37:03 2014
New Revision: 26537

URL: http://svn.gna.org/viewcvs/relax?rev=26537&view=rev
Log:
Python 3 fixes via 2to3 - the xrange() function has been replaced by range().

The command used was:
2to3 -j 4 -w -f xrange .


Modified:
    
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/flag_array.py
    
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/frame_rotations.py
    
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/tensor_projections.py

Modified: 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/flag_array.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/flag_array.py?rev=26537&r1=26536&r2=26537&view=diff
==============================================================================
--- 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/flag_array.py
       (original)
+++ 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/flag_array.py
       Tue Nov 11 17:37:03 2014
@@ -51,7 +51,7 @@
 def check5(flags, N=1, verb=True):
     for i in range(N):
         flag = False
-        for i in xrange(len(flags)):
+        for i in range(len(flags)):
             if flags[i] == 0:
                 flag = True
                 break

Modified: 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/frame_rotations.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/frame_rotations.py?rev=26537&r1=26536&r2=26537&view=diff
==============================================================================
--- 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/frame_rotations.py
  (original)
+++ 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/frame_rotations.py
  Tue Nov 11 17:37:03 2014
@@ -14,7 +14,7 @@
 def rot1(Ri, R, RT, N=1, verb=True):
     d = zeros((len(Ri), 3, 3), float64)
     for i in range(N):
-        for j in xrange(len(Ri)):
+        for j in range(len(Ri)):
             d[j] = dot(R, dot(Ri[j], RT))
     if verb:
         print("\n1st rotation - element by element R.Ri[i].RT.")

Modified: 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/tensor_projections.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/tensor_projections.py?rev=26537&r1=26536&r2=26537&view=diff
==============================================================================
--- 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/tensor_projections.py
       (original)
+++ 
branches/frame_order_cleanup/test_suite/shared_data/frame_order/timings/tensor_projections.py
       Tue Nov 11 17:37:03 2014
@@ -11,7 +11,7 @@
 def proj1(vect, A, N=1, verb=True):
     d = zeros(len(vect), float64)
     for i in range(N):
-        for j in xrange(len(vect)):
+        for j in range(len(vect)):
             d[j] = dot(vect[j], dot(A, vect[j]))
     if verb:
         print("\n1st projection - element by element r[i].A.r[i].")
@@ -50,7 +50,7 @@
     for i in range(N):
         vect2 = vect**2
         double_vect = 2.0 * vect
-        for j in xrange(len(vect)):
+        for j in range(len(vect)):
             d[j] = vect2[j][0]*A[0, 0] + vect2[j][1]*A[1, 1] + 
vect2[j][2]*(A[2, 2]) + double_vect[j][0]*vect[j][1]*A[0, 1] + 
double_vect[j][0]*vect[j][2]*A[0, 2] + double_vect[j][1]*vect[j][2]*A[1, 2]
     if verb:
         print("\n5th projection - expansion and sum.")


_______________________________________________
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

To unsubscribe from this list, get a password
reminder, or change your subscription options,
visit the list information page at
https://mail.gna.org/listinfo/relax-commits

Reply via email to