Skip to content

Minimize hidden employees

Hidden employees are employees that have to be borrowed from a different hospital unit. Shifts should only be assigned to them if otherwise a valid solution cannot be found, e.g., if there is a shortage on skilled employees.

For this purpose we have an objective to minimize the amout of hidden employees and another to minimize their working time.

!!! note The objective to minimize the amount of hidden employees is currently not in use by our implementation as we have a different mechanism in place for that.

Implemented using Google's OR Tools

src/cp/objectives/minimize_hidden_employee_count.py
    hidden_employee_work_vars.append(hidden_employee_is_used)

return cast(LinearExpr, sum(hidden_employee_work_vars)) * self._weight
src/cp/objectives/minimize_hidden_employees.py
    possible_hidden_employee_variables.append(possible_hidden_employee_variable)

return sum(possible_hidden_employee_variables) * self._weight