18 #ifndef CAFFE2_FB_OPERATORS_UTILITY_OPS_H_ 19 #define CAFFE2_FB_OPERATORS_UTILITY_OPS_H_ 21 #include "caffe2/core/context.h" 22 #include "caffe2/core/operator.h" 30 template <
typename TIN,
typename TOUT,
class Context>
33 USE_OPERATOR_CONTEXT_FUNCTIONS;
35 template <
class... Args>
38 threshold_(this->
template GetSingleArgument<TIN>(
"threshold", 0)),
39 low_value_(this->
template GetSingleArgument<TOUT>(
"low_value", 0)),
40 high_value_(this->
template GetSingleArgument<TOUT>(
"high_value", 0)) {}
42 bool RunOnDevice()
override;
52 template <
typename TIN,
typename TOUT,
class Context>
55 USE_OPERATOR_CONTEXT_FUNCTIONS;
57 template <
class... Args>
60 threshold_(this->
template GetSingleArgument<TIN>(
"threshold", 0)) {}
62 bool RunOnDevice()
override;
71 #endif // CAFFE2_FB_OPERATORS_UTILITY_OPS_H_
A global dictionary that holds information about what Caffe2 modules have been loaded in the current ...