aron_conversions.cpp
Go to the documentation of this file.
1#include "aron_conversions.h"
2
3#include <Eigen/Geometry>
4
7#include <ArmarXCore/interface/core/PackagePath.h>
8
14
16
18{
19
20}
21
23{
24
25 template <class DTOType, class BOType>
26 static void
27 fromAronOptional(const std::optional<DTOType>& dtoOpt, std::optional<BOType>& boOpt)
28 {
29 if (dtoOpt.has_value())
30 {
31 BOType bo;
32 fromAron(dtoOpt.value(), bo);
33 boOpt = bo;
34 }
35 else
36 {
37 boOpt = std::nullopt;
38 }
39 }
40
41 template <class DTOType, class BOType>
42 static void
43 toAronOptional(std::optional<DTOType>& dtoOpt, const std::optional<BOType>& boOpt)
44 {
45 if (boOpt.has_value())
46 {
47 DTOType dto;
48 toAron(dto, boOpt.value());
49 dtoOpt = dto;
50 }
51 else
52 {
53 dtoOpt = std::nullopt;
54 }
55 }
56
57 void
58 fromAron(const armarx::human::arondto::HumanPose& dto, HumanPose& bo)
59 {
61
62 fromAron(dto.poseModelId, bo.poseModelId);
63 bo.humanTrackingId = dto.humanTrackingId;
64 bo.cameraFrameName = dto.cameraFrameName;
65 fromAron(dto.keypoints, bo.keypoints);
66 }
67
68 void
69 toAron(armarx::human::arondto::HumanPose& dto, const HumanPose& bo)
70 {
72
73 toAron(dto.poseModelId, bo.poseModelId);
74 dto.humanTrackingId = bo.humanTrackingId;
75 dto.cameraFrameName = bo.cameraFrameName;
76 toAron(dto.keypoints, bo.keypoints);
77 }
78
79 void
80 fromAron(const std::map<std::string, armarx::human::arondto::PoseKeypoint>& dto,
81 std::map<std::string, armarx::armem::human::PoseKeypoint>& bo)
82 {
83 bo.clear();
84 for (const auto& [keypoint_name, keypoint] : dto)
85 {
87 keypoint_bo.label = keypoint_name;
88 fromAron(keypoint, keypoint_bo);
89 bo[keypoint_name] = keypoint_bo;
90 }
91 }
92
93 void
94 toAron(std::map<std::string, armarx::human::arondto::PoseKeypoint>& dto,
95 const std::map<std::string, armarx::armem::human::PoseKeypoint>& bo)
96 {
97 dto.clear();
98 for (const auto& [keypoint_name, keypoint] : bo)
99 {
100 armarx::human::arondto::PoseKeypoint keypoint_dto;
101 toAron(keypoint_dto, keypoint);
102 dto[keypoint_name] = keypoint_dto;
103 }
104 }
105
106 void
107 fromAron(const armarx::human::arondto::PoseKeypoint& dto, PoseKeypoint& bo)
108 {
109 armarx::fromAron(dto.positionCamera, bo.positionCamera);
110 armarx::fromAron(dto.orientationCamera, bo.orientationCamera);
111 armarx::fromAron(dto.positionRobot, bo.positionRobot);
112 armarx::fromAron(dto.orientationRobot, bo.orientationRobot);
113 armarx::fromAron(dto.positionGlobal, bo.positionGlobal);
114 armarx::fromAron(dto.orientationGlobal, bo.orientationGlobal);
115 bo.confidence = dto.confidence;
116 }
117
118 void
119 toAron(armarx::human::arondto::PoseKeypoint& dto, const PoseKeypoint& bo)
120 {
121 armarx::toAron(dto.positionCamera, bo.positionCamera);
122 armarx::toAron(dto.orientationCamera, bo.orientationCamera);
123 armarx::toAron(dto.positionRobot, bo.positionRobot);
124 armarx::toAron(dto.orientationRobot, bo.orientationRobot);
125 armarx::toAron(dto.positionGlobal, bo.positionGlobal);
126 armarx::toAron(dto.orientationGlobal, bo.orientationGlobal);
127 dto.confidence = bo.confidence;
128 }
129
130 void
131 fromAron(const armarx::human::arondto::HumanPose2D& dto, HumanPose2D& bo)
132 {
134
136
137 fromAron(dto.poseModelId, bo.poseModelId);
138 bo.humanTrackingId = dto.humanTrackingId;
139 bo.cameraFrameName = dto.cameraFrameName;
140 fromAron(dto.keypoints, bo.keypoints);
141 }
142
143 void
144 toAron(armarx::human::arondto::HumanPose2D& dto, const HumanPose2D& bo)
145 {
147
148 toAron(dto.poseModelId, bo.poseModelId);
149 dto.humanTrackingId = bo.humanTrackingId;
150 dto.cameraFrameName = bo.cameraFrameName;
151 toAron(dto.keypoints, bo.keypoints);
152 }
153
154 void
155 fromAron(const std::map<std::string, armarx::human::arondto::PoseKeypoint2D>& dto,
156 std::map<std::string, armarx::armem::human::PoseKeypoint2D>& bo)
157 {
158 bo.clear();
159 for (const auto& [keypoint_name, keypoint] : dto)
160 {
162 keypoint_bo.label = keypoint_name;
163 fromAron(keypoint, keypoint_bo);
164 bo[keypoint_name] = keypoint_bo;
165 }
166 }
167
168 void
169 toAron(std::map<std::string, armarx::human::arondto::PoseKeypoint2D>& dto,
170 const std::map<std::string, armarx::armem::human::PoseKeypoint2D>& bo)
171 {
172 dto.clear();
173 for (const auto& [keypoint_name, keypoint] : bo)
174 {
175 armarx::human::arondto::PoseKeypoint2D keypoint_dto;
176 toAron(keypoint_dto, keypoint);
177 dto[keypoint_name] = keypoint_dto;
178 }
179 }
180
181 void
182 fromAron(const armarx::human::arondto::PoseKeypoint2D& dto, PoseKeypoint2D& bo)
183 {
184 bo.position = Eigen::Vector2f(dto.x, dto.y);
185 bo.confidence = dto.confidence;
186 }
187
188 void
189 toAron(armarx::human::arondto::PoseKeypoint2D& dto, const PoseKeypoint2D& bo)
190 {
191 dto.x = bo.position.x();
192 dto.y = bo.position.y();
193 dto.confidence = bo.confidence;
194 }
195
196 void
197 fromAron(const armarx::human::arondto::FaceRecognition& dto, FaceRecognition& bo)
198 {
199 bo.position3DGlobal = Eigen::Matrix(dto.position3DGlobal);
200 bo.extents2D = Eigen::Matrix(dto.extents2D);
201 bo.position2D = Eigen::Matrix(dto.position2D);
202 FramedPosition dtoFramedPosition;
203 armarx::aron::framed::fromAron(dto.framedPosition3D, dtoFramedPosition);
204 bo.framedPosition3D = FramedPosition(dtoFramedPosition);
205 if (dto.profileID.has_value())
206 {
207 armarx::armem::arondto::MemoryID dtoID = dto.profileID.value();
209 armarx::armem::fromAron(dtoID, boID);
210 bo.profileID = boID;
211 }
212 }
213
214 void
215 toAron(armarx::human::arondto::FaceRecognition& dto, const FaceRecognition& bo)
216 {
217 dto.position3DGlobal = Eigen::Matrix(bo.position3DGlobal);
218 dto.extents2D = Eigen::Matrix(bo.extents2D);
219 dto.position2D = Eigen::Matrix(bo.position2D);
221 if (bo.profileID.has_value())
222 {
223 armarx::armem::MemoryID boID = bo.profileID.value();
224 armarx::armem::arondto::MemoryID dtoID;
225 armarx::armem::toAron(dtoID, boID);
226 dto.profileID = dtoID;
227 }
228 // dto.profileID = armarx::aron::toAron<armarx::armem::arondto::MemoryID>(bo.profileID);
229 }
230
231 void
232 fromAron(const armarx::human::arondto::PersonInstance& dto, PersonInstance& bo)
233 {
235 armarx::armem::fromAron(dto.faceRecognitionID, bo.faceRecognitionID);
237 bo.globalPose = Eigen::Isometry3f{dto.pose};
238 }
239
240 void
241 toAron(armarx::human::arondto::PersonInstance& dto, const PersonInstance& bo)
242 {
243 armarx::armem::toAron(dto.profileID, bo.profileID);
244 armarx::armem::toAron(dto.faceRecognitionID, bo.faceRecognitionID);
245 armarx::armem::toAron(dto.poseID, bo.poseID);
246 dto.pose = bo.globalPose.matrix();
247 }
248
249 void
250 fromAron(const armarx::human::arondto::FaceImage& dto, FaceImage& bo)
251 {
252 bo.image = dto.image;
253 if (dto.filepath.has_value())
254 {
255 std::filesystem::path path(dto.filepath.value().path);
256 armarx::PackagePath p = armarx::PackagePath(dto.filepath.value().package, path);
257 armarx::data::PackagePath filePath = p.serialize();
258 bo.filepath = std::make_optional(filePath);
259 }
260 }
261
262 void
263 toAron(armarx::human::arondto::FaceImage& dto, const FaceImage& bo)
264 {
265 dto.image = bo.image;
266 if (bo.filepath.has_value())
267 {
268 armarx::arondto::PackagePath filePath = armarx::arondto::PackagePath();
269 filePath.package = bo.filepath.value().package;
270 filePath.path = bo.filepath.value().path;
271 dto.filepath = filePath;
272 }
273 }
274
275 void
276 fromAron(const armarx::human::arondto::PersonalRooms& dto, PersonalRooms& bo)
277 {
278 bo.bedroom = dto.bedroom;
279 }
280
281 void
282 toAron(armarx::human::arondto::PersonalRooms& dto, const PersonalRooms& bo)
283 {
284 dto.bedroom = bo.bedroom;
285 }
286
287 void
288 fromAron(const armarx::human::arondto::Gender& dto, Gender& bo)
289 {
290 switch (dto.value)
291 {
292 case armarx::human::arondto::Gender::UNKNOWN:
293 bo = Gender::UNKOWN;
294 break;
295 case armarx::human::arondto::Gender::DIVERSE:
296 bo = Gender::DIVERSE;
297 break;
298 case armarx::human::arondto::Gender::FEMALE:
299 bo = Gender::FEMALE;
300 break;
301 case armarx::human::arondto::Gender::MALE:
302 bo = Gender::MALE;
303 break;
304 }
305 }
306
307 void
308 toAron(armarx::human::arondto::Gender& dto, const Gender& bo)
309 {
310 switch (bo)
311 {
312 case Gender::UNKOWN:
313 dto = armarx::human::arondto::Gender::UNKNOWN;
314 break;
315 case Gender::DIVERSE:
316 dto = armarx::human::arondto::Gender::DIVERSE;
317 break;
318 case Gender::FEMALE:
319 dto = armarx::human::arondto::Gender::FEMALE;
320 break;
321 case Gender::MALE:
322 dto = armarx::human::arondto::Gender::MALE;
323 break;
324 }
325 }
326
327 void
328 fromAron(const armarx::human::arondto::Handedness& dto, Handedness& bo)
329 {
330 switch (dto.value)
331 {
332 case armarx::human::arondto::Handedness::UNKNOWN:
334 break;
335 case armarx::human::arondto::Handedness::BOTH:
336 bo = Handedness::BOTH;
337 break;
338 case armarx::human::arondto::Handedness::LEFT:
339 bo = Handedness::LEFT;
340 break;
341 case armarx::human::arondto::Handedness::RIGHT:
343 break;
344 }
345 }
346
347 void
348 toAron(armarx::human::arondto::Handedness& dto, const Handedness& bo)
349 {
350 switch (bo)
351 {
353 dto = armarx::human::arondto::Handedness::UNKNOWN;
354 break;
355 case Handedness::BOTH:
356 dto = armarx::human::arondto::Handedness::BOTH;
357 break;
358 case Handedness::LEFT:
359 dto = armarx::human::arondto::Handedness::LEFT;
360 break;
362 dto = armarx::human::arondto::Handedness::RIGHT;
363 break;
364 }
365 }
366
367 void
368 fromAron(const armarx::human::arondto::Preference& dto, Preference& bo)
369 {
370 bo.disliked = dto.disliked;
371 bo.preferred = dto.preferred;
372 }
373
374 void
375 toAron(armarx::human::arondto::Preference& dto, const Preference& bo)
376 {
377 dto.disliked = bo.disliked;
378 dto.preferred = bo.preferred;
379 }
380
381 void
382 fromAron(const armarx::human::arondto::Preferences& dto, Preferences& bo)
383 {
384 fromAronOptional(dto.communicationStyle, bo.communicationStyle);
385 fromAronOptional(dto.color, bo.color);
386 fromAronOptional(dto.food, bo.food);
387 fromAronOptional(dto.drink, bo.drink);
388 fromAronOptional(dto.hobbies, bo.hobbies);
389 fromAronOptional(dto.music, bo.music);
390 fromAronOptional(dto.fashion, bo.fashion);
391 fromAronOptional(dto.travel, bo.travel);
392 fromAronOptional(dto.people, bo.people);
393 fromAronOptional(dto.work, bo.work);
394 fromAronOptional(dto.technology, bo.technology);
395 fromAronOptional(dto.valuesAndBeliefs, bo.valuesAndBeliefs);
396 }
397
398 void
399 toAron(armarx::human::arondto::Preferences& dto, const Preferences& bo)
400 {
401 toAronOptional(dto.communicationStyle, bo.communicationStyle);
402 toAronOptional(dto.color, bo.color);
403 toAronOptional(dto.food, bo.food);
404 toAronOptional(dto.drink, bo.drink);
405 toAronOptional(dto.hobbies, bo.hobbies);
406 toAronOptional(dto.music, bo.music);
407 toAronOptional(dto.fashion, bo.fashion);
408 toAronOptional(dto.travel, bo.travel);
409 toAronOptional(dto.people, bo.people);
410 toAronOptional(dto.work, bo.work);
411 toAronOptional(dto.technology, bo.technology);
412 toAronOptional(dto.valuesAndBeliefs, bo.valuesAndBeliefs);
413 }
414
415 void
416 fromAron(const armarx::human::arondto::PhysicalData& dto, PhysicalData& bo)
417 {
418 fromAron(dto.gender, bo.gender);
419 fromAron(dto.handedness, bo.handedness);
420 bo.birthday = dto.birthday;
421 bo.heightInMillimeters = dto.heightInMillimeters;
422 bo.weightInGrams = dto.weightInGrams;
423 }
424
425 void
426 toAron(armarx::human::arondto::PhysicalData& dto, const PhysicalData& bo)
427 {
428 toAron(dto.gender, bo.gender);
429 toAron(dto.handedness, bo.handedness);
430 dto.birthday = bo.birthday;
431 dto.heightInMillimeters = bo.heightInMillimeters;
432 dto.weightInGrams = bo.weightInGrams;
433 }
434
435 void
436 fromAron(const armarx::human::arondto::Abilities& dto, Abilities& bo)
437 {
438 bo.canWalk = dto.canWalk;
439 bo.canGraspLeft = dto.canGraspLeft;
440 bo.canGraspRight = dto.canGraspRight;
441 bo.canStand = dto.canStand;
442 bo.isDeaf = dto.isDeaf;
443 bo.isBlind = dto.isBlind;
444 bo.isColorblind = dto.isColorblind;
445 }
446
447 void
448 toAron(armarx::human::arondto::Abilities& dto, const Abilities& bo)
449 {
450 dto.canWalk = bo.canWalk;
451 dto.canGraspLeft = bo.canGraspLeft;
452 dto.canGraspRight = bo.canGraspRight;
453 dto.canStand = bo.canStand;
454 dto.isDeaf = bo.isDeaf;
455 dto.isBlind = bo.isBlind;
456 dto.isColorblind = bo.isColorblind;
457 }
458
459 void
460 fromAron(const armarx::human::arondto::Person& dto, Person& bo)
461 {
462 fromAron(dto.id, bo.id);
463 fromAron(dto.names, bo.names);
464
465 std::vector<FaceImage> faceImages;
466 for (const auto& image_dto : dto.faceImages)
467 {
468 FaceImage image_bo;
469 fromAron(image_dto, image_bo);
470 faceImages.push_back(image_bo);
471 }
472 bo.faceImages = faceImages;
473
474 bo.roles = dto.roles;
475 fromAronOptional(dto.rooms, bo.rooms);
476
477 fromAron(dto.physiologicalBiometrics, bo.physiologicalBiometrics);
478
479 bo.previousInteractions = dto.previousInteractions;
480 fromAron(dto.preferences, bo.preferences);
481 fromAron(dto.abilities, bo.abilities);
482 bo.medicalConditions = dto.medicalConditions;
483 bo.customAttributes = dto.customAttributes;
484 bo.customNotes = dto.customNotes;
485 bo.attributes = dto.attributes;
486 }
487
488 void
489 toAron(armarx::human::arondto::Person& dto, const Person& bo)
490 {
491 toAron(dto.id, bo.id);
492 toAron(dto.names, bo.names);
493
494 std::vector<armarx::human::arondto::FaceImage> faceImages;
495 for (const auto& image_bo : bo.faceImages)
496 {
497 armarx::human::arondto::FaceImage image_dto;
498 toAron(image_dto, image_bo);
499 faceImages.push_back(image_dto);
500 }
501 dto.faceImages = faceImages;
502
503
504 dto.roles = bo.roles;
505 toAronOptional(dto.rooms, bo.rooms);
506
507 toAron(dto.physiologicalBiometrics, bo.physiologicalBiometrics);
508
509 dto.previousInteractions = bo.previousInteractions;
510 toAron(dto.preferences, bo.preferences);
511 toAron(dto.abilities, bo.abilities);
512 dto.medicalConditions = bo.medicalConditions;
513 dto.customAttributes = bo.customAttributes;
514 dto.customNotes = bo.customNotes;
515 dto.attributes = bo.attributes;
516 }
517
518 void
519 fromAron(const armarx::human::arondto::PersonID& dto, PersonID& bo)
520 {
521 bo.firstName = dto.firstName;
522 bo.lastName = dto.lastName;
523 }
524
525 void
526 toAron(armarx::human::arondto::PersonID& dto, const PersonID& bo)
527 {
528 dto.firstName = bo.firstName;
529 dto.lastName = bo.lastName;
530 }
531
532 void
533 fromAron(const armarx::human::arondto::ActivityType& dto, ActivityType& bo)
534 {
535 switch (dto.value)
536 {
537 case armarx::human::arondto::ActivityType::UNKNOWN:
539 break;
540 case armarx::human::arondto::ActivityType::WALKING:
542 break;
543 case armarx::human::arondto::ActivityType::STANDING:
545 break;
546 case armarx::human::arondto::ActivityType::SITTING:
548 break;
549 case armarx::human::arondto::ActivityType::REACHING:
551 break;
552 case armarx::human::arondto::ActivityType::GRASPING:
554 break;
555 case armarx::human::arondto::ActivityType::POINTING:
557 break;
558 case armarx::human::arondto::ActivityType::WAVING:
560 break;
561 case armarx::human::arondto::ActivityType::TALKING:
563 break;
564 case armarx::human::arondto::ActivityType::LISTENING:
566 break;
567 case armarx::human::arondto::ActivityType::WORKING:
569 break;
570 case armarx::human::arondto::ActivityType::EATING:
572 break;
573 case armarx::human::arondto::ActivityType::DRINKING:
575 break;
576 case armarx::human::arondto::ActivityType::SERVICE_REFUSAL:
578 break;
579 case armarx::human::arondto::ActivityType::CUSTOM:
581 break;
582 }
583 }
584
585 void
586 toAron(armarx::human::arondto::ActivityType& dto, const ActivityType& bo)
587 {
588 switch (bo)
589 {
591 dto = armarx::human::arondto::ActivityType::UNKNOWN;
592 break;
594 dto = armarx::human::arondto::ActivityType::WALKING;
595 break;
597 dto = armarx::human::arondto::ActivityType::STANDING;
598 break;
600 dto = armarx::human::arondto::ActivityType::SITTING;
601 break;
603 dto = armarx::human::arondto::ActivityType::REACHING;
604 break;
606 dto = armarx::human::arondto::ActivityType::GRASPING;
607 break;
609 dto = armarx::human::arondto::ActivityType::POINTING;
610 break;
612 dto = armarx::human::arondto::ActivityType::WAVING;
613 break;
615 dto = armarx::human::arondto::ActivityType::TALKING;
616 break;
618 dto = armarx::human::arondto::ActivityType::LISTENING;
619 break;
621 dto = armarx::human::arondto::ActivityType::WORKING;
622 break;
624 dto = armarx::human::arondto::ActivityType::EATING;
625 break;
627 dto = armarx::human::arondto::ActivityType::DRINKING;
628 break;
630 dto = armarx::human::arondto::ActivityType::SERVICE_REFUSAL;
631 break;
633 dto = armarx::human::arondto::ActivityType::CUSTOM;
634 break;
635 }
636 }
637
638 void
639 fromAron(const armarx::human::arondto::HumanActivity& dto, HumanActivity& bo)
640 {
642
643 fromAron(dto.activityType, bo.activityType);
644 bo.activityName = dto.activityName;
645 bo.confidence = dto.confidence;
646 fromAron(dto.startTime, bo.startTime);
647 fromAron(dto.endTime, bo.endTime);
648 fromAronOptional(dto.personID, bo.personID);
649 bo.description = dto.description;
650 }
651
652 void
653 toAron(armarx::human::arondto::HumanActivity& dto, const HumanActivity& bo)
654 {
656
657 toAron(dto.activityType, bo.activityType);
658 dto.activityName = bo.activityName;
659 dto.confidence = bo.confidence;
660 toAron(dto.startTime, bo.startTime);
661 toAron(dto.endTime, bo.endTime);
662 toAronOptional(dto.personID, bo.personID);
663 dto.description = bo.description;
664 }
665
666 void
667 fromAron(const armarx::human::arondto::InteractionType& dto, InteractionType& bo)
668 {
669 switch (dto.value)
670 {
671 case armarx::human::arondto::InteractionType::UNKNOWN:
673 break;
674 case armarx::human::arondto::InteractionType::HANDOVER:
676 break;
677 case armarx::human::arondto::InteractionType::ANSWERING_QUESTION:
679 break;
680 case armarx::human::arondto::InteractionType::SERVING_DRINK:
682 break;
683 case armarx::human::arondto::InteractionType::SERVING_FOOD:
685 break;
686 case armarx::human::arondto::InteractionType::GUIDING:
688 break;
689 case armarx::human::arondto::InteractionType::ASSISTING:
691 break;
692 case armarx::human::arondto::InteractionType::CONVERSATION:
694 break;
695 case armarx::human::arondto::InteractionType::GREETING:
697 break;
698 case armarx::human::arondto::InteractionType::FAREWELL:
700 break;
701 case armarx::human::arondto::InteractionType::CUSTOM:
703 break;
704 }
705 }
706
707 void
708 toAron(armarx::human::arondto::InteractionType& dto, const InteractionType& bo)
709 {
710 switch (bo)
711 {
713 dto = armarx::human::arondto::InteractionType::UNKNOWN;
714 break;
716 dto = armarx::human::arondto::InteractionType::HANDOVER;
717 break;
719 dto = armarx::human::arondto::InteractionType::ANSWERING_QUESTION;
720 break;
722 dto = armarx::human::arondto::InteractionType::SERVING_DRINK;
723 break;
725 dto = armarx::human::arondto::InteractionType::SERVING_FOOD;
726 break;
728 dto = armarx::human::arondto::InteractionType::GUIDING;
729 break;
731 dto = armarx::human::arondto::InteractionType::ASSISTING;
732 break;
734 dto = armarx::human::arondto::InteractionType::CONVERSATION;
735 break;
737 dto = armarx::human::arondto::InteractionType::GREETING;
738 break;
740 dto = armarx::human::arondto::InteractionType::FAREWELL;
741 break;
743 dto = armarx::human::arondto::InteractionType::CUSTOM;
744 break;
745 }
746 }
747
748 void
749 fromAron(const armarx::human::arondto::HumanRobotInteraction& dto, HumanRobotInteraction& bo)
750 {
752
753 fromAron(dto.interactionType, bo.interactionType);
754 bo.interactionName = dto.interactionName;
755 bo.confidence = dto.confidence;
756 fromAron(dto.startTime, bo.startTime);
757 fromAron(dto.endTime, bo.endTime);
758 fromAronOptional(dto.personID, bo.personID);
759 bo.robotName = dto.robotName;
760 bo.description = dto.description;
761 }
762
763 void
764 toAron(armarx::human::arondto::HumanRobotInteraction& dto, const HumanRobotInteraction& bo)
765 {
767
768 toAron(dto.interactionType, bo.interactionType);
769 dto.interactionName = bo.interactionName;
770 dto.confidence = bo.confidence;
771 toAron(dto.startTime, bo.startTime);
772 toAron(dto.endTime, bo.endTime);
773 toAronOptional(dto.personID, bo.personID);
774 dto.robotName = bo.robotName;
775 dto.description = bo.description;
776 }
777
778} // namespace armarx::armem::human
The FramedPosition class.
Definition FramedPose.h:158
data::PackagePath serialize() const
void toAron(armarx::human::arondto::HumanPose &dto, const HumanPose &bo)
void fromAron(const armarx::human::arondto::HumanPose &dto, HumanPose &bo)
void fromAron(const arondto::MemoryID &dto, MemoryID &bo)
void toAron(arondto::MemoryID &dto, const MemoryID &bo)
void toAron(arondto::FramedPosition &dto, const armarx::FramedPosition &bo)
Definition framed.cpp:18
void fromAron(const arondto::FramedPosition &dto, armarx::FramedPosition &bo)
Definition framed.cpp:8
void fromAron(const T &dto, T &bo)
void toAron(T &dto, const T &bo)
Framework for converting ARON DTOs (Data Transfer Objects) to C++ BOs (Business Objects) and back.
void toAron(arondto::PackagePath &dto, const PackageFileLocation &bo)
void fromAron(const arondto::PackagePath &dto, PackageFileLocation &bo)
std::optional< bool > canGraspRight
Definition types.h:199
std::optional< bool > canStand
Definition types.h:200
std::optional< bool > isColorblind
Definition types.h:203
std::optional< bool > canGraspLeft
Definition types.h:198
std::optional< bool > isDeaf
Definition types.h:201
std::optional< bool > canWalk
Definition types.h:197
std::optional< bool > isBlind
Definition types.h:202
std::optional< armarx::data::PackagePath > filepath
Definition types.h:96
std::optional< armarx::armem::MemoryID > profileID
Definition types.h:80
armarx::core::time::DateTime startTime
Definition types.h:302
armarx::core::time::DateTime endTime
Definition types.h:303
std::optional< std::string > description
Definition types.h:305
std::optional< PersonID > personID
Definition types.h:304
std::optional< std::string > humanTrackingId
Definition types.h:65
std::map< std::string, PoseKeypoint2D > keypoints
Definition types.h:64
std::optional< std::string > humanTrackingId
Definition types.h:47
armarx::core::time::DateTime startTime
Definition types.h:328
armarx::core::time::DateTime endTime
Definition types.h:329
std::optional< std::string > description
Definition types.h:332
std::optional< PersonID > personID
Definition types.h:330
std::optional< std::string > robotName
Definition types.h:331
armarx::armem::MemoryID profileID
Definition types.h:85
Eigen::Isometry3f globalPose
Definition types.h:90
armarx::armem::MemoryID faceRecognitionID
Definition types.h:86
armarx::armem::MemoryID poseID
Definition types.h:87
std::vector< FaceImage > faceImages
Definition types.h:210
std::vector< std::string > medicalConditions
Definition types.h:217
std::vector< std::string > previousInteractions
Definition types.h:214
PhysicalData physiologicalBiometrics
Definition types.h:213
armarx::aron::data::DictPtr attributes
Definition types.h:220
std::vector< std::string > customNotes
Definition types.h:219
std::optional< PersonalRooms > rooms
Definition types.h:212
std::map< std::string, std::string > customAttributes
Definition types.h:218
std::vector< std::string > roles
Definition types.h:211
std::optional< double > weightInGrams
Definition types.h:170
std::optional< armarx::core::time::DateTime > birthday
Definition types.h:167
std::optional< double > heightInMillimeters
Definition types.h:169
std::optional< armarx::FramedPosition > positionRobot
Definition types.h:35
std::optional< armarx::FramedOrientation > orientationGlobal
Definition types.h:38
armarx::FramedPosition positionCamera
Definition types.h:33
std::optional< armarx::FramedOrientation > orientationCamera
Definition types.h:34
std::optional< armarx::FramedPosition > positionGlobal
Definition types.h:37
std::optional< armarx::FramedOrientation > orientationRobot
Definition types.h:36
std::vector< std::string > disliked
Definition types.h:176
std::vector< std::string > preferred
Definition types.h:175
std::optional< Preference > color
Definition types.h:182
std::optional< Preference > music
Definition types.h:186
std::optional< Preference > hobbies
Definition types.h:185
std::optional< Preference > food
Definition types.h:183
std::optional< Preference > people
Definition types.h:189
std::optional< Preference > work
Definition types.h:190
std::optional< Preference > travel
Definition types.h:188
std::optional< Preference > fashion
Definition types.h:187
std::optional< Preference > drink
Definition types.h:184
std::optional< Preference > communicationStyle
Definition types.h:181
std::optional< Preference > valuesAndBeliefs
Definition types.h:192
std::optional< Preference > technology
Definition types.h:191
#define ARMARX_TRACE
Definition trace.h:77