Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试使用 python 来调整模型,并尝试通过停用和激活 B&C 的一些启发式方法来改进它。为此,我正在寻求有关如何管理剪切启发式参数以及我在 Gurobi 中有哪些类型的帮助。
通常,您可以通过设置参数来影响切割和启发式方法。文档中有一个详尽的参数列表。例如,要禁用给定模型的切割生成和启发式方法,您可以这样做
import gurobipy as gp m = gp.Model() m.setParam(GRB.Param.cuts, 0) m.setParam(GRB.Param.heuristics, 0.0)