25 #include "algorithms/algorithm.h"
26 #include "data_management/data/numeric_table.h"
27 #include "services/daal_defines.h"
28 #include "algorithms/math/relu_types.h"
49 template<
typename algorithmFPType, Method method, CpuType cpu>
50 class DAAL_EXPORT BatchContainer :
public daal::algorithms::AnalysisContainerIface<batch>
58 BatchContainer(daal::services::Environment::env *daalEnv);
66 virtual services::Status compute() DAAL_C11_OVERRIDE;
83 template<
typename algorithmFPType = DAAL_ALGORITHM_FP_TYPE, Method method = defaultDense>
84 class DAAL_EXPORT Batch :
public daal::algorithms::Analysis<batch>
87 typedef algorithms::math::relu::Input InputType;
88 typedef algorithms::math::relu::Result ResultType;
100 Batch(
const Batch<algorithmFPType, method> &other) : input(other.input)
109 virtual int getMethod() const DAAL_C11_OVERRIDE {
return(
int) method; }
115 ResultPtr getResult()
126 services::Status setResult(
const ResultPtr &result)
128 DAAL_CHECK(result, services::ErrorNullResult)
130 _res = _result.get();
131 return services::Status();
141 services::SharedPtr<Batch<algorithmFPType, method> > clone()
const
143 return services::SharedPtr<Batch<algorithmFPType, method> >(cloneImpl());
147 virtual Batch<algorithmFPType, method> *cloneImpl() const DAAL_C11_OVERRIDE
149 return new Batch<algorithmFPType, method>(*this);
152 virtual services::Status allocateResult() DAAL_C11_OVERRIDE
154 _result.reset(
new ResultType());
155 services::Status s = _result->allocate<algorithmFPType>(&input, NULL, (int) method);
156 _res = _result.get();
162 Analysis<batch>::_ac =
new __DAAL_ALGORITHM_CONTAINER(batch, BatchContainer, algorithmFPType, method)(&_env);
170 using interface1::BatchContainer;
171 using interface1::Batch;
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::math::relu::interface1::Batch::input
InputType input
Definition: relu.h:134
daal::algorithms::math::relu::interface1::Batch::getResult
ResultPtr getResult()
Definition: relu.h:115
daal::algorithms::math::relu::interface1::Batch::getMethod
virtual int getMethod() const DAAL_C11_OVERRIDE
Definition: relu.h:109
daal::algorithms::math::relu::interface1::Batch::Batch
Batch(const Batch< algorithmFPType, method > &other)
Definition: relu.h:100
daal::algorithms::math::relu::interface1::BatchContainer
Class containing methods for the rectified linear function computing using algorithmFPType precision ...
Definition: relu.h:50
daal::batch
Definition: daal_defines.h:110
daal::algorithms::math::relu::interface1::Batch::setResult
services::Status setResult(const ResultPtr &result)
Definition: relu.h:126
daal::algorithms::math::relu::interface1::Batch::Batch
Batch()
Definition: relu.h:91
daal::algorithms::Analysis
Provides methods for execution of operations over data, such as computation of Summary Statistics est...
Definition: analysis.h:68
daal::algorithms::math::relu::interface1::Batch
Computes the rectified linear function in the batch processing mode.
Definition: relu.h:84
daal::algorithms::math::relu::interface1::Batch::clone
services::SharedPtr< Batch< algorithmFPType, method > > clone() const
Definition: relu.h:141
daal::services::ErrorNullResult
Definition: error_indexes.h:96