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

Add more kernels #244

Merged
merged 12 commits into from
May 21, 2024
Merged

Add more kernels #244

merged 12 commits into from
May 21, 2024

Conversation

Scienfitz
Copy link
Collaborator

@Scienfitz Scienfitz commented May 17, 2024

This PR is adding more kernel choices. There are some notable points to consider below:

Bugfix arithmetic Kernels
These used to apply operators like mul(*a_list) but since the operators are defined as 2-input only this failed for a 3-composite kernel test I added. It was fixed via rephrasing it to reduce(mul, a_list)

Removed Prior Iteration Tests
These have become obsolete as the kernels are tested with many priors. I've also reduced the prior used with the scale kernel in iteration tests to one choice, otherwise the list of kernels just got too large.

RQKernel alpha
Even though this kernel has an attribute called alpha (also visible in the equation here) it does not seem to accept priors for it. Hence, I have ignored alpha, both regarding prior and initial value in our corresponding kernel

CosineKernel
I was not able to find prior settings that work with this kernel in the iteration tests. The error I get seem purely computational (a la could not fit any reasonable model etc). I have thus not included it in this PR

@Scienfitz Scienfitz added the new feature New functionality label May 17, 2024
@Scienfitz Scienfitz self-assigned this May 17, 2024
@Scienfitz Scienfitz marked this pull request as ready for review May 17, 2024 17:45
Copy link
Collaborator

@AVHopp AVHopp left a comment

Choose a reason for hiding this comment

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

I'd prefer some more tests (and there is the open question regarding the CosineKernel, other than those this looks gucci.

CHANGELOG.md Outdated Show resolved Hide resolved
baybe/kernels/basic.py Outdated Show resolved Hide resolved
baybe/kernels/__init__.py Outdated Show resolved Hide resolved
baybe/kernels/basic.py Show resolved Hide resolved
baybe/kernels/basic.py Show resolved Hide resolved
tests/test_iterations.py Show resolved Hide resolved
Copy link
Collaborator

@AdrianSosic AdrianSosic left a comment

Choose a reason for hiding this comment

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

Hi @Scienfitz, thanks for the PR. Quite a few issues, but all of them small ones that can be fixed in a breeze

baybe/kernels/basic.py Outdated Show resolved Hide resolved
baybe/kernels/basic.py Outdated Show resolved Hide resolved
baybe/kernels/basic.py Outdated Show resolved Hide resolved
baybe/kernels/basic.py Outdated Show resolved Hide resolved
baybe/kernels/basic.py Outdated Show resolved Hide resolved
baybe/kernels/basic.py Outdated Show resolved Hide resolved
tests/hypothesis_strategies/kernels.py Outdated Show resolved Hide resolved
tests/hypothesis_strategies/kernels.py Outdated Show resolved Hide resolved
tests/hypothesis_strategies/kernels.py Show resolved Hide resolved
tests/hypothesis_strategies/kernels.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@AdrianSosic AdrianSosic left a comment

Choose a reason for hiding this comment

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

Two more things ...

baybe/kernels/basic.py Show resolved Hide resolved
baybe/kernels/basic.py Show resolved Hide resolved
@AdrianSosic AdrianSosic merged commit ae5bad0 into main May 21, 2024
9 of 10 checks passed
@AdrianSosic AdrianSosic deleted the feature/more_kernels branch May 21, 2024 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature New functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants