3 #ifndef CAFFE2_OPERATORS_BATCH_SPARSE_TO_DENSE_OP_H_ 4 #define CAFFE2_OPERATORS_BATCH_SPARSE_TO_DENSE_OP_H_ 6 #include "caffe2/core/context.h" 7 #include "caffe2/core/operator.h" 8 #include "caffe2/utils/math.h" 12 template <
typename T,
class Context>
15 USE_OPERATOR_CONTEXT_FUNCTIONS;
16 template <
class... Args>
19 OP_SINGLE_ARG(int64_t,
"dense_last_dim", dense_last_dim_, -1),
20 OP_SINGLE_ARG(
T,
"default_value", default_value_, static_cast<T>(0)) {}
21 bool RunOnDevice()
override;
24 int64_t dense_last_dim_;
26 INPUT_TAGS(LENGTHS, INDICES, VALUES);
29 template <
typename T,
class Context>
32 USE_OPERATOR_CONTEXT_FUNCTIONS;
33 template <
class... Args>
36 bool RunOnDevice()
override;
39 int64_t dense_last_dim_;
40 INPUT_TAGS(LENGTHS, INDICES, DENSE);
45 #endif // CAFFE2_OPERATORS_BATCH_SPARSE_TO_DENSE_OP_H_
A global dictionary that holds information about what Caffe2 modules have been loaded in the current ...