22 #ifndef __KERNEL_FUNCTION_LINEAR_H__
23 #define __KERNEL_FUNCTION_LINEAR_H__
25 #include "algorithms/algorithm.h"
26 #include "data_management/data/numeric_table.h"
27 #include "algorithms/kernel_function/kernel_function_types_linear.h"
28 #include "algorithms/kernel_function/kernel_function.h"
34 namespace kernel_function
56 template<
typename algorithmFPType, Method method, CpuType cpu>
57 class DAAL_EXPORT BatchContainer :
public daal::algorithms::AnalysisContainerIface<batch>
65 BatchContainer(daal::services::Environment::env *daalEnv);
71 virtual services::Status compute() DAAL_C11_OVERRIDE;
90 template<
typename algorithmFPType = DAAL_ALGORITHM_FP_TYPE, Method method = defaultDense>
91 class DAAL_EXPORT Batch :
public KernelIface
94 typedef KernelIface super;
96 typedef algorithms::kernel_function::linear::Input InputType;
97 typedef algorithms::kernel_function::linear::Parameter ParameterType;
98 typedef typename super::ResultType ResultType;
100 ParameterType parameter;
115 Batch(
const Batch<algorithmFPType, method> &other) : KernelIface(other), parameter(other.parameter), input(other.input)
124 virtual int getMethod() const DAAL_C11_OVERRIDE {
return(
int) method; }
130 virtual InputType * getInput() DAAL_C11_OVERRIDE {
return &input; }
136 virtual ParameterBase * getParameter() DAAL_C11_OVERRIDE {
return ¶meter; }
143 services::SharedPtr<Batch<algorithmFPType, method> > clone()
const
145 return services::SharedPtr<Batch<algorithmFPType, method> >(cloneImpl());
151 Analysis<batch>::_ac =
new __DAAL_ALGORITHM_CONTAINER(batch, BatchContainer, algorithmFPType, method)(&_env);
156 virtual Batch<algorithmFPType, method> * cloneImpl() const DAAL_C11_OVERRIDE
158 return new Batch<algorithmFPType, method>(*this);
161 virtual services::Status allocateResult() DAAL_C11_OVERRIDE
163 services::Status s = _result->allocate<algorithmFPType>(&input, ¶meter, (int) method);
164 _res = _result.get();
170 using interface1::BatchContainer;
171 using interface1::Batch;
daal::algorithms::kernel_function::linear::interface1::Batch::Batch
Batch(const Batch< algorithmFPType, method > &other)
Definition: kernel_function_linear.h:115
daal
Definition: algorithm_base_common.h:31
daal::algorithms::AnalysisContainerIface
Abstract interface class that provides virtual methods to access and run implementations of the analy...
Definition: analysis.h:53
daal::algorithms::kernel_function::linear::interface1::Batch::clone
services::SharedPtr< Batch< algorithmFPType, method > > clone() const
Definition: kernel_function_linear.h:143
daal::algorithms::kernel_function::linear::interface1::Batch::getInput
virtual InputType * getInput() DAAL_C11_OVERRIDE
Definition: kernel_function_linear.h:130
daal::algorithms::kernel_function::linear::interface1::Batch::Batch
Batch()
Definition: kernel_function_linear.h:104
daal::algorithms::kernel_function::linear::interface1::Batch::getMethod
virtual int getMethod() const DAAL_C11_OVERRIDE
Definition: kernel_function_linear.h:124
daal::algorithms::kernel_function::linear::interface1::BatchContainer
Provides methods to run implementations of the linear kernel function algorithm. This class is associ...
Definition: kernel_function_linear.h:57
daal::batch
Definition: daal_defines.h:106
daal::algorithms::kernel_function::linear::interface1::Batch::input
InputType input
Definition: kernel_function_linear.h:101
daal::algorithms::kernel_function::linear::interface1::Batch::parameter
ParameterType parameter
Definition: kernel_function_linear.h:100
daal::algorithms::Analysis
Provides methods for execution of operations over data, such as computation of Summary Statistics est...
Definition: analysis.h:68
daal::algorithms::kernel_function::linear::interface1::Batch
Computes a linear kernel function in the batch processing mode.
Definition: kernel_function_linear.h:91
daal::algorithms::kernel_function::linear::interface1::Batch::getParameter
virtual ParameterBase * getParameter() DAAL_C11_OVERRIDE
Definition: kernel_function_linear.h:136