Loading...
Searching...
No Matches
ParallelPlan.cpp
79ompl::base::PlannerStatus ompl::tools::ParallelPlan::solve(double solveTime, std::size_t minSolCount,
82 return solve(base::timedPlannerTerminationCondition(solveTime, std::min(solveTime / 100.0, 0.1)), minSolCount,
86ompl::base::PlannerStatus ompl::tools::ParallelPlan::solve(const base::PlannerTerminationCondition &ptc, bool hybridize)
160 OMPL_DEBUG("ParallelPlan.solveOne: Solution found by %s in %lf seconds", planner->getName().c_str(), duration);
169void ompl::tools::ParallelPlan::solveMore(base::Planner *planner, std::size_t minSolCount, std::size_t maxSolCount,
187 OMPL_DEBUG("ParallelPlan.solveMore: Solution found by %s in %lf seconds", planner->getName().c_str(), duration);
195 attempts += phybrid_->recordPath(std::static_pointer_cast<geometric::PathGeometric>(path.path_), false);
201 OMPL_DEBUG("ParallelPlan.solveMore: Spent %f seconds hybridizing %u solution paths (attempted %u connections "
Encapsulate a termination condition for a motion planner. Planners will call operator() to decide whe...
Definition PlannerTerminationCondition.h:64
void terminate() const
Notify that the condition for termination should become true, regardless of what eval() returns....
Definition PlannerTerminationCondition.cpp:172
void addPlannerAllocator(const base::PlannerAllocator &pa)
Add a planner allocator to use.
Definition ParallelPlan.cpp:57
ParallelPlan(const base::ProblemDefinitionPtr &pdef)
Create an instance for a specified space information.
Definition ParallelPlan.cpp:41
void solveMore(base::Planner *planner, std::size_t minSolCount, std::size_t maxSolCount, const base::PlannerTerminationCondition *ptc)
Run the planner and collect the solutions. This function is only called if hybridize_ is true.
Definition ParallelPlan.cpp:169
void solveOne(base::Planner *planner, std::size_t minSolCount, const base::PlannerTerminationCondition *ptc)
Run the planner and call ompl::base::PlannerTerminationCondition::terminate() for the other planners ...
Definition ParallelPlan.cpp:144
base::PlannerStatus solve(double solveTime, bool hybridize=true)
Call Planner::solve() for all planners, in parallel, each planner running for at most solveTime secon...
Definition ParallelPlan.cpp:74
geometric::PathHybridizationPtr phybrid_
The instance of the class that performs path hybridization.
Definition ParallelPlan.h:153
void clearHybridizationPaths()
Clear the set of paths recorded for hybrididzation.
Definition ParallelPlan.cpp:69
std::vector< base::PlannerPtr > planners_
The set of planners to be used.
Definition ParallelPlan.h:150
std::function< PlannerPtr(const SpaceInformationPtr &)> PlannerAllocator
Definition of a function that can allocate a planner.
Definition Planner.h:437
PlannerTerminationCondition timedPlannerTerminationCondition(double duration)
Return a termination condition that will become true duration seconds in the future (wall-time)
Definition PlannerTerminationCondition.cpp:216
This namespace contains code that is specific to planning under geometric constraints.
Definition GeneticSearch.h:48
duration seconds(double sec)
Return the time duration representing a given number of seconds.
Definition Time.h:64
STL namespace.
A class to store the exit status of Planner::solve()
Definition PlannerStatus.h:49