Skip to content

Commit ff49855

Browse files
authored
Merge branch 'master' into st/test_Matern_AD
2 parents 27f9ba4 + 873aa8d commit ff49855

File tree

4 files changed

+26
-26
lines changed

4 files changed

+26
-26
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "KernelFunctions"
22
uuid = "ec8451be-7e33-11e9-00cf-bbf324bd1392"
3-
version = "0.10.35"
3+
version = "0.10.36"
44

55
[deps]
66
ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@
99
[![DOI](https://zenodo.org/badge/188430419.svg)](https://zenodo.org/badge/latestdoi/188430419)
1010

1111

12-
1312
## Kernel functions for machine learning
1413

15-
KernelFunctions.jl provides a flexible framework for defining kernel functions, and an extensive collection of implementations.
16-
17-
The aim is to make the API as model-agnostic as possible while still being user-friendly, and to interoperate well with generic packages for handling parameters like [ParameterHandling.jl](https://github.com/invenia/ParameterHandling.jl/) and FluxML's [Functors.jl](https://github.com/FluxML/Functors.jl/).
18-
19-
Where appropriate, kernels are AD-compatible.
14+
**KernelFunctions.jl** is a general purpose [kernel](https://en.wikipedia.org/wiki/Positive-definite_kernel) package.
15+
It provides a flexible framework for creating kernel functions and manipulating them, and an extensive collection of implementations.
16+
The main goals of this package are:
17+
- **Flexibility**: operations between kernels should be fluid and easy without breaking, with a user-friendly API.
18+
- **Plug-and-play**: being model-agnostic; including the kernels before/after other steps should be straightforward. To interoperate well with generic packages for handling parameters like [ParameterHandling.jl](https://github.com/invenia/ParameterHandling.jl/) and FluxML's [Functors.jl](https://github.com/FluxML/Functors.jl/).
19+
- **Automatic Differentiation compatibility**: all kernel functions which _ought_ to be differentiable using AD packages like [ForwardDiff.jl](https://github.com/JuliaDiff/ForwardDiff.jl) or [Zygote.jl](https://github.com/FluxML/Zygote.jl) _should_ be.
2020

2121
## Examples
2222

@@ -50,9 +50,9 @@ plot(
5050

5151
## Related Work
5252

53-
Directly inspired by the [MLKernels](https://github.com/trthatcher/MLKernels.jl) package.
53+
This package replaces the now-defunct [MLKernels.jl](https://github.com/trthatcher/MLKernels.jl). It incorporates lots of excellent existing work from packages such as [GaussianProcesses.jl](https://github.com/STOR-i/GaussianProcesses.jl), and is used in downstream packages such as [AbstractGPs.jl](https://github.com/JuliaGaussianProcesses/AbstractGPs.jl), [ApproximateGPs.jl](https://github.com/JuliaGaussianProcesses/ApproximateGPs.jl), [Stheno.jl](https://github.com/willtebbutt/Stheno.jl), and [AugmentedGaussianProcesses.jl](https://github.com/theogf/AugmentedGaussianProcesses.jl).
5454

55-
See the JuliaGaussianProcesses [Github organisation](https://github.com/JuliaGaussianProcesses) and [website](https://juliagaussianprocesses.github.io/) for more related packages.
55+
See the JuliaGaussianProcesses [Github organisation](https://github.com/JuliaGaussianProcesses) and [website](https://juliagaussianprocesses.github.io/) for more information.
5656

5757
## Issues/Contributing
5858

docs/src/index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# KernelFunctions.jl
22

33
**KernelFunctions.jl** is a general purpose [kernel](https://en.wikipedia.org/wiki/Positive-definite_kernel) package.
4-
It aims at providing a flexible framework for creating kernels and manipulating them.
4+
It provides a flexible framework for creating kernel functions and manipulating them, and an extensive collection of implementations.
55
The main goals of this package are:
6-
- **Flexibility**: operations between kernels should be fluid and easy without breaking.
7-
- **Plug-and-play**: including the kernels before/after other steps should be straightforward.
6+
- **Flexibility**: operations between kernels should be fluid and easy without breaking, with a user-friendly API.
7+
- **Plug-and-play**: being model-agnostic; including the kernels before/after other steps should be straightforward. To interoperate well with generic packages for handling parameters like [ParameterHandling.jl](https://github.com/invenia/ParameterHandling.jl/) and FluxML's [Functors.jl](https://github.com/FluxML/Functors.jl/).
88
- **Automatic Differentiation compatibility**: all kernel functions which _ought_ to be differentiable using AD packages like [ForwardDiff.jl](https://github.com/JuliaDiff/ForwardDiff.jl) or [Zygote.jl](https://github.com/FluxML/Zygote.jl) _should_ be.
99

1010
This package replaces the now-defunct [MLKernels.jl](https://github.com/trthatcher/MLKernels.jl). It incorporates lots of excellent existing work from packages such as [GaussianProcesses.jl](https://github.com/STOR-i/GaussianProcesses.jl), and is used in downstream packages such as [AbstractGPs.jl](https://github.com/JuliaGaussianProcesses/AbstractGPs.jl), [ApproximateGPs.jl](https://github.com/JuliaGaussianProcesses/ApproximateGPs.jl), [Stheno.jl](https://github.com/willtebbutt/Stheno.jl), and [AugmentedGaussianProcesses.jl](https://github.com/theogf/AugmentedGaussianProcesses.jl).

src/test_utils.jl

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -94,18 +94,18 @@ function test_interface(
9494
rng::AbstractRNG, k::Kernel, ::Type{Vector{T}}; kwargs...
9595
) where {T<:Real}
9696
return test_interface(
97-
k, randn(rng, T, 1001), randn(rng, T, 1001), randn(rng, T, 1000); kwargs...
97+
k, randn(rng, T, 11), randn(rng, T, 11), randn(rng, T, 13); kwargs...
9898
)
9999
end
100100

101101
function test_interface(
102-
rng::AbstractRNG, k::MOKernel, ::Type{Vector{Tuple{T,Int}}}; dim_out=1, kwargs...
102+
rng::AbstractRNG, k::MOKernel, ::Type{Vector{Tuple{T,Int}}}; dim_out=3, kwargs...
103103
) where {T<:Real}
104104
return test_interface(
105105
k,
106-
[(randn(rng, T), rand(rng, 1:dim_out)) for i in 1:51],
107-
[(randn(rng, T), rand(rng, 1:dim_out)) for i in 1:51],
108-
[(randn(rng, T), rand(rng, 1:dim_out)) for i in 1:50];
106+
[(randn(rng, T), rand(rng, 1:dim_out)) for i in 1:11],
107+
[(randn(rng, T), rand(rng, 1:dim_out)) for i in 1:11],
108+
[(randn(rng, T), rand(rng, 1:dim_out)) for i in 1:13];
109109
kwargs...,
110110
)
111111
end
@@ -115,9 +115,9 @@ function test_interface(
115115
) where {T<:Real}
116116
return test_interface(
117117
k,
118-
ColVecs(randn(rng, T, dim_in, 1001)),
119-
ColVecs(randn(rng, T, dim_in, 1001)),
120-
ColVecs(randn(rng, T, dim_in, 1000));
118+
ColVecs(randn(rng, T, dim_in, 11)),
119+
ColVecs(randn(rng, T, dim_in, 11)),
120+
ColVecs(randn(rng, T, dim_in, 13));
121121
kwargs...,
122122
)
123123
end
@@ -127,9 +127,9 @@ function test_interface(
127127
) where {T<:Real}
128128
return test_interface(
129129
k,
130-
RowVecs(randn(rng, T, 1001, dim_in)),
131-
RowVecs(randn(rng, T, 1001, dim_in)),
132-
RowVecs(randn(rng, T, 1000, dim_in));
130+
RowVecs(randn(rng, T, 11, dim_in)),
131+
RowVecs(randn(rng, T, 11, dim_in)),
132+
RowVecs(randn(rng, T, 13, dim_in));
133133
kwargs...,
134134
)
135135
end
@@ -139,9 +139,9 @@ function test_interface(
139139
) where {T<:Real}
140140
return test_interface(
141141
k,
142-
[randn(rng, T, dim_in) for _ in 1:1001],
143-
[randn(rng, T, dim_in) for _ in 1:1001],
144-
[randn(rng, T, dim_in) for _ in 1:1000];
142+
[randn(rng, T, dim_in) for _ in 1:11],
143+
[randn(rng, T, dim_in) for _ in 1:11],
144+
[randn(rng, T, dim_in) for _ in 1:13];
145145
kwargs...,
146146
)
147147
end

0 commit comments

Comments
 (0)