Multiprocessing produce different results in each run.
ユーザーの入力を待っています。I used the following code for multiprocessing, but it gives different results in each run. Am I doing something wrong?
import multiprocessing as mp
import gurobipy as gp
def solve_model(input_data):
with gp.Env() as env, gp.Model(env=env) as model:
#read model from LP file
model.optimize()
# retrieve data from model
if __name__ == '__main__':
with mp.Pool() as pool:
pool.map(solve_model, [input_data1, input_data2, input_data3]
0
-
正式なコメント
This post is more than three years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum. Or why not try our AI Gurobot?. -
Hi Sanjeev,
Could you please try posting a minimal reproducible example (MRE)?
Best regards,
Jaromił0
投稿コメントは受け付けていません。
コメント
2件のコメント