If you don't want to use the default parameter values when solving your models, you can pass in custom values using the options field.
The example below shows how to override all ten configurable parameters with non-default values. If you leave out any of these, the default value will be used for that parameter. You can also omit the entire options field to use all default settings.
options = {
'max_time_seconds': 300, # Max run time
'mip_gap_percentage': 0.01, # Relative optimality gap
'mip_gap_absolute': 1e-10, # Absolute optimality gap
'presolve': 'on', # Presolver (on/off)
'node_count': 1 # Processing power
'tol_primal_feasibility': 1e-7, # Primal feasibility tolerance
'tol_dual_feasibility': 1e-10, # Dual feasibility tolerance
'tol_integer': 1e-6, # Integral tolerance
'cut_strategy': 'normal', # Cut strategy
'heuristic_strategy': 'normal', # Heuristics strategy
'scaling': 'equilibrate' # Scaling
}
results = solver.solve(model, options=options)
Comments
0 comments
Please sign in to leave a comment.