Skip to content

Extend lengthscale tip #476

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

Merged
merged 5 commits into from
Sep 26, 2022
Merged

Extend lengthscale tip #476

merged 5 commits into from
Sep 26, 2022

Conversation

willtebbutt
Copy link
Member

Summary

It was unclear to a Stheno.jl user how to do ARD stuff -- see this issue. This PR extends our lengthscale tip to multiple dimensions.

Proposed changes

Extend lengthscale tip to cover ARD and factor analysis cases.

What alternatives have you considered?

I considered adding something in Stheno, but I didn't want to dilute the docs.
I also considered not adding the factor analyis example, since it is so closely-related to the ARD example, it felt important to include.

Breaking changes

None

Comment on lines 24 to 29
Per-dimension lengthscales for automatic relevance determination work in a similar manner:
```julia
inverse_length_scales = [1.0, 2.0]
k = SqExponentialKernel() ∘ ARDTransform(inverse_length_scales)
k = compose(SqExponentialKernel(), ARDTransform(inverse_length_scales))
```
Copy link
Member

Choose a reason for hiding this comment

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

I thought commonly one would just use with_lengthscale? ARD is actually mentioned two lines above 🙂

Copy link
Member Author

Choose a reason for hiding this comment

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

Huh. I hadn't realised that is a thing! Maybe I should just add an example with a vector of lengthscales to the tip then, rather than extending substantially? And maybe change the title to "How do I set the lengthscale(s)?"?

Copy link
Member

Choose a reason for hiding this comment

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

I think these are good suggestions.

Copy link
Member Author

Choose a reason for hiding this comment

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

Have tweaked -- let me know if you think it works.

@codecov
Copy link

codecov bot commented Sep 26, 2022

Codecov Report

Base: 40.97% // Head: 47.94% // Increases project coverage by +6.97% 🎉

Coverage data is based on head (39e625a) compared to base (e42d89d).
Patch has no changes to coverable lines.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #476      +/-   ##
==========================================
+ Coverage   40.97%   47.94%   +6.97%     
==========================================
  Files          52       52              
  Lines        1340     1341       +1     
==========================================
+ Hits          549      643      +94     
+ Misses        791      698      -93     
Impacted Files Coverage Δ
src/mokernels/lmm.jl 0.00% <0.00%> (-100.00%) ⬇️
src/mokernels/slfm.jl 0.00% <0.00%> (-100.00%) ⬇️
src/distances/delta.jl 0.00% <0.00%> (-100.00%) ⬇️
src/mokernels/moinput.jl 0.00% <0.00%> (-100.00%) ⬇️
src/mokernels/mokernel.jl 0.00% <0.00%> (-100.00%) ⬇️
src/mokernels/independent.jl 0.00% <0.00%> (-100.00%) ⬇️
src/matrix/kernelkroneckermat.jl 0.00% <0.00%> (-100.00%) ⬇️
src/mokernels/intrinsiccoregion.jl 0.00% <0.00%> (-100.00%) ⬇️
src/approximations/nystrom.jl 0.00% <0.00%> (-92.69%) ⬇️
src/matrix/kernelpdmat.jl 0.00% <0.00%> (-75.00%) ⬇️
... and 32 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@willtebbutt willtebbutt merged commit ba7b37c into master Sep 26, 2022
@willtebbutt willtebbutt deleted the wct/docs-improvement branch September 26, 2022 13:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants