def __init__(self, space, type=None, **options): """Initializes a plan with a given CSpace and a given type. Optionally, planner options can be set via keyword arguments. Valid values for type are: * 'prm': the Probabilistic Roadmap algorithm * 'rrt': the Rapidly Exploring Random Trees algorithm * 'sbl': the Single-Query Bidirectional Lazy planner * 'sblprt': the probabilistic roadmap of trees (PRT) algorithm with SBL as the inter-root planner. * 'rrt*': the RRT* algorithm for optimal motion planning * 'prm*': the PRM* algorithm for optimal motion planning * 'lazyprm*': the Lazy-PRM* algorithm for optimal motion planning * 'lazyrrg*': the Lazy-RRG* algorithm for optimal motion planning * 'fmm': the fast marching method algorithm for resolution-complete optimal motion planning * 'fmm*': an anytime fast marching method algorithm for optimal motion planning (this list may be out-of-date; the most current documentation is listed in src/motionplanning.h) """ if space.cspace is None: space.setup() if type != None: motionplanning.setPlanType(type) if len(options) > 0: MotionPlan.setOptions(**options) self.space = space self.planOptions = motionplanning.getPlanJSONString() self.planner = motionplanning.PlannerInterface(space.cspace) self.edgeCost = None self.terminalCost = None
def __init__(self, space, type=None): """Initializes a plan with a given CSpace and a given type. Valid values for type are: - prm: the Probabilistic Roadmap algorithm - rrt: the Rapidly Exploring Random Trees algorithm - sbl: the Single-Query Bidirectional Lazy planner - sblprt: the probabilistic roadmap of trees (PRT) algorithm with SBL as the inter-root planner. - rrt*: the RRT* algorithm for optimal motion planning - prm*: the PRM* algorithm for optimal motion planning - lazyprm*: the Lazy-PRM* algorithm for optimal motion planning - lazyrrg*: the Lazy-RRG* algorithm for optimal motion planning - fmm: the fast marching method algorithm for resolution-complete optimal motion planning - fmm*: an anytime fast marching method algorithm for optimal motion planning (this list may be out-of-date; the most current documentation is listed in motionplanning.h) """ if space.cspace == None: space.setup() if type != None: motionplanning.setPlanType(type) self.planner = motionplanning.PlannerInterface(space.cspace)