1 #ifndef OPENPOSE_POSE_W_POSE_EXTRACTOR_HPP
2 #define OPENPOSE_POSE_W_POSE_EXTRACTOR_HPP
10 template<
typename TDatums>
14 explicit WPoseExtractor(
const std::shared_ptr<PoseExtractor>& poseExtractorSharedPtr);
18 void work(TDatums& tDatums);
21 std::shared_ptr<PoseExtractor> spPoseExtractor;
35 template<
typename TDatums>
37 spPoseExtractor{poseExtractorSharedPtr}
41 template<
typename TDatums>
44 spPoseExtractor->initializationOnThread();
47 template<
typename TDatums>
59 for (
auto& tDatum : *tDatums)
61 spPoseExtractor->forwardPass(tDatum.inputNetData,
Point<int>{tDatum.cvInputData.cols, tDatum.cvInputData.rows}, tDatum.scaleRatios);
62 tDatum.poseHeatMaps = spPoseExtractor->getHeatMaps().clone();
63 tDatum.poseKeypoints = spPoseExtractor->getPoseKeypoints().clone();
64 tDatum.scaleNetToOutput = spPoseExtractor->getScaleNetToOutput();
73 catch (
const std::exception& e)
77 error(e.what(), __LINE__, __FUNCTION__, __FILE__);
84 #endif // OPENPOSE_POSE_W_POSE_EXTRACTOR_HPP
static const unsigned long long DEFAULT_X
Definition: profiler.hpp:24
static const std::string timerInit(const int line, const std::string &function, const std::string &file)
OP_API void error(const std::string &message, const int line=-1, const std::string &function="", const std::string &file="")
void dLog(const T &message, const Priority priority=Priority::Max, const int line=-1, const std::string &function="", const std::string &file="")
Definition: errorAndLog.hpp:47
bool checkNoNullNorEmpty(const TPointerContainer &tPointerContainer)
Definition: pointerContainer.hpp:7
#define COMPILE_TEMPLATE_DATUM(templateName)
Definition: macros.hpp:21
static void printAveragedTimeMsOnIterationX(const std::string &key, const int line, const std::string &function, const std::string &file, const unsigned long long x=DEFAULT_X)
static void timerEnd(const std::string &key)