Author: bugman Date: Tue Jul 29 13:58:14 2014 New Revision: 24802 URL: http://svn.gna.org/viewcvs/relax?rev=24802&view=rev Log: Created the Frame_order.test_auto_analysis system test. This will be an extremely quick run through of the frame order auto-analysis as this is not currently tested. 1 Sobol' quasi-random integration point will be used for all models for speed. The system test uses the rigid CaM test data to perform a full analysis. Added: branches/frame_order_cleanup/test_suite/system_tests/scripts/frame_order/cam/auto_analysis_to_rigid.py - copied, changed from r24801, branches/frame_order_cleanup/test_suite/shared_data/frame_order/cam/full_analysis.py Modified: branches/frame_order_cleanup/test_suite/system_tests/frame_order.py Modified: branches/frame_order_cleanup/test_suite/system_tests/frame_order.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/system_tests/frame_order.py?rev=24802&r1=24801&r2=24802&view=diff ============================================================================== --- branches/frame_order_cleanup/test_suite/system_tests/frame_order.py (original) +++ branches/frame_order_cleanup/test_suite/system_tests/frame_order.py Tue Jul 29 13:58:14 2014 @@ -238,6 +238,13 @@ setattr(cdp, param, curr) + def test_auto_analysis(self): + """Test the frame order auto-analysis using the rigid CaM test data.""" + + # Execute the script. + self.interpreter.run(script_file=self.cam_path+'auto_analysis_to_rigid.py') + + def test_cam_double_rotor(self): """Test the double rotor frame order model of CaM.""" Copied: branches/frame_order_cleanup/test_suite/system_tests/scripts/frame_order/cam/auto_analysis_to_rigid.py (from r24801, branches/frame_order_cleanup/test_suite/shared_data/frame_order/cam/full_analysis.py) URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/system_tests/scripts/frame_order/cam/auto_analysis_to_rigid.py?p2=branches/frame_order_cleanup/test_suite/system_tests/scripts/frame_order/cam/auto_analysis_to_rigid.py&p1=branches/frame_order_cleanup/test_suite/shared_data/frame_order/cam/full_analysis.py&r1=24801&r2=24802&rev=24802&view=diff ============================================================================== --- branches/frame_order_cleanup/test_suite/shared_data/frame_order/cam/full_analysis.py (original) +++ branches/frame_order_cleanup/test_suite/system_tests/scripts/frame_order/cam/auto_analysis_to_rigid.py Tue Jul 29 13:58:14 2014 @@ -19,14 +19,8 @@ # # ############################################################################### -"""Script for black-box Frame Order analysis. - -This script should be run from the directory where it is found with the commands: - -$ ../../../../../relax full_analysis.py - -The free rotor pseudo-elliptic cone model is not used in this script as the cone X and Y opening angles cannot be differentiated with simply RDC and PCS data, hence this model is perfectly approximated by the free rotor isotropic cone. -""" +"""Script for black-box Frame Order analysis.""" + # Python module imports. from numpy import array @@ -34,40 +28,41 @@ # relax module imports. from auto_analyses.frame_order import Frame_order_analysis +from status import Status; status = Status() # Analysis variables. ##################### # The grid search size (the number of increments per dimension). -GRID_INC = 11 +GRID_INC = 2 # The more precise grid search size for the initial rigid model (the number of increments per dimension). -GRID_INC_RIGID = 31 +GRID_INC_RIGID = 2 # The number of Sobol' points for the PCS numerical integration in the grid searches. -NUM_INT_PTS_GRID = 50 +NUM_INT_PTS_GRID = 1 # The list of the number of Sobol' points for the PCS numerical integration to use iteratively in the optimisations after the grid search (for the PCS data subset). -NUM_INT_PTS_SUBSET = [100] +NUM_INT_PTS_SUBSET = [1] # The minimisation function tolerance cutoff to terminate optimisation (for the PCS data subset, see the minimise user function). FUNC_TOL_SUBSET = [1e-2] # The list of the number of Sobol' points for the PCS numerical integration to use iteratively in the optimisations after the grid search (for all PCS and RDC data). -NUM_INT_PTS_FULL = [100, 1000, 10000] +NUM_INT_PTS_FULL = [1] # The minimisation function tolerance cutoff to terminate optimisation (for all PCS and RDC data, see the minimise user function). -FUNC_TOL_FULL = [1e-2, 1e-3, 1e-4] +FUNC_TOL_FULL = [1e-2] # The optimisation technique. MIN_ALGOR = 'simplex' # The number of Monte Carlo simulations to be used for error analysis at the end of the protocol. -MC_NUM = 100 +MC_NUM = 3 # The number of Sobol' points for the PCS numerical integration during Monte Carlo simulations. -MC_INT_PTS = 100 +MC_INT_PTS = 1 # The minimisation function tolerance cutoff to terminate optimisation during Monte Carlo simulations. MC_FUNC_TOL = 1e-2 @@ -81,11 +76,16 @@ 'iso cone, free rotor', 'iso cone', 'pseudo-ellipse, torsionless', - 'pseudo-ellipse' + 'pseudo-ellipse', + 'double rotor' ] # Set up the base data pipes. ############################# + +# The data paths. +BASE_PATH = status.install_path + sep+'test_suite'+sep+'shared_data'+sep+'frame_order'+sep+'cam'+sep +DATA_PATH = BASE_PATH + sep+'rigid' # The data pipe bundle to group all data pipes. PIPE_BUNDLE = "Frame Order (%s)" % asctime(localtime()) @@ -95,8 +95,8 @@ pipe.create(pipe_name=SUBSET, pipe_type='frame order', bundle=PIPE_BUNDLE) # Read the structures. -structure.read_pdb('1J7O_1st_NH.pdb', dir='..', set_mol_name='N-dom') -structure.read_pdb('1J7P_1st_NH_rot.pdb', dir='..', set_mol_name='C-dom') +structure.read_pdb('1J7O_1st_NH.pdb', dir=BASE_PATH, set_mol_name='N-dom') +structure.read_pdb('1J7P_1st_NH_rot.pdb', dir=BASE_PATH, set_mol_name='C-dom') # Set up the 15N and 1H spins. structure.load_spins(spin_id='@N', ave_pos=False) @@ -147,17 +147,17 @@ # Loop over the alignments. for i in range(len(ln)): # Load the RDCs. - rdc.read(align_id=ln[i], file=rdc_files[i], dir='.', spin_id1_col=1, spin_id2_col=2, data_col=3, error_col=4) + rdc.read(align_id=ln[i], file=rdc_files[i], dir=DATA_PATH, spin_id1_col=1, spin_id2_col=2, data_col=3, error_col=4) # The PCS (only a subset of ~5 spins for fast initial optimisations). - pcs.read(align_id=ln[i], file=pcs_files_subset[i], dir='.', mol_name_col=1, res_num_col=2, spin_name_col=5, data_col=6, error_col=7) + pcs.read(align_id=ln[i], file=pcs_files_subset[i], dir=DATA_PATH, mol_name_col=1, res_num_col=2, spin_name_col=5, data_col=6, error_col=7) # The temperature and field strength. spectrometer.temperature(id=ln[i], temp=303.0) spectrometer.frequency(id=ln[i], frq=rdc_frq[i], units="MHz") # Load the N-domain tensors (the full tensors). -script('../tensors.py') +script(BASE_PATH + 'tensors.py') # Define the domains. domain(id='N', spin_id="#N-dom") @@ -199,7 +199,7 @@ # Load the complete PCS data into the already filled data pipe. for i in range(len(ln)): - pcs.read(align_id=ln[i], file=pcs_files[i], mol_name_col=1, res_num_col=2, spin_name_col=5, data_col=6, error_col=7) + pcs.read(align_id=ln[i], file=pcs_files[i], dir=DATA_PATH, mol_name_col=1, res_num_col=2, spin_name_col=5, data_col=6, error_col=7)