All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
cocoJsonSaver.hpp
Go to the documentation of this file.
#ifndef OPENPOSE_FILESTREAM_POSE_JSON_COCO_SAVER_HPP
#define OPENPOSE_FILESTREAM_POSE_JSON_COCO_SAVER_HPP
#include <openpose/core/common.hpp>
#include <openpose/filestream/enumClasses.hpp>
#include <openpose/filestream/jsonOfstream.hpp>
namespace op
{
class OP_API CocoJsonSaver
{
public:
explicit CocoJsonSaver(const std::string& filePathToSave, const bool humanReadable = true,
const CocoJsonFormat cocoJsonFormat = CocoJsonFormat::Body,
const int mCocoJsonVariant = 0);
virtual ~CocoJsonSaver();
void record(const Array<float>& poseKeypoints, const Array<float>& poseScores, const std::string& imageName);
private:
const CocoJsonFormat mCocoJsonFormat;
const int mCocoJsonVariant;
JsonOfstream mJsonOfstream;
bool mFirstElementAdded;
DELETE_COPY(CocoJsonSaver);
};
}
#endif // OPENPOSE_FILESTREAM_POSE_JSON_COCO_SAVER_HPP
DELETE_COPY
#define DELETE_COPY(className)
Definition: macros.hpp:34
op::CocoJsonFormat::Body
common.hpp
op::JsonOfstream
Definition: jsonOfstream.hpp:9
op::CocoJsonSaver
Definition: cocoJsonSaver.hpp:14
enumClasses.hpp
op::Array< float >
jsonOfstream.hpp
op::CocoJsonFormat
CocoJsonFormat
Definition: enumClasses.hpp:14
OP_API
#define OP_API
Definition: macros.hpp:19
cl::string
std::string string
Definition: cl2.hpp:574