Author: bugman
Date: Sun Nov 2 22:45:56 2014
New Revision: 26422
URL: http://svn.gna.org/viewcvs/relax?rev=26422&view=rev
Log:
The frame_order_simulate.py script now uses lib.text.progress.progress_meter().
This script for simulating the frame order matrix elements now uses the
standard progress meter in
relax to simplify the script. This should also speed up the calculations as
the progress printouts
were slowing down the calculations.
Modified:
branches/frame_order_cleanup/test_suite/shared_data/frame_order/sim_vs_pred_matrix/frame_order_simulate.py
Modified:
branches/frame_order_cleanup/test_suite/shared_data/frame_order/sim_vs_pred_matrix/frame_order_simulate.py
URL:
http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/shared_data/frame_order/sim_vs_pred_matrix/frame_order_simulate.py?rev=26422&r1=26421&r2=26422&view=diff
==============================================================================
---
branches/frame_order_cleanup/test_suite/shared_data/frame_order/sim_vs_pred_matrix/frame_order_simulate.py
(original)
+++
branches/frame_order_cleanup/test_suite/shared_data/frame_order/sim_vs_pred_matrix/frame_order_simulate.py
Sun Nov 2 22:45:56 2014
@@ -11,6 +11,7 @@
from lib.errors import RelaxError
from lib.geometry.angles import wrap_angles
from lib.geometry.rotations import R_random_hypersphere, R_to_euler_zyz
+from lib.text.progress import progress_meter
# Variables.
@@ -70,8 +71,7 @@
self.init_storage()
# Init.
- index, type, round = 0, 0, 0
- char = ['/', '-', '\\', '|']
+ index = 0
# Pre-transpose the eigenframe for speed.
eig_frame_T = transpose(EIG_FRAME)
@@ -97,16 +97,8 @@
# Loop over random starting positions.
while 1:
- # Print out.
- if not index % 200:
- # Sim number.
- sys.stdout.write("\b"*100 + "Sim: %-9i %s" % (index,
char[type]))
- sys.stdout.flush()
-
- # Twirly thing index.
- type += 1
- round += 1
- if type == 4: type = 0
+ # Printout.
+ progress_meter(index, a=1000, b=100000)
# Generate a random rotation.
R_random_hypersphere(self.rot)
_______________________________________________
relax (http://www.nmr-relax.com)
This is the relax-commits mailing list
[email protected]
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