Parallel starting from array of JuMP models


#1

Hello,

I am writing an algorithm that receives an array of JuMP models that need to be solved in parallel. I’ve read the recommendations on this forum to just send the data to the worker to build and solve the model. However, If I don’t have access to the function or just received an array of models, what would be the correct process?. I must also mention that this solution is going to be iterative.

I am not sure on how to use the different tools. I believe that If I use pmap, the model will be moved to the worker at each iteration. Should I use @spawn or something like that?.

thanks!


#2

@spawnat and remotecall let you choose the worker that gets each model, so you could manually ensure it’s the same process each time via mod1(idx in array,length(array)).

Dagger may be worth a look: