Originally posted by: TalRaviv
Thanks. I am setting my model as follow:
model.parameters.parallel.set(-1) # opportunistic parallel search mode
model.parameters.threads.set(4)
Indeed when cplex starts is says
MIP search method: traditional branch-and-cut.
Parallel mode: opportunistic, using up to 4 threads.
My callback functions seem to be thread safe as they only read shared data and add cuts and lazy constraints but otherwise never write anything to global variables.
The model creates hundreds of nodes and has most of them open at some point and still my cpu usage is around 25% on a four cores machine.
Can I find a somewhere a python sample code that implements branch and cut with cplex API and supposed to be multithreads?
Any additional ideas?
#CPLEXOptimizers#DecisionOptimization