Skip to content

Commit

Permalink
add memout
Browse files Browse the repository at this point in the history
  • Loading branch information
ElisaTosello committed Mar 26, 2024
1 parent 15058a8 commit 7c2f46c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion unified_planning/engines/mixins/oneshot_planner.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ def solve(
problem: "up.model.AbstractProblem",
heuristic: Optional[Callable[["up.model.state.State"], Optional[float]]] = None,
timeout: Optional[float] = None,
memout: Optional[float] = None,
output_stream: Optional[IO[str]] = None,
) -> "up.engines.results.PlanGenerationResult":
"""
Expand Down Expand Up @@ -77,14 +78,15 @@ def solve(
if not problem_kind.has_quality_metrics() and self.optimality_metric_required:
msg = f"The problem has no quality metrics but the engine is required to be optimal!"
raise up.exceptions.UPUsageError(msg)
return self._solve(problem, heuristic, timeout, output_stream)
return self._solve(problem, heuristic, timeout, memout, output_stream)

@abstractmethod
def _solve(
self,
problem: "up.model.AbstractProblem",
heuristic: Optional[Callable[["up.model.state.State"], Optional[float]]] = None,
timeout: Optional[float] = None,
memout: Optional[float] = None,
output_stream: Optional[IO[str]] = None,
) -> "up.engines.results.PlanGenerationResult":
"""Method called by the OneshotPlannerMixin.solve method."""
Expand Down

0 comments on commit 7c2f46c

Please sign in to comment.