That is a far more robust solution! Cheers,
Edward On 12 August 2014 15:23, <[email protected]> wrote: > Author: tlinnet > Date: Tue Aug 12 15:23:55 2014 > New Revision: 24999 > > URL: http://svn.gna.org/viewcvs/relax?rev=24999&view=rev > Log: > Implemented partial reading of results file. > > Before reading a results file, it is determined if the file exists. > > This makes is possible to read a directory with partial results from a > previous analysis. > > This can be handsome, if reading R2eff values in R1rho experiments, and the > error estimation has been > prepared with a high number of Monte-Carlo simulations. > > sr #3135(https://gna.org/support/?3135): Optimisation of the R1 relaxation > rate for the off-resonance R1rho relaxation dispersion models. > > Modified: > branches/R1_fitting/auto_analyses/relax_disp.py > > Modified: branches/R1_fitting/auto_analyses/relax_disp.py > URL: > http://svn.gna.org/viewcvs/relax/branches/R1_fitting/auto_analyses/relax_disp.py?rev=24999&r1=24998&r2=24999&view=diff > ============================================================================== > --- branches/R1_fitting/auto_analyses/relax_disp.py (original) > +++ branches/R1_fitting/auto_analyses/relax_disp.py Tue Aug 12 15:23:55 > 2014 > @@ -30,7 +30,8 @@ > from warnings import warn > > # relax module imports. > -from lib.errors import RelaxError, RelaxNoPipeError > +from lib.errors import RelaxError, RelaxFileError, RelaxNoPipeError > +from lib.io import determine_compression, get_file_path > from lib.text.sectioning import section, subsection, subtitle, title > from lib.warnings import RelaxWarning > from pipe_control.mol_res_spin import return_spin, spin_loop > @@ -446,7 +447,21 @@ > self.interpreter.relax_disp.r20_from_min_r2eff(force=True) > > # Use pre-run results as the optimisation starting point. > + # Test if file exists. > if self.pre_run_dir: > + path = self.pre_run_dir + sep + model > + # File path. > + file_path = get_file_path('results', path) > + > + # Test if the file exists and determine the compression type. > + try: > + compress_type, file_path = determine_compression(file_path) > + res_file_exists = True > + > + except RelaxFileError: > + res_file_exists = False > + > + if self.pre_run_dir and res_file_exists: > self.pre_run_parameters(model=model) > > # Otherwise use the normal nesting check and grid search if not > nested. > > > _______________________________________________ > 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 _______________________________________________ relax (http://www.nmr-relax.com) This is the relax-devel 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-devel

