25#include <VirtualRobot/Nodes/RobotNode.h>
34#include <VisionX/libraries/armem_human/aron/HumanPose.aron.generated.h>
44 const std::string RGBDPoseEstimationWithMemoryWriter::defaultName =
45 "RGBDPoseEstimationWithMemoryWriter";
53 def->required(properties.providerName,
"ImageProviderName");
55 def->optional(properties.enableMemory,
57 "Enables or disables writing to the human memory.");
58 def->optional(properties.humanMemory.memoryName,
59 "humanMemory.memory_name",
60 "Name of the human memory.");
61 def->optional(properties.humanMemory.coreSegmentName,
62 "humanMemory.core_segment_name",
63 "Name of the core segment in the human memory.");
65 humanPoseWriter.registerPropertyDefinitions(def);
74 return RGBDPoseEstimationWithMemoryWriter::defaultName;
80 return RGBDPoseEstimationWithMemoryWriter::defaultName;
86 if (properties.enableMemory)
90 std::vector<armem::human::HumanPose> humanPoses;
102 for (
const auto& keypoint3D : humanPose3D.second.keypointMap)
105 .label = keypoint3D.first,
107 static_cast<float>(
static_cast<int>(keypoint3D.second.confidence)),
110 keypoint3D.second.x, keypoint3D.second.y, keypoint3D.second.z},
113 meanZ += keypoint3D.second.z;
115 meanZ /= humanPose3D.second.keypointMap.size();
119 humanPoses.emplace_back(humanPose);
127 if (not humanPoseWriter.commitHumanPosesInCameraFrame(humanPoses,
getName(), ts))
152 if (properties.enableMemory)
Default component property definition container.
std::string getConfigIdentifier()
Retrieve config identifier for this component as set in constructor.
The FramedPosition class.
SpamFilterDataPtr deactivateSpam(float deactivationDurationSec=10.0f, const std::string &identifier="", bool deactivate=true) const
disables the logging for the current line for the given amount of seconds.
std::string getName() const
Retrieve name of object.
std::atomic_long timestamp_of_update
OpenPoseAdapter::OpenPoseSettings op_settings
std::mutex rgbImageBufferMutex
std::mutex openposeResultImageMutex
std::atomic_bool running2D
std::uint64_t sucessCounter2d
std::uint64_t readErrorCounter2d
CByteImage * rgbImageBuffer
CByteImage ** imageBuffer
std::atomic_bool result_image_ready
visionx::ImageFormatInfo rgbImageFormat
std::atomic_bool update_ready
CByteImage ** openposeResultImage
armarx::MetaInfoSizeBasePtr imageMetaInfo
std::uint64_t timeoutCounter2d
std::mutex imageBufferMutex
visionx::ImageProviderInfo imageProviderInfo
std::mutex depthImageBufferMutex
std::string cameraNodeName
VirtualRobot::RobotPtr localRobot
void preOnInitImageProcessor() override
void postCreatePropertyDefinitions(PropertyDefinitionsPtr &properties) override
CByteImage * depthImageBuffer
void postOnDisconnectImageProcessor() override
void preOnConnectImageProcessor() override
void postOnConnectImageProcessor() override
void preOnDisconnectImageProcessor() override
void reportEntities() override
HumanPose3DMap openposeResult3D
virtual void onConnectImageProcessor() override
Implement this method in the ImageProcessor in order execute parts when the component is fully initia...
virtual void onExitImageProcessor() override
Exit the ImapeProcessor component.
virtual armarx::PropertyDefinitionsPtr createPropertyDefinitions() override
virtual void process() override
Process the vision component.
virtual void onInitImageProcessor() override
Setup the vision component.
static std::string GetDefaultName()
Get the component's default name.
virtual void onDisconnectImageProcessor() override
Implement this method in the ImageProcessor in order execute parts when the component looses network ...
void reportEntities() override
std::string getDefaultName() const override
MemoryNameSystem & memoryNameSystem()
static Duration MicroSeconds(std::int64_t microSeconds)
Constructs a duration in microseconds.
void enableResultImages(int numberImages, ImageDimension imageDimension, ImageType imageType, const std::string &name="")
Enables visualization.
void usingImageProvider(std::string name)
Registers a delayed topic subscription and a delayed provider proxy retrieval which all will be avail...
bool waitForImages(int milliseconds=1000)
Wait for new images.
ImageProviderInfo getImageProvider(std::string name, ImageType destinationImageType=eRgb, bool waitForProxy=false)
Select an ImageProvider.
int getImages(CByteImage **ppImages)
Poll images from provider.
void provideResultImages(CByteImage **images, armarx::MetaInfoSizeBasePtr info=nullptr)
sends result images for visualization
#define ARMARX_INFO
The normal logging level.
#define ARMARX_IMPORTANT
The logging level for always important information, but expected behaviour (in contrast to ARMARX_WAR...
#define ARMARX_FATAL
The logging level for unexpected behaviour, that will lead to a seriously malfunctioning program and ...
#define ARMARX_ERROR
The logging level for unexpected behaviour, that must be fixed.
#define ARMARX_DEBUG
The logging level for output that is only interesting while debugging.
#define ARMARX_WARNING
The logging level for unexpected behaviour, but not a serious problem.
armarx::core::time::DateTime Time
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< class PropertyDefinitionContainer > PropertyDefinitionsPtr
PropertyDefinitions smart pointer type.
std::optional< std::string > humanTrackingId
std::string cameraFrameName