sczesla / PyAstronomy

A collection of astronomy-related routines in Python
152 stars 35 forks source link

Some further streamlining of syncFit with onedfit #16

Closed pcschneider closed 8 years ago

pcschneider commented 8 years ago

With the required overhaul in mind, I couldn't resist to add some of the required functionality ad hoc to syncFit from onedfit. The additions should just add functionality without breaking anything, e.g., the addition of "steppar" to syncFit.

sczesla commented 8 years ago

Hi PCS,

good patch for the time being. Before merging, I suggest to change the nansum to a simple "sum" in l 142 and 152. It appears to me that nansum is (here) an excellent means to silently hide errors, which should really be dealt with explicitly by the user.

What do you think?

Stefan

pcschneider commented 8 years ago

Oh yeah, definitely. This can cause trouble and shall be dealt with by the user. It is actually remnant from experimenting with NaNs to mark bad pixel. Will update the pull-request.

Btw, we could leave these options in as "robust_sqrt" etc. What do you think?

pcschneider commented 8 years ago

Done. There are now 'robust' functions, but the original numpy.sum functionality is restored. Should be save to pull.