27#include <condition_variable>
33#include <RobotComponents/interface/components/MotionPlanning/Tasks/AdaptiveDynamicDomainInformedRRTStar/ManagerNode.h>
34#include <RobotComponents/interface/components/MotionPlanning/Tasks/AdaptiveDynamicDomainInformedRRTStar/Task.h>
60 public virtual TaskBase,
81 const cprs::ComputingPowerRequestStrategyBasePtr& planningComputingPowerRequestStrategy,
84 const std::string& taskName =
"ADDIRRTStarTask",
85 Ice::Long maximalPlanningTimeInSeconds = 300,
86 AdaptiveDynamicDomainParameters addParams = generateADDParamsFromDCDStepsize(0.01f),
89 float dcdStep = 0.01f,
90 Ice::Long batchSize = 10,
91 Ice::Long nodeCountDeltaForGoalConnectionTries = 50,
93 Ice::Long initialWorkerCount = 1,
94 Ice::Long maximalWorkerCount = std::numeric_limits<Ice::Long>::max());
103 getNthPath(Ice::Long n,
const Ice::Current& = Ice::emptyCurrent)
const override
109 getPath(
const Ice::Current& = Ice::emptyCurrent)
const override
118 PathWithCost
getBestPath(
const Ice::Current& = Ice::emptyCurrent)
const override;
122 Ice::Long
getPathCount(
const Ice::Current& = Ice::emptyCurrent)
const override;
128 const Ice::Current& = Ice::emptyCurrent)
const override;
132 PathWithCostSeq
getAllPathsWithCost(
const Ice::Current& = Ice::emptyCurrent)
const override;
138 void abortTask(
const Ice::Current& = Ice::emptyCurrent)
override;
145 void run(
const RemoteObjectNodePrxList& remoteNodes,
146 const Ice::Current& = Ice::emptyCurrent)
override;
152 void setPaths(
const PathWithCostSeq& newPathList,
153 const Ice::Current& = Ice::emptyCurrent)
override;
158 Ice::Long
getNodeCount(
const Ice::Current& = Ice::emptyCurrent)
const override;
161 void setMaxCpus(Ice::Int maxCpus,
const Ice::Current& = Ice::emptyCurrent)
override;
163 Ice::Int
getMaxCpus(
const Ice::Current& = Ice::emptyCurrent)
const override;
166 template <
class Base,
class Derived>
167 friend class ::armarx::GenericFactory;
Path getNthPath(Ice::Long n, const Ice::Current &=Ice::emptyCurrent) const override
PathWithCost getPathWithCost(const Ice::Current &=Ice::emptyCurrent) const override
Path getPath(const Ice::Current &=Ice::emptyCurrent) const override
The RemoteHandle class wrapps a ClientSideRemoteHandleControlBlock and can be used just as a Ice prox...
void setPaths(const PathWithCostSeq &newPathList, const Ice::Current &=Ice::emptyCurrent) override
Used by the manager to store its found paths.
PathWithCostSeq getAllPathsWithCost(const Ice::Current &=Ice::emptyCurrent) const override
Ice::Long getPathCount(const Ice::Current &=Ice::emptyCurrent) const override
PathWithCost getNthPathWithCost(Ice::Long index, const Ice::Current &=Ice::emptyCurrent) const override
Path getPath(const Ice::Current &=Ice::emptyCurrent) const override
RemoteHandle< ManagerNodeBasePrx > manager
The manager node.
Task(CSpaceBasePtr cspace, const cprs::ComputingPowerRequestStrategyBasePtr &planningComputingPowerRequestStrategy, VectorXf startCfg, VectorXf goalCfg, const std::string &taskName="ADDIRRTStarTask", Ice::Long maximalPlanningTimeInSeconds=300, AdaptiveDynamicDomainParameters addParams=generateADDParamsFromDCDStepsize(0.01f), float targetCost=0, float dcdStep=0.01f, Ice::Long batchSize=10, Ice::Long nodeCountDeltaForGoalConnectionTries=50, Ice::Long initialWorkerCount=1, Ice::Long maximalWorkerCount=std::numeric_limits< Ice::Long >::max())
Ctor.
PathWithCostSeq paths
All found paths.
std::condition_variable_any managerDone
CV used by the dispatcher thread to wait until planning is done.
std::recursive_mutex mutex
Mutex to protect internal structures.
void abortTask(const Ice::Current &=Ice::emptyCurrent) override
Aborts the task.
PathWithCost getBestPath(const Ice::Current &=Ice::emptyCurrent) const override
void setMaxCpus(Ice::Int maxCpus, const Ice::Current &=Ice::emptyCurrent) override
void checkParameters()
Checks for illegal parameters.
Task()
Ctor used by object factories.
Ice::Long cachedNodeCount
The cahced node count.
Ice::Long getNodeCount(const Ice::Current &=Ice::emptyCurrent) const override
Ice::Int getMaxCpus(const Ice::Current &=Ice::emptyCurrent) const override
void run(const RemoteObjectNodePrxList &remoteNodes, const Ice::Current &=Ice::emptyCurrent) override
Runs the task.
Path getNthPath(Ice::Long n, const Ice::Current &=Ice::emptyCurrent) const override
PathWithCost getPathWithCost(const Ice::Current &=Ice::emptyCurrent) const override
Implementation of the slice interface CPRSAwarePlanningTaskBase.
IceInternal::Handle< Task > TaskPtr
An ice handle for an addirrt* Task.
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< ADDIRRTStarTask > ADDIRRTStarTaskPtr
RemoteHandle< armarx::MotionPlanningMultiPathWithCostTaskControlInterfacePrx > ADDIRRTStarTaskHandle
addirrtstar::Task ADDIRRTStarTask