Remove the no-offset kernel; it is not useful and was a hack for a deadline.
This commit is contained in:
@@ -68,33 +68,6 @@ class PolynomialKernel
|
||||
double degree;
|
||||
};
|
||||
|
||||
// For an integer degree known at compile time. No offset.
|
||||
template<int degree>
|
||||
class PolynomialNoOffsetKernel
|
||||
{
|
||||
public:
|
||||
PolynomialNoOffsetKernel();
|
||||
|
||||
template<typename VecType>
|
||||
static double Evaluate(const VecType& a, const VecType& b)
|
||||
{
|
||||
return pow((arma::dot(a, b)), degree);
|
||||
}
|
||||
};
|
||||
|
||||
template<int denominator>
|
||||
class PolynomialFractionKernel
|
||||
{
|
||||
public:
|
||||
PolynomialFractionKernel();
|
||||
|
||||
template<typename VecType>
|
||||
static double Evaluate(const VecType& a, const VecType& b)
|
||||
{
|
||||
return pow((arma::dot(a, b)), 1.0 / (double) denominator);
|
||||
}
|
||||
};
|
||||
|
||||
}; // namespace kernel
|
||||
}; // namespace mlpack
|
||||
|
||||
|
||||
Reference in New Issue
Block a user