Caffe2 - C++ API
A deep learning, cross platform ML framework
lengths_tile_op.h
1 #ifndef CAFFE2_OPERATORS_LENGTHS_TILE_OP_H_
2 #define CAFFE2_OPERATORS_LENGTHS_TILE_OP_H_
3 
4 #include "caffe2/core/operator.h"
5 #include "caffe2/utils/math.h"
6 
7 namespace caffe2 {
8 
9 template <class Context>
10 class LengthsTileOp : public Operator<Context> {
11  public:
12  USE_OPERATOR_CONTEXT_FUNCTIONS;
13  USE_SIMPLE_CTOR_DTOR(LengthsTileOp);
14 
15  bool RunOnDevice() override {
16  return true;
17  }
18 
19  INPUT_TAGS(DATA, LENGTHS);
20 
21  private:
22  Tensor lengths_host_{CPU};
23  Tensor rowMappingHost_;
24  Tensor rowMappingDevice_;
25 };
26 
27 } // namespace caffe2
28 
29 #endif // CAFFE2_OPERATORS_LENGTHS_TILE_OP_H_
A global dictionary that holds information about what Caffe2 modules have been loaded in the current ...
Definition: blob.h:13