diff --git a/src/icesat2_tracks/ICEsat2_SI_tools/angle_optimizer.py b/src/icesat2_tracks/ICEsat2_SI_tools/angle_optimizer.py index fa167fcc..014be176 100644 --- a/src/icesat2_tracks/ICEsat2_SI_tools/angle_optimizer.py +++ b/src/icesat2_tracks/ICEsat2_SI_tools/angle_optimizer.py @@ -208,7 +208,7 @@ def sample(self, fitting_args= None , method='emcee', steps=100, verbose= True, fitting_args, fitting_kargs = self.fitting_args, self.fitting_kargs self.fitter = self.LM.minimize(self.objective_func, self.params, method=method, args=fitting_args, kws=fitting_kargs , - nwalkers=self.nwalkers, steps=steps, pos= self.seeds, **kargs) + nwalkers=self.nwalkers, steps=steps, pos= self.seeds,nan_policy='omit' , **kargs) if verbose: print(self.LM.report_fit(self.fitter)) print('results at self.fitter')