Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initialization strategies for multi-component models #67

Merged
merged 7 commits into from
Mar 11, 2021

Conversation

luisfabib
Copy link
Member

This PR introduces new strategies to initialize the non-linear parameters of the N-component models in the fitmultimodel function.

Three strategies are introduced:

  • Spreading: For each N-component model, the non-linear parameters start values are spread equidistantly over the box constraints. The number of components are changed in a forward matter, i.e. 1,2,...,N. Previously the default in fitmultimodel.
  • Splitting: For each N-component model, the non-linear parameters start values are selected by splitting the location and spread of the components obtained from the N-1 component fit. The number of components are changed in a forward matter, i.e. 1,2,...,N. Now the default in fitmultimodel, faster and more accurate than the spreading strategy.
  • Merging: For each N-component model, the non-linear parameters start values are selected by merging the location and spread of the components obtained from the N+1 component fit. The number of components are changed in a backward matter, i.e. N,N-1,...,1. More accurate than the spreading strategy but might be slower than the splitting strategy.

@luisfabib luisfabib added the enhancement New feature or request label Dec 30, 2020
@luisfabib luisfabib added this to the 0.13.0 milestone Dec 30, 2020
areCenterDistances = [str in ['Mean','Location'] for str in paramnames]
if any(areCenterDistances):
areLocations = [str in ['Mean','Location'] for str in paramnames]
areSpreads = [str in ['Spread','Width','Standard deviation'] for str in paramnames]
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the reason you apply these initialization strategies to the spread? I would think it is needed only for the location. Otherwise, what would you do about other basis function parameters such as asymmetry parameters?

Second question: do all dd model functions have a single location parameter, or there any that have two? This would have implications here.

@luisfabib luisfabib merged commit d054bbe into main Mar 11, 2021
@stestoll stestoll deleted the feature/multimodel_init_strategy branch March 19, 2021 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants