OpenPose  1.0.0rc2
OpenPose: A Real-Time Multi-Person Key-Point Detection And Multi-Threading C++ Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
cocoJsonSaver.hpp
Go to the documentation of this file.
1 #ifndef OPENPOSE_FILESTREAM_POSE_JSON_COCO_SAVER_HPP
2 #define OPENPOSE_FILESTREAM_POSE_JSON_COCO_SAVER_HPP
3 
8 
9 namespace op
10 {
16  {
17  public:
24  explicit CocoJsonSaver(
25  const std::string& filePathToSave, const PoseModel poseModel, const bool humanReadable = true,
26  const CocoJsonFormat cocoJsonFormat = CocoJsonFormat::Body, const int mCocoJsonVariant = 0);
27 
28  virtual ~CocoJsonSaver();
29 
30  void record(const Array<float>& poseKeypoints, const Array<float>& poseScores, const std::string& imageName);
31 
32  private:
33  const PoseModel mPoseModel;
34  const CocoJsonFormat mCocoJsonFormat;
35  const int mCocoJsonVariant;
36  JsonOfstream mJsonOfstream;
37  bool mFirstElementAdded;
38 
40  };
41 }
42 
43 #endif // OPENPOSE_FILESTREAM_POSE_JSON_COCO_SAVER_HPP
#define DELETE_COPY(className)
Definition: macros.hpp:34
PoseModel
Definition: enumClasses.hpp:9
Definition: jsonOfstream.hpp:9
Definition: cocoJsonSaver.hpp:15
CocoJsonFormat
Definition: enumClasses.hpp:14
#define OP_API
Definition: macros.hpp:19
std::string string
Definition: cl2.hpp:574