Quantcast

User Cut Callback being executed just once in every node (JuMP/CPLEX)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

User Cut Callback being executed just once in every node (JuMP/CPLEX)

Claudio Contardo
Hello,

I am experiencing the following issue when using user cut callbacks using CPLEX:

The callback is executed a single time at every node. Even if the callback succeeds at finding cuts, the solver does not call the separations again within the same node. Instead, CPLEX performs branching directly.

According to Pkg.status() I am using JuMP v0.14.0+ (master branch), CPLEX v0.1.7 (master branch).

When the solver is set to Gurobi, the callback gets called several times as expected while the separations keep finding cuts.

Is anyone capable of reproducing this issue?

Best regards,

Claudio

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: User Cut Callback being executed just once in every node (JuMP/CPLEX)

Joey Huchette-2

Hey Claudio,
I believe this is because we set the useraction_p parameter to CPX_CALLBACK_ABORT_CUT_LOOP here. I believe we chose this as the default since I noticed cycling-like behavior otherwise, but I can’t quite remember. You’re welcome to play around with other values (probably CPX_CALLBACK_DEFAULT); I’d be open to changing the default if the behavior makes sense.

-Joey


On Sat, Nov 5, 2016 at 6:53 PM, Claudio Contardo <[hidden email]> wrote:
Hello,

I am experiencing the following issue when using user cut callbacks using CPLEX:

The callback is executed a single time at every node. Even if the callback succeeds at finding cuts, the solver does not call the separations again within the same node. Instead, CPLEX performs branching directly.

According to Pkg.status() I am using JuMP v0.14.0+ (master branch), CPLEX v0.1.7 (master branch).

When the solver is set to Gurobi, the callback gets called several times as expected while the separations keep finding cuts.

Is anyone capable of reproducing this issue?

Best regards,

Claudio

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: User Cut Callback being executed just once in every node (JuMP/CPLEX)

Claudio Contardo
Thank you Joey,

I followed your suggestion and for some weird reason (jus as you predicted) the user callback eventually enters into an inifinite loop in the middle of the separation process.

Best regards,

Claudio

On Sunday, November 6, 2016 at 9:19:35 PM UTC-3, Joey Huchette wrote:

Hey Claudio,
I believe this is because we set the useraction_p parameter to CPX_CALLBACK_ABORT_CUT_LOOP <a href="https://github.com/JuliaOpt/CPLEX.jl/blob/f7b1864001b018954c53b09165613c28a65bf326/src/CplexSolverInterface.jl#L393" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FJuliaOpt%2FCPLEX.jl%2Fblob%2Ff7b1864001b018954c53b09165613c28a65bf326%2Fsrc%2FCplexSolverInterface.jl%23L393\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGLTDc82ZPTB6t7ZgXxFY6zpA0J3Q&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FJuliaOpt%2FCPLEX.jl%2Fblob%2Ff7b1864001b018954c53b09165613c28a65bf326%2Fsrc%2FCplexSolverInterface.jl%23L393\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGLTDc82ZPTB6t7ZgXxFY6zpA0J3Q&#39;;return true;">here. I believe we chose this as the default since I noticed cycling-like behavior otherwise, but I can’t quite remember. You’re welcome to play around with other values (probably CPX_CALLBACK_DEFAULT); I’d be open to changing the default if the behavior makes sense.

-Joey


On Sat, Nov 5, 2016 at 6:53 PM, Claudio Contardo <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="OlbFHPbXBgAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">ccon...@...> wrote:
Hello,

I am experiencing the following issue when using user cut callbacks using CPLEX:

The callback is executed a single time at every node. Even if the callback succeeds at finding cuts, the solver does not call the separations again within the same node. Instead, CPLEX performs branching directly.

According to Pkg.status() I am using JuMP v0.14.0+ (master branch), CPLEX v0.1.7 (master branch).

When the solver is set to Gurobi, the callback gets called several times as expected while the separations keep finding cuts.

Is anyone capable of reproducing this issue?

Best regards,

Claudio

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="OlbFHPbXBgAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">julia-opt+...@googlegroups.com.
Visit this group at <a href="https://groups.google.com/group/julia-opt" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/group/julia-opt&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/julia-opt&#39;;return true;">https://groups.google.com/group/julia-opt.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: User Cut Callback being executed just once in every node (JuMP/CPLEX)

Joey Huchette-2
Out of curiosity, why does it not suffice to enter the callback once per node? You can separate and add multiple cuts in a single "call" to the callback function.

-Joey

On Mon, Nov 7, 2016 at 12:34 PM, Claudio Contardo <[hidden email]> wrote:
Thank you Joey,

I followed your suggestion and for some weird reason (jus as you predicted) the user callback eventually enters into an inifinite loop in the middle of the separation process.

Best regards,

Claudio

On Sunday, November 6, 2016 at 9:19:35 PM UTC-3, Joey Huchette wrote:

Hey Claudio,
I believe this is because we set the useraction_p parameter to CPX_CALLBACK_ABORT_CUT_LOOP here. I believe we chose this as the default since I noticed cycling-like behavior otherwise, but I can’t quite remember. You’re welcome to play around with other values (probably CPX_CALLBACK_DEFAULT); I’d be open to changing the default if the behavior makes sense.

-Joey


On Sat, Nov 5, 2016 at 6:53 PM, Claudio Contardo <[hidden email]> wrote:
Hello,

I am experiencing the following issue when using user cut callbacks using CPLEX:

The callback is executed a single time at every node. Even if the callback succeeds at finding cuts, the solver does not call the separations again within the same node. Instead, CPLEX performs branching directly.

According to Pkg.status() I am using JuMP v0.14.0+ (master branch), CPLEX v0.1.7 (master branch).

When the solver is set to Gurobi, the callback gets called several times as expected while the separations keep finding cuts.

Is anyone capable of reproducing this issue?

Best regards,

Claudio

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: User Cut Callback being executed just once in every node (JuMP/CPLEX)

Claudio Contardo
My separation routines generate a few cuts each time. I need to reoptimize to see if I get to find more. Moreover, some of my separation routines are more time consuming than others and are thus separated last. I wanted to abort the separation call as soon as one of the first separations found anything, then reoptimize and proceed with the separation routines again (from the beginning). Currently, CPLEX either loops infinitely (using CPX_CALLBACK_DEFAULT) or I never get to execute the more time consuming (but eventually more powerful) separation routines (using CPX_CALLBACK_ABORT_CUT_LOOP).

Besides, I also tried Gurobi but I discovered another issue. Gurobi apparently has an internal parameter that decides on its own when to abort the cut callback and proceed instead to branching. Again, Gurobi sometimes decides to abort before I get the chance of running the more expensive separations.

I really need a callback that allows me to: 1) reoptimize every time I generate cuts; and 2) let me decide when to abort the cut callback (and of course 3) that does not cycle!)

Best,

Claudio
On Monday, November 7, 2016 at 3:05:05 PM UTC-3, Joey Huchette wrote:
Out of curiosity, why does it not suffice to enter the callback once per node? You can separate and add multiple cuts in a single "call" to the callback function.

-Joey

On Mon, Nov 7, 2016 at 12:34 PM, Claudio Contardo <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="xRtt6xoSBwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">ccon...@...> wrote:
Thank you Joey,

I followed your suggestion and for some weird reason (jus as you predicted) the user callback eventually enters into an inifinite loop in the middle of the separation process.

Best regards,

Claudio

On Sunday, November 6, 2016 at 9:19:35 PM UTC-3, Joey Huchette wrote:

Hey Claudio,
I believe this is because we set the useraction_p parameter to CPX_CALLBACK_ABORT_CUT_LOOP <a href="https://github.com/JuliaOpt/CPLEX.jl/blob/f7b1864001b018954c53b09165613c28a65bf326/src/CplexSolverInterface.jl#L393" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FJuliaOpt%2FCPLEX.jl%2Fblob%2Ff7b1864001b018954c53b09165613c28a65bf326%2Fsrc%2FCplexSolverInterface.jl%23L393\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGLTDc82ZPTB6t7ZgXxFY6zpA0J3Q&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2FJuliaOpt%2FCPLEX.jl%2Fblob%2Ff7b1864001b018954c53b09165613c28a65bf326%2Fsrc%2FCplexSolverInterface.jl%23L393\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGLTDc82ZPTB6t7ZgXxFY6zpA0J3Q&#39;;return true;">here. I believe we chose this as the default since I noticed cycling-like behavior otherwise, but I can’t quite remember. You’re welcome to play around with other values (probably CPX_CALLBACK_DEFAULT); I’d be open to changing the default if the behavior makes sense.

-Joey


On Sat, Nov 5, 2016 at 6:53 PM, Claudio Contardo <[hidden email]> wrote:
Hello,

I am experiencing the following issue when using user cut callbacks using CPLEX:

The callback is executed a single time at every node. Even if the callback succeeds at finding cuts, the solver does not call the separations again within the same node. Instead, CPLEX performs branching directly.

According to Pkg.status() I am using JuMP v0.14.0+ (master branch), CPLEX v0.1.7 (master branch).

When the solver is set to Gurobi, the callback gets called several times as expected while the separations keep finding cuts.

Is anyone capable of reproducing this issue?

Best regards,

Claudio

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at <a href="https://groups.google.com/group/julia-opt" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/group/julia-opt&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/julia-opt&#39;;return true;">https://groups.google.com/group/julia-opt.
For more options, visit <a href="https://groups.google.com/d/optout" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="xRtt6xoSBwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">julia-opt+...@googlegroups.com.
Visit this group at <a href="https://groups.google.com/group/julia-opt" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/group/julia-opt&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/julia-opt&#39;;return true;">https://groups.google.com/group/julia-opt.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: User Cut Callback being executed just once in every node (JuMP/CPLEX)

Miles Lubin

You should look into using SCIP then.


On Nov 7, 2016 1:21 PM, "Claudio Contardo" <[hidden email]> wrote:
My separation routines generate a few cuts each time. I need to reoptimize to see if I get to find more. Moreover, some of my separation routines are more time consuming than others and are thus separated last. I wanted to abort the separation call as soon as one of the first separations found anything, then reoptimize and proceed with the separation routines again (from the beginning). Currently, CPLEX either loops infinitely (using CPX_CALLBACK_DEFAULT) or I never get to execute the more time consuming (but eventually more powerful) separation routines (using CPX_CALLBACK_ABORT_CUT_LOOP).

Besides, I also tried Gurobi but I discovered another issue. Gurobi apparently has an internal parameter that decides on its own when to abort the cut callback and proceed instead to branching. Again, Gurobi sometimes decides to abort before I get the chance of running the more expensive separations.

I really need a callback that allows me to: 1) reoptimize every time I generate cuts; and 2) let me decide when to abort the cut callback (and of course 3) that does not cycle!)

Best,

Claudio
On Monday, November 7, 2016 at 3:05:05 PM UTC-3, Joey Huchette wrote:
Out of curiosity, why does it not suffice to enter the callback once per node? You can separate and add multiple cuts in a single "call" to the callback function.

-Joey

On Mon, Nov 7, 2016 at 12:34 PM, Claudio Contardo <[hidden email]> wrote:
Thank you Joey,

I followed your suggestion and for some weird reason (jus as you predicted) the user callback eventually enters into an inifinite loop in the middle of the separation process.

Best regards,

Claudio

On Sunday, November 6, 2016 at 9:19:35 PM UTC-3, Joey Huchette wrote:

Hey Claudio,
I believe this is because we set the useraction_p parameter to CPX_CALLBACK_ABORT_CUT_LOOP here. I believe we chose this as the default since I noticed cycling-like behavior otherwise, but I can’t quite remember. You’re welcome to play around with other values (probably CPX_CALLBACK_DEFAULT); I’d be open to changing the default if the behavior makes sense.

-Joey


On Sat, Nov 5, 2016 at 6:53 PM, Claudio Contardo <[hidden email]> wrote:
Hello,

I am experiencing the following issue when using user cut callbacks using CPLEX:

The callback is executed a single time at every node. Even if the callback succeeds at finding cuts, the solver does not call the separations again within the same node. Instead, CPLEX performs branching directly.

According to Pkg.status() I am using JuMP v0.14.0+ (master branch), CPLEX v0.1.7 (master branch).

When the solver is set to Gurobi, the callback gets called several times as expected while the separations keep finding cuts.

Is anyone capable of reproducing this issue?

Best regards,

Claudio

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: User Cut Callback being executed just once in every node (JuMP/CPLEX)

c.d. mclean

potentially of interest, and likely obvious:

   https://github.com/SCIP-Interfaces/SCIP.jl



--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.
Loading...