-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
More generic API for Rainbow variants (#324)
* Initial import from Etienne PR, with some adjustments to make it more generic * Make parameter and error unscaling more generic * Implement peak time computation * Use new generic implementation instead of old RainbowFit * (Slightly better) decorrelate temperature and amplitude by using peak-normalized Planck function * Generalize baseline handling w.r.t. bolometric term initial parameters * Cont. of previous commit * Do not crash in baseline fitting when some bands do not have data * Revert the normalization of Planck term back to 'bolometric', so that it works meaningfully with temperature evolution * Decorrelate Bazin amplitude from rise/fall times by normalizing it to 1 * Pass measurement errors to initial parameter estimators, and use them to better estimate rise/fall times * Add tests for generic RainbowFit implementation * Remove now obsolete versions of RainbowFit * Improve docstrings * Do not raise an exception if the fitting fails but `get_initial=True` * Delayed sigmoid temperature term added * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix the tests * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Do not use 3.9+ features * Improve docstrings and stricter check for parameter unscaling * Minor fixes requested in the review * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Additional fixes requested in the review * Small docstring for the sigmoid mentioning that it has no peak time properly defined * Fix linting errors --------- Co-authored-by: erusseil <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
- Loading branch information
1 parent
84f276f
commit 4128c04
Showing
12 changed files
with
685 additions
and
795 deletions.
There are no files selected for viewing
4 changes: 1 addition & 3 deletions
4
light-curve/light_curve/light_curve_py/features/rainbow/__init__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1 @@ | ||
from .bazin import * | ||
from .rising import * | ||
from .symmetric import * | ||
from .generic import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
118 changes: 0 additions & 118 deletions
118
light-curve/light_curve/light_curve_py/features/rainbow/bazin.py
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.