Component.cpp
Go to the documentation of this file.
1 /**
2  * This file is part of ArmarX.
3  *
4  * ArmarX is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License version 2 as
6  * published by the Free Software Foundation.
7  *
8  * ArmarX is distributed in the hope that it will be useful, but
9  * WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  *
13  * You should have received a copy of the GNU General Public License
14  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15  *
16  * @package Navigation::ArmarXObjects::Navigator
17  * @author Fabian Reister ( fabian dot reister at kit dot edu )
18  * @author Christian R. G. Dreher ( c dot dreher at kit dot edu )
19  * @date 2021
20  * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
21  * GNU General Public License
22  */
23 
24 #include "Component.h"
25 
26 #include <algorithm>
27 #include <cmath>
28 #include <cstdint>
29 #include <experimental/memory>
30 #include <iterator>
31 #include <memory>
32 #include <optional>
33 #include <string>
34 #include <tuple>
35 #include <utility>
36 #include <vector>
37 
38 #include <Eigen/Geometry>
39 
40 #include <opencv2/core/eigen.hpp>
41 
42 #include <Ice/Current.h>
43 
44 #include <SimoxUtility/color/ColorMap.h>
45 #include <SimoxUtility/color/cmaps/colormaps.h>
46 
56 
59 #include <RobotAPI/interface/ArViz/Elements.h>
60 #include <RobotAPI/interface/aron/Aron.h>
62 
64 #include <armarx/navigation/client/ice/NavigatorInterface.h>
82 
84 {
86 }
87 
88 namespace armarx::navigation
89 {
90 
91  std::vector<core::Pose>
92  convert(const std::vector<Eigen::Matrix4f>& wps)
93  {
94  std::vector<core::Pose> p;
95  p.reserve(wps.size());
96  std::transform(wps.begin(),
97  wps.end(),
98  std::back_inserter(p),
99  [](const auto& p) { return core::Pose(p); });
100  return p;
101  }
102 
103 } // namespace armarx::navigation
104 
106 {
107 
108  Component::Component() : parameterizationService(nullptr, nullptr)
109  // publisher(&resultsWriter, &eventsWriter)
110  {
111  // scene().timeServer = &timeServer;
112 
113  addPlugin(parameterizationReaderPlugin);
114  addPlugin(parameterizationWriterPlugin);
115  addPlugin(eventsWriterPlugin);
116  addPlugin(resultsWriterPlugin);
117  addPlugin(graphReaderPlugin);
118  addPlugin(costmapReaderPlugin);
119  addPlugin(humanReaderPlugin);
120  addPlugin(laserScannerFeaturesReaderPlugin);
121 
122  addPlugin(virtualRobotReaderPlugin);
123 
124  parameterizationService = server::MemoryParameterizationService(
125  &parameterizationReaderPlugin->get(), &parameterizationWriterPlugin->get());
126  }
127 
128 
129  Component::~Component() = default;
130 
131  void
133  {
134  }
135 
136  void
138  {
139  ARMARX_TRACE;
140 
141  // virtualRobotReaderPlugin->get().setSyncTimeout(Duration::MilliSeconds(20));
142  // virtualRobotReaderPlugin->get().setSleepAfterSyncFailure(Duration::MilliSeconds(10));
143 
145 
146  // initialize scene provider
147  ARMARX_TRACE;
148  {
150  .graphReader = &graphReaderPlugin->get(),
151  .costmapReader = &costmapReaderPlugin->get(),
152  .virtualRobotReader = &virtualRobotReaderPlugin->get(),
153  .humanReader = &humanReaderPlugin->get(),
154  .laserScannerFeaturesReader = &laserScannerFeaturesReaderPlugin->get(),
155  .objectPoseClient = ObjectPoseClientPluginUser::getClient()};
156 
157  // emplace (below) will be effectless if object is already initialized
158  ARMARX_CHECK_NULL(sceneProvider);
159  sceneProvider.emplace(srv, params.sceneCfg);
160  }
161 
162  initializeScene();
163 
164  ARMARX_TRACE;
165 
166  if (not params.disableExecutor)
167  {
168  ARMARX_CHECK_NULL(executor);
169 
170  executor.emplace(
173  .robotName = params.sceneCfg.robotName,
174  .rtUnitDynamicallyLoadLibraries = params.rtUnitDynamicallyLoadLibraries});
175  }
176 
177  ARMARX_TRACE;
178 
179  ARMARX_CHECK_NULL(introspector);
180  introspector = server::ArvizIntrospector(
182  // memoryIntrospector = server::MemoryIntrospector(resultsWriterPlugin->get(), );
183 
184  ARMARX_CHECK_NULL(navRemoteGui);
185  navRemoteGui.emplace(remoteGui, *this);
186  navRemoteGui->enable();
187 
188  // initialized = true;
189 
190  ARMARX_INFO << "Initialized. Will now respond to navigation requests.";
191  }
192 
193  void
195  {
196  ARMARX_TRACE;
197 
198  // "Running" in a broader sense. The navigator could also be paused but will be stopped subsequenty.
199  const bool isAnyNavigatorRunning = std::any_of(navigators.begin(),
200  navigators.end(),
201  [](const auto& p) -> bool
202  {
203  const server::Navigator& navigator =
204  p.second;
205 
206  return not navigator.isStopped();
207  });
208 
209 
210  if (isAnyNavigatorRunning)
211  {
213  << "A navigator was running when the component got disconnected. Will try to stop "
214  "as much as possible but expect something to be broken now.";
215  }
216 
217  stopAllImpl(isAnyNavigatorRunning);
218 
219  navRemoteGui->disable();
220  navRemoteGui.reset();
221 
222  sceneProvider.reset();
223  executor.reset();
224  introspector.reset();
225  }
226 
227  void
229  {
230  }
231 
232  bool
234  {
235  ARMARX_TRACE;
236  return sceneProvider->initialize(armarx::Clock::Now());
237  }
238 
239  std::string
241  {
242  return GetDefaultName();
243  }
244 
245  std::string
247  {
248  return "navigator";
249  }
250 
251  void
253  const std::string& callerId,
254  const Ice::Current&)
255  {
256  // TODO: Not thread-safe.
257  ARMARX_TRACE;
258  ARMARX_INFO << "Creating config for caller '" << callerId << "'";
259 
260  parameterizationService.store(stackConfig, callerId, armarx::Clock::Now());
261 
263  stackConfig,
264  sceneProvider->scene(),
266 
267  // FIXME unify this. The local planner also needs the visu. Yet, it is passed to the navigation stack factory above now.
268  // set visualization of LocalPlanner
269  if (stack.localPlanner)
270  {
271  stack.localPlanner->setVisualization(getArvizClient());
272  }
273 
274  memoryIntrospectors.emplace_back(
275  std::make_unique<server::MemoryIntrospector>(resultsWriterPlugin->get(), callerId));
276 
277  // keep track of all memory publishers
278  memoryPublishers.emplace(
279  callerId,
280  std::make_unique<server::MemoryPublisher>(
281  &resultsWriterPlugin->get(), &eventsWriterPlugin->get(), callerId));
282 
283  server::ExecutorInterface* executorPtr = nullptr;
284  if (executor.has_value())
285  {
286  executorPtr = &executor.value();
287  }
288 
289  // if we emplace an existing key it is not replaced, so remove it first.
290  navigators.erase(callerId);
291  navigators.emplace(
292  std::piecewise_construct,
293  std::forward_as_tuple(callerId),
294  std::forward_as_tuple(
295  server::Navigator::Config{.stack = std::move(stack),
296  .general = params.navigatorGeneralConfig,
297  .goalReachedConfig = params.navigatorGoalReachedConfig},
299  .executor = executorPtr,
300  .publisher = memoryPublishers.at(callerId).get(),
301  .introspector = introspector.has_value() ? &(introspector.value()) : nullptr,
302  .debugObserverHelper = &getDebugObserverComponentPlugin(),
303  .sceneProvider =
304  sceneProvider.has_value() ? &sceneProvider.value() : nullptr}));
305  }
306 
307  void
308  Component::moveTo(const std::vector<Eigen::Matrix4f>& waypoints,
309  const std::string& navigationMode,
310  const std::string& callerId,
311  const Ice::Current&)
312  {
313  ARMARX_TRACE;
314 
315  ARMARX_INFO << "moveTo() requested by caller '" << callerId << "' with navigation mode `"
316  << navigationMode << "`.";
317  ARMARX_CHECK(navigators.count(callerId) > 0)
318  << "Navigator config for caller `" << callerId << "` not registered!";
319 
320  try
321  {
322  navigators.at(callerId).moveTo(convert(waypoints),
323  core::NavigationFrameNames.from_name(navigationMode));
324  }
325  catch (...)
326  {
328 
329  // TODO: Error handling.
330  ARMARX_WARNING << "Failed to execute moveTo()."
331  << "Movement will be paused.";
332  stopAll(); // TODO pause movement must not throw
333  throw;
334  }
335  }
336 
337  void
338  Component::updateMoveTo(const std::vector<Eigen::Matrix4f>& waypoints,
339  const std::string& navigationMode,
340  const std::string& callerId,
341  const Ice::Current& /*c*/)
342  {
343  ARMARX_TRACE;
344 
345  ARMARX_INFO << "updateMoveTo() requested by caller '" << callerId << "'";
346  ARMARX_CHECK(navigators.count(callerId) > 0)
347  << "Navigator config for caller `" << callerId << "` not registered!";
348 
349  const auto checkIsActiveNavigator = [&](const std::string& callerId)
350  {
351  const std::optional<std::string> activeNavigatorCallerId = activeNavigatorId();
352  if (not activeNavigatorCallerId.has_value())
353  {
354  ARMARX_VERBOSE << "No navigator is active.";
355  return false;
356  }
357 
358  return activeNavigatorCallerId == callerId;
359  };
360 
361  ARMARX_CHECK(checkIsActiveNavigator(callerId))
362  << "The navigator with id `" << callerId << "` is not active!";
363 
364  navigators.at(callerId).update(convert(waypoints),
365  core::NavigationFrameNames.from_name(navigationMode));
366  }
367 
368  void
370  const std::string& navigationMode,
371  const std::string& callerId,
372  const Ice::Current& c)
373  {
374  ARMARX_TRACE;
375 
376  ARMARX_IMPORTANT << "moveTo2 requested by caller '" << callerId << "'";
377 
378  const std::vector<client::WaypointTarget> wps = client::defrost(waypoints);
379 
380  ARMARX_CHECK(navigators.count(callerId) > 0)
381  << "Navigator config for caller `" << callerId << "` not registered!";
382 
383  navigators.at(callerId).moveTo(wps, core::NavigationFrameNames.from_name(navigationMode));
384  }
385 
386  void
387  Component::moveToLocation(const std::string& location,
388  const std::string& callerId,
389  const Ice::Current& c)
390  {
391  ARMARX_TRACE;
392  ARMARX_INFO << "MoveToLocation `" << location << "` requested by caller '" << callerId
393  << "'";
394 
395  ARMARX_CHECK(navigators.count(callerId) > 0)
396  << "Navigator config for caller `" << callerId << "` not registered!";
397 
398  navigators.at(callerId).moveToLocation(location);
399  }
400 
401  void
402  Component::moveTowards(const Eigen::Vector3f& direction,
403  const std::string& navigationMode,
404  const std::string& callerId,
405  const Ice::Current&)
406  {
407  // TODO: Error handling.
408  ARMARX_TRACE;
409  ARMARX_INFO << "MoveTowards requested by caller '" << callerId << "'";
410 
411  ARMARX_CHECK(navigators.count(callerId) > 0)
412  << "Navigator config for caller `" << callerId << "` not registered!";
413 
414  navigators.at(callerId).moveTowards(direction,
415  core::NavigationFrameNames.from_name(navigationMode));
416  }
417 
418  void
419  Component::pause(const std::string& configId, const Ice::Current&)
420  {
421  ARMARX_CHECK(navigators.count(configId) > 0)
422  << "Navigator config for caller `" << configId << "` not registered!";
423  navigators.at(configId).pause();
424  }
425 
426  void
427  Component::resume(const std::string& configId, const Ice::Current&)
428  {
429  ARMARX_TRACE;
430  ARMARX_CHECK(navigators.count(configId) > 0)
431  << "Navigator config for caller `" << configId << "` not registered!";
432  navigators.at(configId).resume();
433  }
434 
435  void
436  Component::stop(const std::string& configId, const Ice::Current&)
437  {
438  // FIXME make sure that event is emitted
439  ARMARX_TRACE;
440  ARMARX_CHECK(navigators.count(configId) > 0)
441  << "Navigator config for caller `" << configId << "` not registered!";
442  navigators.at(configId).stop();
443 
444  // emit UserAbortTriggered event
446  core::Pose(scene().robot->getGlobalPose())};
447  memoryPublishers.at(configId)->userAbortTriggered(event);
448  }
449 
450  void
451  Component::stopAll(const Ice::Current&)
452  {
453  stopAllImpl(true);
454  }
455 
456  void
457  Component::stopAllImpl(const bool emitMemoryEvent)
458  {
459  ARMARX_IMPORTANT << "stopAll()";
460 
461  ARMARX_TRACE;
462  for (auto& [_, navigator] : navigators)
463  {
464  navigator.stop();
465  }
466 
467  if (emitMemoryEvent)
468  {
469  ARMARX_INFO << "Trying to emit memory event `UserAbortTriggered`";
470  // emit UserAbortTriggered event
472  core::Pose(scene().robot->getGlobalPose())};
473 
474  // This call might fail if the component is already disconnected from the NavigationMemory in onDisconnectComponent.
475  for (auto& [callerId, memoryPublisher] : memoryPublishers)
476  {
477  memoryPublisher->userAbortTriggered(event);
478  }
479  }
480  }
481 
482  bool
483  Component::isPaused(const std::string& configId, const Ice::Current&)
484  {
485  ARMARX_TRACE;
486  ARMARX_CHECK(navigators.count(configId) > 0)
487  << "Navigator config for caller `" << configId << "` not registered!";
488  return navigators.at(configId).isPaused();
489  }
490 
491  const core::Scene&
493  {
494  ARMARX_CHECK_NOT_NULL(sceneProvider);
495  return sceneProvider->scene();
496  }
497 
498  bool
499  Component::isStopped(const std::string& configId, const Ice::Current&)
500  {
501  ARMARX_TRACE;
502  ARMARX_CHECK(navigators.count(configId) > 0)
503  << "Navigator config for caller `" << configId << "` not registered!";
504  return navigators.at(configId).isStopped();
505  }
506 
509  {
510  ARMARX_TRACE;
511 
513 
514  // Publish to a topic (passing the TopicListenerPrx).
515  // def->topic(myTopicListener);
516 
517  // Subscribe to a topic (passing the topic name).
518  // def->topic<PlatformUnitListener>("MyTopic");
519 
520  // Use (and depend on) another component (passing the ComponentInterfacePrx).
521  def->component(remoteGui, "RemoteGuiProvider");
522  // Add a required property.
523  // def->required(properties.boxLayerName, "p.box.LayerName", "Name of the box layer in ArViz.");
524 
525  // Add an optionalproperty.
526  def->optional(params.occupiedGridThreshold,
527  "p.occupancy_grid.occopied_threshold",
528  "Threshold for each cell to be considered occupied. Increase this value to "
529  "reduce noise.");
530 
531  def->optional(params.disableExecutor,
532  "p.disableExecutor",
533  "If the executor is disabled, the navigator will only plan the trajectory "
534  "but won't execute it.");
535 
536  def->required(params.sceneCfg.robotName, "p.scene.robotName");
537  def->optional(params.sceneCfg.staticCostmapProviderName,
538  "p.scene.staticCostmapProviderName");
539  def->optional(params.sceneCfg.staticCostmapName, "p.scene.staticCostmapName");
540  def->optional(params.sceneCfg.humanProviderName, "p.scene.humanProviderName");
541  def->optional(params.sceneCfg.laserScannerFeaturesProviderName,
542  "p.scene.laserScannerFeaturesProviderName");
543 
544  def->optional(params.rtUnitDynamicallyLoadLibraries,
545  "p.rtUnitDynamicallyLoadLibraries",
546  "If enabled, the controller library will automatically be loaded in the "
547  "RobotUnit. If disabled (desired), you have to make sure that the controller "
548  "library is listed in the RobotUnit's property `LoadLibraries`");
549 
550 
551  def->optional(params.navigatorGeneralConfig.tasks.replanningUpdatePeriod,
552  "p.navigator.general.replanningPeriod");
553 
554  def->optional(params.navigatorGoalReachedConfig.posTh, "p.navigator.goalReached.posTh");
555  def->optional(params.navigatorGoalReachedConfig.oriTh, "p.navigator.goalReached.oriTh");
556  def->optional(params.navigatorGoalReachedConfig.linearVelTh,
557  "p.navigator.goalReached.linearVelTh");
558  def->optional(params.navigatorGoalReachedConfig.angularVelTh,
559  "p.navigator.goalReached.angularVelTh");
560  def->optional(params.navigatorGoalReachedConfig.filterCount,
561  "p.navigator.goalReached.filterCount");
562 
563  return def;
564  }
565 
566  void
567  visualize(const algorithms::Costmap& costmap, viz::Client& arviz, const std::string& name)
568  {
569  const auto cmap = simox::color::cmaps::viridis();
570  const float vmax = costmap.getGrid().array().maxCoeff();
571 
572  const auto asColor = [&cmap, &vmax](const float distance) -> viz::data::Color
573  {
574  const auto color = cmap.at(distance, 0.F, vmax);
575  return {color.a, color.r, color.g, color.b};
576  };
577 
578  auto layer = arviz.layer("costmap_" + name);
579 
580  const std::int64_t cols = costmap.getGrid().cols();
581  const std::int64_t rows = costmap.getGrid().rows();
582 
583  auto mesh = viz::Mesh("");
584 
585  std::vector<std::vector<Eigen::Vector3f>> vertices;
586  std::vector<std::vector<viz::data::Color>> colors;
587 
588  for (int r = 0; r < rows; r++)
589  {
590  auto& verticesRow = vertices.emplace_back(cols);
591  auto& colorsRow = colors.emplace_back(cols);
592 
593  for (int c = 0; c < cols; c++)
594  {
595  verticesRow.at(c) = conv::to3D(costmap.toPositionGlobal({r, c}));
596  colorsRow.at(c) = asColor(costmap.getGrid()(r, c));
597  }
598  }
599 
600  mesh.grid2D(vertices, colors);
601 
602  layer.add(mesh);
603 
604  arviz.commit(layer);
605  }
606 
609  {
610 
611  const auto navigatorId = activeNavigatorId();
612  if (not navigatorId.has_value())
613  {
614  return nullptr;
615  }
616 
617  return &navigators.at(navigatorId.value());
618  }
619 
620  std::optional<std::string>
622  {
623  ARMARX_TRACE;
624  // We define the active navigator to be the one whose movement is enabled.
625  const auto isActive = [](const auto& nameNavPair) -> bool
626  {
627  const auto& [name, navigator] = nameNavPair;
628  return not navigator.isPaused();
629  };
630 
631  const auto it = std::find_if(navigators.begin(), navigators.end(), isActive);
632 
633  // no navigator active?
634  if (it == navigators.end())
635  {
636  return std::nullopt;
637  }
638 
639  return it->first;
640  }
641 
642 } // namespace armarx::navigation::components::navigator
ice_conversions.h
Client.h
armarx::navigation::components::navigator::Component::activeNavigator
server::Navigator * activeNavigator()
Definition: Component.cpp:608
armarx::viz::Client::commit
CommitResult commit(StagedCommit const &commit)
Definition: Client.cpp:89
armarx::ArVizComponentPluginUser::getArvizClient
armarx::viz::Client & getArvizClient()
Definition: ArVizComponentPlugin.h:45
armarx::navigation::components::navigator::Component::isStopped
bool isStopped(const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:499
ARMARX_VERBOSE
#define ARMARX_VERBOSE
Definition: Logging.h:187
NavigationStack.h
armarx::navigation::components::navigator::Component::activeNavigatorId
std::optional< std::string > activeNavigatorId() const
Definition: Component.cpp:621
armarx::navigation::server::MemoryParameterizationService::store
bool store(const aron::data::DictPtr &params, const std::string &clientId, const armarx::core::time::DateTime &timestamp)
Definition: MemoryParameterizationService.cpp:20
armarx::navigation::server::scene_provider::SceneProvider::InjectedServices::graphReader
memory::client::graph::Reader * graphReader
Definition: SceneProvider.h:73
ARMARX_IMPORTANT
#define ARMARX_IMPORTANT
Definition: Logging.h:190
armarx::navigation::server::PlatformControllerExecutor::Properties::robotName
std::string robotName
Definition: PlatformControllerExecutor.h:36
LocalException.h
armarx::navigation::server::ExecutorInterface
An executer the server navigator will use to send its control commands to.
Definition: ExecutorInterface.h:12
armarx::navigation::core::Pose
Eigen::Isometry3f Pose
Definition: basic_types.h:31
armarx::navigation::components::navigator::Component::createPropertyDefinitions
PropertyDefinitionsPtr createPropertyDefinitions() override
Definition: Component.cpp:508
basic_types.h
ObjectPoseClientPlugin.h
ExecutorInterface.h
armarx::navigation::convert
std::vector< core::Pose > convert(const std::vector< Eigen::Matrix4f > &wps)
Definition: Component.cpp:92
armarx::DebugObserverComponentPluginUser::getDebugObserverComponentPlugin
plugins::DebugObserverComponentPlugin & getDebugObserverComponentPlugin()
Definition: DebugObserverComponentPlugin.cpp:89
armarx::navigation::components::navigator::Component::pause
void pause(const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:419
ARMARX_CHECK_NOT_NULL
#define ARMARX_CHECK_NOT_NULL(ptr)
This macro evaluates whether ptr is not null and if it turns out to be false it will throw an Express...
Definition: ExpressionException.h:206
armarx::navigation::client::NavigatorInterface::stopAll
idempotent void stopAll()
armarx::viz::Mesh
Definition: Mesh.h:28
trace.h
std::experimental::fundamentals_v2::make_observer
observer_ptr< _Tp > make_observer(_Tp *__p) noexcept
armarx::objpose::ObjectPoseClient::objectFinder
ObjectFinder objectFinder
Definition: ObjectPoseClient.h:107
Reader.h
armarx::navigation::server::Navigator::Config
Definition: Navigator.h:67
armarx::navigation::server::NavigationStack
Definition: NavigationStack.h:36
c
constexpr T c
Definition: UnscentedKalmanFilterTest.cpp:46
armarx::navigation::components::navigator::Component::stop
void stop(const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:436
armarx::navigation::server::Navigator
Definition: Navigator.h:63
armarx::ManagedIceObject::addPlugin
PluginT * addPlugin(const std::string prefix="", ParamsT &&... params)
Definition: ManagedIceObject.h:186
armarx::navigation::components::navigator::visualize
void visualize(const algorithms::Costmap &costmap, viz::Client &arviz, const std::string &name)
Definition: Component.cpp:567
MemoryParameterizationService.h
armarx::ObjectFinder::setLogObjectDiscoveryError
void setLogObjectDiscoveryError(bool logEnabled)
Definition: ObjectFinder.cpp:397
armarx::navigation
This file is part of ArmarX.
Definition: aron_conversions.cpp:25
armarx::navigation::algorithms::Costmap::toPositionGlobal
Position toPositionGlobal(const Index &index) const
Definition: Costmap.cpp:69
NavigationStackFactory.h
armarx::navigation::components::navigator::Component::updateMoveTo
void updateMoveTo(const std::vector< Eigen::Matrix4f > &waypoints, const std::string &navigationMode, const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:338
armarx::navigation::components::navigator::Component::scene
const core::Scene & scene() const
Definition: Component.cpp:492
armarx::navigation::components::navigator::Component::moveToLocation
void moveToLocation(const std::string &location, const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:387
ARMARX_CHECK
#define ARMARX_CHECK(expression)
Shortcut for ARMARX_CHECK_EXPRESSION.
Definition: ExpressionException.h:82
Clock.h
armarx::navigation::server::NavigationStack::localPlanner
local_planning::LocalPlannerPtr localPlanner
Definition: NavigationStack.h:39
events.h
armarx::navigation::components::navigator::Component
Definition: Component.h:87
armarx::navigation::components::navigator::Component::onDisconnectComponent
void onDisconnectComponent() override
Definition: Component.cpp:194
armarx::navigation::core::NavigationFrameNames
const simox::meta::EnumNames< NavigationFrame > NavigationFrameNames
Definition: types.h:48
Costmap.h
IceInternal::Handle
Definition: forward_declarations.h:8
armarx::navigation::server::PlatformControllerExecutor::Properties
Definition: PlatformControllerExecutor.h:34
armarx::GetHandledExceptionString
std::string GetHandledExceptionString()
Definition: Exception.cpp:165
ARMARX_TRACE
#define ARMARX_TRACE
Definition: trace.h:77
armarx::navigation::client::defrost
client::GlobalPlanningStrategy defrost(const client::detail::GlobalPlanningStrategy &strategy)
Definition: ice_conversions.cpp:21
armarx::navigation::components::navigator::Component::resume
void resume(const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:427
RemoteGui.h
Color
uint32_t Color
RGBA color.
Definition: color.h:8
armarx::navigation::server::Navigator::Config::stack
server::NavigationStack stack
Definition: Navigator.h:77
armarx::navigation::components::navigator::Component::stopAllImpl
void stopAllImpl(bool emitMemoryEvent)
Definition: Component.cpp:457
armarx::navigation::client::detail::Waypoints
sequence< Waypoint > Waypoints
Definition: NavigatorInterface.ice:57
armarx::navigation::components::navigator::Component::moveTo2
void moveTo2(const client::detail::Waypoints &waypoints, const std::string &navigationMode, const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:369
armarx::navigation::core::UserAbortTriggeredEvent
Event describing that the user aborted the current execution.
Definition: events.h:96
armarx::navigation::algorithms::Costmap::getGrid
const Grid & getGrid() const
Definition: Costmap.cpp:243
armarx::navigation::components::navigator::Component::moveTowards
void moveTowards(const Eigen::Vector3f &direction, const std::string &navigationMode, const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:402
armarx::navigation::server::Navigator::InjectedServices
Definition: Navigator.h:83
PlatformControllerExecutor.h
armarx::control::client::ComponentPluginUser::getControlComponentPlugin
ComponentPlugin & getControlComponentPlugin()
Definition: ComponentPlugin.cpp:68
armarx::navigation::server::Navigator::InjectedServices::executor
ExecutorInterface * executor
Definition: Navigator.h:85
armarx::navigation::core::Scene
Definition: types.h:60
MemoryIntrospector.h
Component.h
armarx::navigation::fac::NavigationStackFactory::create
static server::NavigationStack create(const aron::data::DictPtr &params, const core::Scene &scene, std::experimental::observer_ptr< viz::Client > arviz)
Definition: NavigationStackFactory.cpp:26
armarx::transform
auto transform(const Container< InputT, Alloc > &in, OutputT(*func)(InputT const &)) -> Container< OutputT, typename std::allocator_traits< Alloc >::template rebind_alloc< OutputT >>
Convenience function (with less typing) to transform a container of type InputT into the same contain...
Definition: algorithm.h:351
armarx::navigation::components::navigator::Component::initializeScene
bool initializeScene()
Definition: Component.cpp:233
MemoryPublisher.h
ExpressionException.h
Mesh.h
armarx::navigation::components::navigator::Component::moveTo
void moveTo(const std::vector< Eigen::Matrix4f > &waypoints, const std::string &navigationMode, const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:308
armarx::Component::getConfigIdentifier
std::string getConfigIdentifier()
Retrieve config identifier for this component as set in constructor.
Definition: Component.cpp:79
Decoupled.h
armarx::ComponentPropertyDefinitions
Default component property definition container.
Definition: Component.h:69
ARMARX_INFO
#define ARMARX_INFO
Definition: Logging.h:181
PropertyDefinitionContainer.h
armarx::navigation::components::navigator::Component::onConnectComponent
void onConnectComponent() override
Definition: Component.cpp:137
IceUtil::Handle< class PropertyDefinitionContainer >
LogSender.h
F
Definition: ExportDialogControllerTest.cpp:18
armarx::navigation::conv::to3D
std::vector< Eigen::Vector3f > to3D(const std::vector< Eigen::Vector2f > &v)
Definition: eigen.cpp:14
armarx::navigation::components::navigator::Component::Component
Component()
Definition: Component.cpp:108
ARMARX_CHECK_NULL
#define ARMARX_CHECK_NULL(ptr)
Definition: ExpressionException.h:212
armarx::core::time::Clock::Now
static DateTime Now()
Current time on the virtual clock.
Definition: Clock.cpp:93
distance
double distance(const Point &a, const Point &b)
Definition: point.hpp:95
armarx::navigation::components::navigator::Component::GetDefaultName
static std::string GetDefaultName()
Definition: Component.cpp:246
eigen.h
Logging.h
armarx::navigation::components::navigator::Component::~Component
~Component() override
armarx::ObjectPoseClientPluginUser::getClient
objpose::ObjectPoseClient getClient() const
Definition: ObjectPoseClientPlugin.cpp:70
ARMARX_WARNING
#define ARMARX_WARNING
Definition: Logging.h:193
armarx::viz::Client::layer
Layer layer(std::string const &name) const
Definition: Client.cpp:80
armarx::navigation::components::navigator::Component::isPaused
bool isPaused(const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:483
armarx::navigation::components::navigator::Component::getDefaultName
std::string getDefaultName() const override
Definition: Component.cpp:240
armarx::viz::Client
Definition: Client.h:117
armarx::navigation::components::navigator::Component::createConfig
void createConfig(const aron::data::dto::DictPtr &stackConfig, const std::string &callerId, const Ice::Current &c=Ice::emptyCurrent) override
Definition: Component.cpp:252
armarx::navigation::server::ArvizIntrospector
Definition: ArvizIntrospector.h:54
types.h
Navigator.h
armarx::navigation::server::MemoryParameterizationService
Definition: MemoryParameterizationService.h:38
armarx::navigation::components::navigator::ARMARX_REGISTER_COMPONENT_EXECUTABLE
ARMARX_REGISTER_COMPONENT_EXECUTABLE(Component, Component::GetDefaultName())
armarx::navigation::components::navigator
This file is part of ArmarX.
Definition: Component.cpp:83
armarx::navigation::algorithms::Costmap
Definition: Costmap.h:16
armarx::navigation::components::navigator::Component::onInitComponent
void onInitComponent() override
Definition: Component.cpp:132
armarx::navigation::components::navigator::Component::onExitComponent
void onExitComponent() override
Definition: Component.cpp:228
ArvizIntrospector.h
armarx::navigation::server::scene_provider::SceneProvider::InjectedServices
Definition: SceneProvider.h:70
SceneProvider.h