Skip to content

Commit b11149f

Browse files
committed
Add tests
1 parent a60a494 commit b11149f

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

test/trainable.jl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,22 @@
3636
kr = RationalQuadraticKernel=α)
3737
test_params(kr, ([α],))
3838

39+
A = rand(3, 3)
40+
km = PiecewisePolynomialKernel(v=1, maha=A)
41+
test_params(km, (A,))
42+
43+
km = MahalanobisKernel(A)
44+
test_params(km, (A,))
45+
3946
k = km + kc
4047
test_params(k, (km, kc))
4148

4249
k = km * kc
4350
test_params(k, (km, kc))
4451

52+
k = TensorProduct(km, kc)
53+
test_params(k, (km, kc))
54+
4555
s = 2.0
4656
k = transform(km, s)
4757
test_params(k, (km, [s]))

0 commit comments

Comments
 (0)