Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Matthias Mayr
limbo
Commits
aedc90e1
Commit
aedc90e1
authored
Jul 22, 2016
by
Konstantinos Chatzilygeroudis
Browse files
Fix typos in kernels
parent
614026e7
Changes
10
Hide whitespace changes
Inline
Side-by-side
src/examples/experimental/parego.cpp
View file @
aedc90e1
...
...
@@ -17,7 +17,7 @@ struct Params {
};
#endif
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.2
);
};
...
...
src/examples/mono_dim.cpp
View file @
aedc90e1
#include
<limbo/tools/macros.hpp>
#include
<limbo/kernel/matern_five_hal
f
s.hpp>
#include
<limbo/kernel/matern_five_hal
ve
s.hpp>
#include
<limbo/mean/data.hpp>
#include
<limbo/model/gp.hpp>
#include
<limbo/acqui/gp_ucb.hpp>
...
...
@@ -27,7 +27,7 @@ BO_PARAMS(std::cout,
BO_PARAM
(
double
,
alpha
,
0.1
);
};
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.2
);
};
...
...
src/examples/obs_multi.cpp
View file @
aedc90e1
#include
<limbo/tools/macros.hpp>
#include
<limbo/kernel/matern_five_hal
f
s.hpp>
#include
<limbo/kernel/matern_five_hal
ve
s.hpp>
#include
<limbo/mean/data.hpp>
#include
<limbo/model/gp.hpp>
#include
<limbo/acqui/gp_ucb.hpp>
...
...
@@ -21,7 +21,7 @@ struct Params {
struct
opt_gridsearch
:
public
defaults
::
opt_gridsearch
{
};
#endif
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.2
);
};
...
...
src/examples/obs_multi_auto_mean.cpp
View file @
aedc90e1
...
...
@@ -24,7 +24,7 @@ struct Params {
struct
kernel_squared_exp_ard
:
public
defaults
::
kernel_squared_exp_ard
{
};
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.2
);
};
...
...
src/limbo/kernel.hpp
View file @
aedc90e1
...
...
@@ -5,8 +5,8 @@
///@defgroup kernel_defaults
#include
<limbo/kernel/exp.hpp>
#include
<limbo/kernel/matern_five_hal
f
s.hpp>
#include
<limbo/kernel/matern_three_hal
f
s.hpp>
#include
<limbo/kernel/matern_five_hal
ve
s.hpp>
#include
<limbo/kernel/matern_three_hal
ve
s.hpp>
#include
<limbo/kernel/squared_exp_ard.hpp>
#endif
src/limbo/kernel/matern_five_hal
f
s.hpp
→
src/limbo/kernel/matern_five_hal
ve
s.hpp
View file @
aedc90e1
#ifndef LIMBO_KERNEL_MATERN_FIVE_HAL
F
S_HPP
#define LIMBO_KERNEL_MATERN_FIVE_HAL
F
S_HPP
#ifndef LIMBO_KERNEL_MATERN_FIVE_HAL
VE
S_HPP
#define LIMBO_KERNEL_MATERN_FIVE_HAL
VE
S_HPP
#include
<Eigen/Core>
...
...
@@ -7,7 +7,7 @@
namespace
limbo
{
namespace
defaults
{
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
/// @ingroup kernel_defaults
BO_PARAM
(
double
,
sigma_sq
,
1
);
/// @ingroup kernel_defaults
...
...
@@ -44,7 +44,7 @@ namespace limbo {
double
operator
()(
const
Eigen
::
VectorXd
&
v1
,
const
Eigen
::
VectorXd
&
v2
)
const
{
double
d
=
(
v1
-
v2
).
norm
();
return
Params
::
kernel_maternfivehal
f
s
::
sigma_sq
()
*
(
1
+
std
::
sqrt
(
5
)
*
d
/
Params
::
kernel_maternfivehal
f
s
::
l
()
+
5
*
d
*
d
/
(
3
*
Params
::
kernel_maternfivehal
f
s
::
l
()
*
Params
::
kernel_maternfivehal
f
s
::
l
()))
*
std
::
exp
(
-
std
::
sqrt
(
5
)
*
d
/
Params
::
kernel_maternfivehal
f
s
::
l
());
return
Params
::
kernel_maternfivehal
ve
s
::
sigma_sq
()
*
(
1
+
std
::
sqrt
(
5
)
*
d
/
Params
::
kernel_maternfivehal
ve
s
::
l
()
+
5
*
d
*
d
/
(
3
*
Params
::
kernel_maternfivehal
ve
s
::
l
()
*
Params
::
kernel_maternfivehal
ve
s
::
l
()))
*
std
::
exp
(
-
std
::
sqrt
(
5
)
*
d
/
Params
::
kernel_maternfivehal
ve
s
::
l
());
}
};
}
...
...
src/limbo/kernel/matern_three_hal
f
s.hpp
→
src/limbo/kernel/matern_three_hal
ve
s.hpp
View file @
aedc90e1
#ifndef LIMBO_KERNEL_MATERN_THREE_HAL
F
S_HPP
#define LIMBO_KERNEL_MATERN_THREE_HAL
F
S_HPP
#ifndef LIMBO_KERNEL_MATERN_THREE_HAL
VE
S_HPP
#define LIMBO_KERNEL_MATERN_THREE_HAL
VE
S_HPP
#include
<Eigen/Core>
...
...
@@ -7,7 +7,7 @@
namespace
limbo
{
namespace
defaults
{
struct
kernel_maternthreehal
f
s
{
struct
kernel_maternthreehal
ve
s
{
/// @ingroup kernel_defaults
/// This is is sigma squared!
BO_PARAM
(
double
,
sigma_sq
,
1
);
...
...
@@ -43,7 +43,7 @@ namespace limbo {
double
operator
()(
const
Eigen
::
VectorXd
&
v1
,
const
Eigen
::
VectorXd
&
v2
)
const
{
double
d
=
(
v1
-
v2
).
norm
();
return
Params
::
kernel_maternthreehal
f
s
::
sigma_sq
()
*
(
1
+
std
::
sqrt
(
3
)
*
d
/
Params
::
kernel_maternthreehal
f
s
::
l
())
*
std
::
exp
(
-
std
::
sqrt
(
3
)
*
d
/
Params
::
kernel_maternthreehal
f
s
::
l
());
return
Params
::
kernel_maternthreehal
ve
s
::
sigma_sq
()
*
(
1
+
std
::
sqrt
(
3
)
*
d
/
Params
::
kernel_maternthreehal
ve
s
::
l
())
*
std
::
exp
(
-
std
::
sqrt
(
3
)
*
d
/
Params
::
kernel_maternthreehal
ve
s
::
l
());
}
};
}
...
...
src/tests/all_combinations_template.cpp
View file @
aedc90e1
...
...
@@ -13,12 +13,12 @@ struct Params {
BO_PARAM
(
double
,
l
,
1
);
};
struct
kernel_maternthreehal
f
s
{
struct
kernel_maternthreehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.2
);
};
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.2
);
};
...
...
src/tests/test_gp.cpp
View file @
aedc90e1
...
...
@@ -4,8 +4,8 @@
#include
<boost/test/unit_test.hpp>
#include
<limbo/acqui/ucb.hpp>
#include
<limbo/kernel/matern_five_hal
f
s.hpp>
#include
<limbo/kernel/matern_three_hal
f
s.hpp>
#include
<limbo/kernel/matern_five_hal
ve
s.hpp>
#include
<limbo/kernel/matern_three_hal
ve
s.hpp>
#include
<limbo/kernel/exp.hpp>
#include
<limbo/kernel/squared_exp_ard.hpp>
#include
<limbo/mean/constant.hpp>
...
...
@@ -32,7 +32,7 @@ struct Params {
struct
kernel_squared_exp_ard
:
public
defaults
::
kernel_squared_exp_ard
{
};
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
1
);
BO_PARAM
(
double
,
l
,
0.25
);
};
...
...
@@ -290,11 +290,11 @@ BOOST_AUTO_TEST_CASE(test_gp_init_variance)
BO_PARAM
(
double
,
sigma_sq
,
10
);
BO_PARAM
(
double
,
l
,
1
);
};
struct
kernel_maternthreehal
f
s
{
struct
kernel_maternthreehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
10
);
BO_PARAM
(
double
,
l
,
0.25
);
};
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma_sq
,
10
);
BO_PARAM
(
double
,
l
,
0.25
);
};
...
...
src/tests/test_init_functions.cpp
View file @
aedc90e1
...
...
@@ -26,7 +26,7 @@ struct Params {
struct
kernel_exp
:
public
defaults
::
kernel_exp
{
};
struct
kernel_maternfivehal
f
s
{
struct
kernel_maternfivehal
ve
s
{
BO_PARAM
(
double
,
sigma
,
1
);
BO_PARAM
(
double
,
l
,
0.25
);
};
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment