woutergins / satlas

Statistical Analysis Toolbox for Laser Spectroscopy
Other
6 stars 4 forks source link

Behaviour of FWHM is inconsistent #1

Closed woutergins closed 9 years ago

woutergins commented 9 years ago

Use of FWHM sometimes being a list, sometimes being a float lead to inconsistency, and bugs. Will change this to use of arrays, with expected length of 2 and 1 respectively for the lineshapes that require 2 and 1 numbers for the FWHM.

rubendegroote commented 9 years ago

In addition, I would always calculate the total FWHM when the FWHM is changed.

Consider always using a 2d array, just with one element none if only one is needed? Not sure if that would make things more consistent, or induce consistent bugs ;-).

woutergins commented 9 years ago

Would probably make the behaviour more consistent, albeit pretty weird if you want to use a profile in other code. I would also need to update the code in polar.py to deal with this.

rubendegroote commented 9 years ago

Perhaps write a custom FWHM object that handles this nicely in the background?

rubendegroote commented 9 years ago

This really should not be forgotten: highest priority! It is one of the last things the actual fitting code needs as enhancement!

woutergins commented 9 years ago

Bugfix has been made: every profile now has a fwhm attribute that represents the total fwhm.

rubendegroote commented 9 years ago

You did not push that change anywhere I believe.

woutergins commented 9 years ago

I just pushed now, along with a bugfix for the relative imports that were broken.