Author: bugman Date: Wed May 29 10:56:38 2013 New Revision: 19765 URL: http://svn.gna.org/viewcvs/relax?rev=19765&view=rev Log: Large simplification of the Relax_disp system tests using Hansen's CPMG data. Instead of calculating the R2eff values in the test, these are read from the high error precision results files in test_suite/shared_data/dispersion/Hansen. This allows the model parameters to be consistently found and to be identical between different runs of the test. Modified: branches/relax_disp/test_suite/system_tests/relax_disp.py branches/relax_disp/test_suite/system_tests/scripts/relax_disp/hansen_data.py Modified: branches/relax_disp/test_suite/system_tests/relax_disp.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/test_suite/system_tests/relax_disp.py?rev=19765&r1=19764&r2=19765&view=diff ============================================================================== --- branches/relax_disp/test_suite/system_tests/relax_disp.py (original) +++ branches/relax_disp/test_suite/system_tests/relax_disp.py Wed May 29 10:56:38 2013 @@ -63,7 +63,7 @@ """ # Set the model. - ds.models = ['R2eff', 'LM63'] + ds.models = ['LM63'] # Execute the script. self.interpreter.run(script_file=status.install_path + sep+'test_suite'+sep+'system_tests'+sep+'scripts'+sep+'relax_disp'+sep+'hansen_data.py') @@ -92,7 +92,7 @@ """ # Set the model. - ds.models = ['R2eff', 'CR72'] + ds.models = ['CR72'] # Execute the script. self.interpreter.run(script_file=status.install_path + sep+'test_suite'+sep+'system_tests'+sep+'scripts'+sep+'relax_disp'+sep+'hansen_data.py') Modified: branches/relax_disp/test_suite/system_tests/scripts/relax_disp/hansen_data.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/test_suite/system_tests/scripts/relax_disp/hansen_data.py?rev=19765&r1=19764&r2=19765&view=diff ============================================================================== --- branches/relax_disp/test_suite/system_tests/scripts/relax_disp/hansen_data.py (original) +++ branches/relax_disp/test_suite/system_tests/scripts/relax_disp/hansen_data.py Wed May 29 10:56:38 2013 @@ -9,11 +9,8 @@ from status import Status; status = Status() -# Analysis variables. -##################### - # The dispersion models. -MODELS = ['R2eff', 'fast 2-site'] +MODELS = ['LM63'] if hasattr(ds, 'models'): MODELS = ds.models @@ -25,13 +22,6 @@ -# Set up the data pipe. -####################### - -# The results directory. -if not hasattr(ds, 'tmpdir'): - ds.tmpdir = None - # Create the data pipe. pipe_name = 'base pipe' pipe_bundle = 'relax_disp' @@ -40,86 +30,12 @@ # The path to the data files. data_path = status.install_path + sep+'test_suite'+sep+'shared_data'+sep+'dispersion'+sep+'Hansen' -# Load the sequence. -sequence.read('fake_sequence.in_trunc', dir=status.install_path + sep+'test_suite'+sep+'shared_data'+sep+'dispersion'+sep+'Hansen', res_num_col=1, res_name_col=2) +# Load the saved base pipe +results.read(data_path+sep+'base_pipe') -# Name the spins so they can be matched to the assignments. -spin.name(name='N') - -# Set the relaxation dispersion experiment type. -relax_disp.exp_type('cpmg fixed') - -# The spectral data - spectrum ID, peak list file name, CPMG frequency (Hz), spectrometer frequency in Hertz. -data = [ - ['500_reference.in', '500_MHz'+sep+'reference.in_trunc', None, 500e6], - ['500_66.667.in', '500_MHz'+sep+'66.667.in_trunc', 66.6666, 500e6], - ['500_133.33.in', '500_MHz'+sep+'133.33.in_trunc', 133.3333, 500e6], - ['500_133.33.in.bis', '500_MHz'+sep+'133.33.in.bis_trunc', 133.3333, 500e6], - ['500_200.in', '500_MHz'+sep+'200.in_trunc', 200.0000, 500e6], - ['500_266.67.in', '500_MHz'+sep+'266.67.in_trunc', 266.6666, 500e6], - ['500_333.33.in', '500_MHz'+sep+'333.33.in_trunc', 333.3333, 500e6], - ['500_400.in', '500_MHz'+sep+'400.in_trunc', 400.0000, 500e6], - ['500_466.67.in', '500_MHz'+sep+'466.67.in_trunc', 466.6666, 500e6], - ['500_533.33.in', '500_MHz'+sep+'533.33.in_trunc', 533.3333, 500e6], - ['500_533.33.in.bis', '500_MHz'+sep+'533.33.in.bis_trunc', 533.3333, 500e6], - ['500_600.in', '500_MHz'+sep+'600.in_trunc', 600.0000, 500e6], - ['500_666.67.in', '500_MHz'+sep+'666.67.in_trunc', 666.6666, 500e6], - ['500_733.33.in', '500_MHz'+sep+'733.33.in_trunc', 733.3333, 500e6], - ['500_800.in', '500_MHz'+sep+'800.in_trunc', 800.0000, 500e6], - ['500_866.67.in', '500_MHz'+sep+'866.67.in_trunc', 866.6666, 500e6], - ['500_933.33.in', '500_MHz'+sep+'933.33.in_trunc', 933.3333, 500e6], - ['500_933.33.in.bis', '500_MHz'+sep+'933.33.in.bis_trunc', 933.3333, 500e6], - ['500_1000.in', '500_MHz'+sep+'1000.in_trunc', 1000.0000, 500e6], - ['800_reference.in', '800_MHz'+sep+'reference.in_trunc', None, 800e6], - ['800_66.667.in', '800_MHz'+sep+'66.667.in_trunc', 66.6666, 800e6], - ['800_133.33.in', '800_MHz'+sep+'133.33.in_trunc', 133.3333, 800e6], - ['800_133.33.in.bis', '800_MHz'+sep+'133.33.in.bis_trunc', 133.3333, 800e6], - ['800_200.in', '800_MHz'+sep+'200.in_trunc', 200.0000, 800e6], - ['800_266.67.in', '800_MHz'+sep+'266.67.in_trunc', 266.6666, 800e6], - ['800_333.33.in', '800_MHz'+sep+'333.33.in_trunc', 333.3333, 800e6], - ['800_400.in', '800_MHz'+sep+'400.in_trunc', 400.0000, 800e6], - ['800_466.67.in', '800_MHz'+sep+'466.67.in_trunc', 466.6666, 800e6], - ['800_533.33.in', '800_MHz'+sep+'533.33.in_trunc', 533.3333, 800e6], - ['800_533.33.in.bis', '800_MHz'+sep+'533.33.in.bis_trunc', 533.3333, 800e6], - ['800_600.in', '800_MHz'+sep+'600.in_trunc', 600.0000, 800e6], - ['800_666.67.in', '800_MHz'+sep+'666.67.in_trunc', 666.6666, 800e6], - ['800_733.33.in', '800_MHz'+sep+'733.33.in_trunc', 733.3333, 800e6], - ['800_800.in', '800_MHz'+sep+'800.in_trunc', 800.0000, 800e6], - ['800_866.67.in', '800_MHz'+sep+'866.67.in_trunc', 866.6666, 800e6], - ['800_933.33.in', '800_MHz'+sep+'933.33.in_trunc', 933.3333, 800e6], - ['800_933.33.in.bis', '800_MHz'+sep+'933.33.in.bis_trunc', 933.3333, 800e6], - ['800_1000.in', '800_MHz'+sep+'1000.in_trunc', 1000.0000, 800e6] -] - -# Loop over the spectra. -for id, file, cpmg_frq, H_frq in data: - # Load the peak intensities. - spectrum.read_intensities(file=file, dir=data_path, spectrum_id=id, int_method='height') - - # Set the relaxation dispersion CPMG frequencies. - relax_disp.cpmg_frq(spectrum_id=id, cpmg_frq=cpmg_frq) - - # Set the NMR field strength of the spectrum. - spectrometer.frequency(id=id, frq=H_frq) - - # Relaxation dispersion CPMG constant time delay T (in s). - relax_disp.relax_time(spectrum_id=id, time=0.030) - -# Specify the duplicated spectra. -spectrum.replicated(spectrum_ids=['500_133.33.in', '500_133.33.in.bis']) -spectrum.replicated(spectrum_ids=['500_533.33.in', '500_533.33.in.bis']) -spectrum.replicated(spectrum_ids=['500_933.33.in', '500_933.33.in.bis']) -spectrum.replicated(spectrum_ids=['800_133.33.in', '800_133.33.in.bis']) -spectrum.replicated(spectrum_ids=['800_533.33.in', '800_533.33.in.bis']) -spectrum.replicated(spectrum_ids=['800_933.33.in', '800_933.33.in.bis']) - -# Peak intensity error analysis. -spectrum.error_analysis(subset=['500_reference.in', '500_66.667.in', '500_133.33.in', '500_133.33.in.bis', '500_200.in', '500_266.67.in', '500_333.33.in', '500_400.in', '500_466.67.in', '500_533.33.in', '500_533.33.in.bis', '500_600.in', '500_666.67.in', '500_733.33.in', '500_800.in', '500_866.67.in', '500_933.33.in', '500_933.33.in.bis', '500_1000.in']) -spectrum.error_analysis(subset=['800_reference.in', '800_66.667.in', '800_133.33.in', '800_133.33.in.bis', '800_200.in', '800_266.67.in', '800_333.33.in', '800_400.in', '800_466.67.in', '800_533.33.in', '800_533.33.in.bis', '800_600.in', '800_666.67.in', '800_733.33.in', '800_800.in', '800_866.67.in', '800_933.33.in', '800_933.33.in.bis', '800_1000.in']) - -# Deselect unresolved spins. -deselect.read(file='unresolved', dir=data_path+sep+'500_MHz', res_num_col=1) -deselect.read(file='unresolved', dir=data_path+sep+'800_MHz', res_num_col=1) +# Create the R2eff data pipe and load the results. +pipe.create(pipe_name='R2eff', bundle=pipe_bundle, pipe_type='relax_disp') +results.read(data_path+sep+'r2eff_pipe') # Auto-analysis execution.