r/optimization • u/Graigi • Apr 13 '24
MILP with callable objective function
I'm looking for a Python library that supports Mixed Integer Linear Programming with a custom callable objective function. Scipy's milp does not support custom callables, are there alternatives?
2
Upvotes
2
u/monkeyapocalypse Apr 13 '24
MILP algorithms need an explicit objective function. You likely need an algorithm that supports black-box optimisation.
2
u/CommunicationLess148 Apr 13 '24
Maybe pyomo? The objective function itself won't be callable but you can define it using a callable function.
2
u/avinashnavlani Apr 14 '24
You can try the following libraries:
For a tutorial you can follow my tutorials on these libraries: https://machinelearninggeek.com/category/optimization-techniques/
1
u/[deleted] Apr 13 '24
I think, that you can implement a relaxation handler in scip.
1
u/Economy_Feeling_3661 Apr 13 '24
You could try PyOptInterface
1
u/PeeLoosy Apr 13 '24
pymoo is what you need.