Skip to main content

additional argument in callback function



1 comment

  • Marika Karbstein
    Gurobi Staff Gurobi Staff

    I think you are looking for the following, see the Callback documentation:

    If you would like to pass data to your callback function, you can do so through the Model object. For example, if your program includes the statement model._value = 1 before the optimization begins, then your callback function can query the value of model._value. Note that the name of the user data field must begin with an underscore.


Please sign in to leave a comment.