How can limit 'Thread count' instead of using 'all available processors'?

Answered

Comments

2 comments

  • Eli Towle

    Hi Kamal,

    This can be done as follows:

    optimizer = SolverFactory('gurobi')
    optimizer.options['threads'] = 1

    For more information about passing options to solvers, see the Pyomo documentation on the topic. I hope this helps!

    Eli

    1
    Comment actions Permalink
  • Kamal Chowdhury

    Hi Eli,

    Thank you for the nice simple solution!

    Best,

    Kamal

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk