Mercurial > repos > rv43 > tomo
diff fit.py @ 71:1cf15b61cd83 draft
planemo upload for repository https://github.com/rolfverberg/galaxytools commit 366e516aef0735af2998c6ff3af037181c8d5213
author | rv43 |
---|---|
date | Mon, 20 Mar 2023 13:56:57 +0000 |
parents | fba792d5f83b |
children | d5e1d4ea2b7e |
line wrap: on
line diff
--- a/fit.py Fri Mar 10 16:39:22 2023 +0000 +++ b/fit.py Mon Mar 20 13:56:57 2023 +0000 @@ -20,7 +20,10 @@ from os import cpu_count, getpid, listdir, mkdir, path from re import compile, sub from shutil import rmtree -from sympy import diff, simplify +try: + from sympy import diff, simplify +except: + pass try: from joblib import Parallel, delayed have_joblib = True @@ -32,12 +35,20 @@ except: have_xarray = False -from .general import illegal_value, is_int, is_dict_series, is_index, index_nearest, \ +#try: +# from .general import illegal_value, is_int, is_dict_series, is_index, index_nearest, \ +# almost_equal, quick_plot #, eval_expr +#except: +# try: +# from sys import path as syspath +# syspath.append(f'/nfs/chess/user/rv43/msnctools/msnctools') +# from general import illegal_value, is_int, is_dict_series, is_index, index_nearest, \ +# almost_equal, quick_plot #, eval_expr +# except: +# from general import illegal_value, is_int, is_dict_series, is_index, index_nearest, \ +# almost_equal, quick_plot #, eval_expr +from general import illegal_value, is_int, is_dict_series, is_index, index_nearest, \ almost_equal, quick_plot #, eval_expr -#from sys import path as syspath -#syspath.append(f'/nfs/chess/user/rv43/msnctools/msnctools') -#from general import illegal_value, is_int, is_dict_series, is_index, index_nearest, \ -# almost_equal, quick_plot #, eval_expr from sys import float_info float_min = float_info.min @@ -1810,8 +1821,8 @@ self.fit(**kwargs) @classmethod - def fit_map(cls, x, ymap, models, normalize=True, **kwargs): - return(cls(x, ymap, models, normalize=normalize, **kwargs)) + def fit_map(cls, ymap, models, x=None, normalize=True, **kwargs): + return(cls(ymap, x=x, models=models, normalize=normalize, **kwargs)) @property def best_errors(self):