diff --git a/linopy/solvers.py b/linopy/solvers.py index 70ace0ce..987c7b70 100644 --- a/linopy/solvers.py +++ b/linopy/solvers.py @@ -294,7 +294,7 @@ def __getattr__(self, attr: str) -> Any: gurobipy = _LazyModule("gurobipy") # type: ignore[assignment] -highspy = _LazyModule("highspy") +highspy = _LazyModule("highspy") # type: ignore[assignment] scip = _LazyModule("pyscipopt") cplex = _LazyModule("cplex") knitro = _LazyModule("knitro") @@ -1656,7 +1656,7 @@ def _build_solver_model( int_mask = (vtypes == "B") | (vtypes == "I") | (vtypes == "S") labels = np.arange(len(vtypes))[int_mask] integrality = np.array( - [integrality_map[v] for v in vtypes[int_mask]], dtype=np.int32 + [integrality_map[v] for v in vtypes[int_mask]], dtype=np.uint8 ) h.changeColsIntegrality(len(labels), labels, integrality)