| 121 | ####################################################### |
| 122 | |
| 123 | def create_simplified_problem(problem, use_actions=False, use_streams=False, new_goal=None): |
| 124 | # TODO: check whether goal is a conjunction |
| 125 | domain_pddl, constant_map, stream_pddl, stream_map, init, goal_parts = problem |
| 126 | if not use_streams: |
| 127 | stream_pddl = None |
| 128 | if new_goal is None: |
| 129 | new_goal = goal_parts |
| 130 | domain = parse_domain(domain_pddl) # TODO: Constant map value @base not mentioned in domain :constants |
| 131 | if not use_actions: |
| 132 | domain.actions[:] = [] # No actions |
| 133 | return PDDLProblem(domain, constant_map, stream_pddl, stream_map, init, new_goal) |
| 134 | |
| 135 | |
| 136 | def test_init_goal(problem, **kwargs): |