OpenPose  1.7.0
The first real-time multi-person system to jointly detect human body, hand, facial, and foot keypoints
handExtractorCaffe.hpp
Go to the documentation of this file.
1 #ifndef OPENPOSE_HAND_HAND_EXTRACTOR_CAFFE_HPP
2 #define OPENPOSE_HAND_HAND_EXTRACTOR_CAFFE_HPP
3 
7 
8 namespace op
9 {
14  {
15  public:
26  HandExtractorCaffe(const Point<int>& netInputSize, const Point<int>& netOutputSize,
27  const std::string& modelFolder, const int gpuId,
28  const int numberScales = 1, const float rangeScales = 0.4f,
29  const std::vector<HeatMapType>& heatMapTypes = {},
30  const ScaleMode heatMapScaleMode = ScaleMode::ZeroToOneFixedAspect,
31  const bool enableGoogleLogging = true);
32 
38 
44 
54  void forwardPass(const std::vector<std::array<Rectangle<float>, 2>> handRectangles, const Matrix& inputData);
55 
56  private:
57  // PIMPL idiom
58  // http://www.cppsamples.com/common-tasks/pimpl.html
59  struct ImplHandExtractorCaffe;
60  std::unique_ptr<ImplHandExtractorCaffe> upImpl;
61 
62  Array<float> getHeatMapsFromLastPass() const;
63 
64  // PIMP requires DELETE_COPY & destructor, or extra code
65  // http://oliora.github.io/2015/12/29/pimpl-and-rule-of-zero.html
67  };
68 }
69 
70 #endif // OPENPOSE_HAND_HAND_EXTRACTOR_CAFFE_HPP
void forwardPass(const std::vector< std::array< Rectangle< float >, 2 >> handRectangles, const Matrix &inputData)
HandExtractorCaffe(const Point< int > &netInputSize, const Point< int > &netOutputSize, const std::string &modelFolder, const int gpuId, const int numberScales=1, const float rangeScales=0.4f, const std::vector< HeatMapType > &heatMapTypes={}, const ScaleMode heatMapScaleMode=ScaleMode::ZeroToOneFixedAspect, const bool enableGoogleLogging=true)
virtual ~HandExtractorCaffe()
#define OP_API
Definition: macros.hpp:18
#define DELETE_COPY(className)
Definition: macros.hpp:32
ScaleMode
Definition: enumClasses.hpp:7