OpenPose 1.0.0rc2 OpenPose: A Real-Time Multi-Person Key-Point Detection And Multi-Threading C++ Library

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
poseExtractorCaffe.hpp
Go to the documentation of this file.
1 #ifndef OPENPOSE_POSE_POSE_EXTRACTOR_CAFFE_HPP
2 #define OPENPOSE_POSE_POSE_EXTRACTOR_CAFFE_HPP
3
4 #include <openpose/core/common.hpp>
5 #include <openpose/pose/enumClasses.hpp>
6 #include <openpose/pose/poseExtractorNet.hpp>
7
8 namespace op
9 {
10 class OP_API PoseExtractorCaffe : public PoseExtractorNet
11 {
12 public:
13 PoseExtractorCaffe(const PoseModel poseModel, const std::string& modelFolder, const int gpuId,
14 const std::vector<HeatMapType>& heatMapTypes = {},
15 const ScaleMode heatMapScale = ScaleMode::ZeroToOne,
16 const bool addPartCandidates = false,
17 const bool maximizePositives = false,
18 const bool enableGoogleLogging = true);
19
20 virtual ~PoseExtractorCaffe();
21
22 void netInitializationOnThread();
23
24 void forwardPass(const std::vector<Array<float>>& inputNetData, const Point<int>& inputDataSize,
25 const std::vector<double>& scaleInputToNetInputs = {1.f});
26
27 const float* getCandidatesCpuConstPtr() const;
28
29 const float* getCandidatesGpuConstPtr() const;
30
31 const float* getHeatMapCpuConstPtr() const;
32
33 const float* getHeatMapGpuConstPtr() const;
34
35 std::vector<int> getHeatMapSize() const;
36
37 const float* getPoseGpuConstPtr() const;
38
39 private:
40 // PIMPL idiom
41 // http://www.cppsamples.com/common-tasks/pimpl.html
42 struct ImplPoseExtractorCaffe;
43 std::unique_ptr<ImplPoseExtractorCaffe> upImpl;
44
45 // PIMP requires DELETE_COPY & destructor, or extra code
46 // http://oliora.github.io/2015/12/29/pimpl-and-rule-of-zero.html
47 DELETE_COPY(PoseExtractorCaffe);
48 };
49 }
50
51 #endif // OPENPOSE_POSE_POSE_EXTRACTOR_CAFFE_HPP
DELETE_COPY
#define DELETE_COPY(className)
Definition: macros.hpp:34
enumClasses.hpp
op::PoseModel
PoseModel
Definition: enumClasses.hpp:9
poseExtractorNet.hpp
op::Point< int >
common.hpp
op::ScaleMode::ZeroToOne
op::PoseExtractorCaffe
Definition: poseExtractorCaffe.hpp:10
op::ScaleMode
ScaleMode
Definition: enumClasses.hpp:6
op::Array< float >
cl::vector
std::vector< T, Alloc > vector
Definition: cl2.hpp:567
OP_API
#define OP_API
Definition: macros.hpp:19
op::PoseExtractorNet
Definition: poseExtractorNet.hpp:11
cl::string
std::string string
Definition: cl2.hpp:574