Author: bugman Date: Wed Nov 20 19:51:14 2013 New Revision: 21560 URL: http://svn.gna.org/viewcvs/relax?rev=21560&view=rev Log: Bug fix for the relaxation dispersion model selection. Deselected spins in the current pipe were being skipped, so for model selection between different data pipes that results in spins not being used when they should be. Modified: branches/relax_disp/specific_analyses/relax_disp/api.py branches/relax_disp/specific_analyses/relax_disp/disp_data.py Modified: branches/relax_disp/specific_analyses/relax_disp/api.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/api.py?rev=21560&r1=21559&r2=21560&view=diff ============================================================================== --- branches/relax_disp/specific_analyses/relax_disp/api.py (original) +++ branches/relax_disp/specific_analyses/relax_disp/api.py Wed Nov 20 19:51:14 2013 @@ -1037,7 +1037,7 @@ """ # The cluster loop. - for spin_ids in loop_cluster(): + for spin_ids in loop_cluster(skip_desel=False): yield spin_ids Modified: branches/relax_disp/specific_analyses/relax_disp/disp_data.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/disp_data.py?rev=21560&r1=21559&r2=21560&view=diff ============================================================================== --- branches/relax_disp/specific_analyses/relax_disp/disp_data.py (original) +++ branches/relax_disp/specific_analyses/relax_disp/disp_data.py Wed Nov 20 19:51:14 2013 @@ -596,16 +596,18 @@ return False -def loop_cluster(): +def loop_cluster(skip_desel=True): """Loop over the spin groupings for one model applied to multiple spins. - @return: The list of spin IDs per block will be yielded. - @rtype: list of str + @keyword skip_desel: A flag which if True will cause deselected spins or spin clusters to be skipped. + @type skip_desel: bool + @return: The list of spin IDs per block will be yielded. + @rtype: list of str """ # No clustering, so loop over the sequence. if not hasattr(cdp, 'clustering'): - for spin, spin_id in spin_loop(return_id=True, skip_desel=True): + for spin, spin_id in spin_loop(return_id=True, skip_desel=skip_desel): # Skip protons for MMQ data. if spin.model in MODEL_LIST_MMQ and spin.isotope == '1H': continue @@ -626,7 +628,7 @@ for spin_id in cdp.clustering[key]: # Skip deselected spins. spin = return_spin(spin_id) - if not spin.select: + if skip_desel and not spin.select: continue # Skip protons for MMQ data. @@ -643,7 +645,7 @@ for spin_id in cdp.clustering['free spins']: # Skip deselected spins. spin = return_spin(spin_id) - if not spin.select: + if skip_desel and not spin.select: continue # Skip protons for MMQ data.