def solve_pddl(): domain_pddl = read_pddl('domain.pddl') problem_pddl = read_pddl('problem.pddl') plan, cost = solve_from_pddl(domain_pddl, problem_pddl) print('Plan:', plan) print('Cost:', cost)
def solve_pddl(): domain_pddl = read_pddl(__file__, 'domain0.pddl') problem_pddl = read_pddl(__file__, 'problem0.pddl') plan, cost = solve_from_pddl(domain_pddl, problem_pddl) solved = plan is not None print('Solved: {}'.format(solved)) print('Cost: {}'.format(cost)) print('Length: {}'.format(get_length(plan))) if not solved: return for i, action in enumerate(plan): print('{}) {}'.format(i + 1, ' '.join(map(str, action))))
def solve_pddl(): domain_pddl = read_pddl(__file__, 'domain0.pddl') problem_pddl = read_pddl(__file__, 'problem0.pddl') plan, cost = solve_from_pddl(domain_pddl, problem_pddl) dump_plan(plan, cost)
def solve_pddl(): plan, cost = solve_from_pddl(DOMAIN_PDDL, PROBLEM_PDDL) print('Plan:', plan) print('Cost:', cost)
def main(): # TODO: make a method that does this domain_pddl, problem_pddl = read_pddl_pair(__file__) plan, cost = solve_from_pddl(domain_pddl, problem_pddl) dump_plan(plan, cost)
def main(): plan, cost = solve_from_pddl(DOMAIN_PDDL, PROBLEM_PDDL, planner='dijkstra') dump_plan(plan, cost)
def main(): domain_pddl, problem_pddl = read_pddl_pair(__file__) plan, cost = solve_from_pddl(domain_pddl, problem_pddl) dump_plan(plan, cost)