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

Inconsistency in definition of "components" in gp_priors and gp_signals #323

Open
paulthebaker opened this issue Oct 27, 2022 · 0 comments
Assignees
Labels

Comments

@paulthebaker
Copy link
Member

paulthebaker commented Oct 27, 2022

There has some confusion over the keyword argument components in gp_priors.powerlaw.

In gp_signals.FourierBasisGP, the keyword argument components refers to the number of frequency bins in the GP model. In the GP basis functions like gp_bases.createfourierdesignmatrix_red, this same number of frequency bins is called nmodes.

The name components is used extensively in enterprise_extensions to refer to the number of frequency bins, too.

In gp_priors.powerlaw the keyword components=2 refers to the number of sinusoidal components at each frequency bin. This should always be two, for a sine and a cosine. Other powerlaw-like prior functions, turnover and broken_powerlaw, don't take this keyword argument at all. These functions hard code to 2 in the appropriate places. In practice the default is never changed, as far as I know.

Thanks to @danielreardon for pointing this out!

  • Should we remove the components=2 keyword from all powerlaw-like gp_priors? This would assume two sinusoidal components in all cases.
  • Should we rename nmodes to components in gp_bases? This would keep the same naming convention for the prior and basis functions.

Whoever makes changes related to this should add docstrings to the gp_priors functions, to explain what they do and when to use them!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants