labscheduler.solvers.cp_solver module¶
A solver implementation using google OR-tools to model and solve the JSSP as a constraint program(CP)
- class labscheduler.solvers.cp_solver.CPSolver[source]¶
Bases:
JSSPSolver- _abc_impl = <_abc._abc_data object>¶
- compute_schedule(inst: JSSP, time_limit: float, offset: float, **kwargs) tuple[dict[str, ScheduledAssignment] | None, SolutionQuality][source]¶
Tries to compute a schedule for the given JSSP instance. Depending on the algorithm there might be no guaranty a solution is found. :param inst: The Problem instance :param time_limit: Maximum computation time(in seconds) the solver is allowed :param offset: Minimum time(in seconds) between call of the function and start time scheduled for any operation :param kwargs: Optional arguments custom to a solver :return: A valid schedule or None
- static get_algorithm_info() AlgorithmInfo[source]¶
Every algorithm should provide this basic information about itself :return: A typing.NamedTuple containing name, optimality, success guaranty and recommended maximum problem size