Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exact Fractional Solver SegFaults #110

Open
Andful opened this issue Sep 16, 2024 · 5 comments
Open

Exact Fractional Solver SegFaults #110

Andful opened this issue Sep 16, 2024 · 5 comments

Comments

@Andful
Copy link

Andful commented Sep 16, 2024

Version:

SCIP version 10.0.0 [precision: 8 byte] [memory: block] [mode: optimized] [LP solver: Soplex 7.1.0] [GitHash: 820c627c95]
Copyright (c) 2002-2024 Zuse Institute Berlin (ZIB)

External libraries: 
  Readline 8.2         GNU library for command line editing (gnu.org/s/readline)
  Soplex 7.1.0         Linear Programming Solver developed at Zuse Institute Berlin (soplex.zib.de) [GitHash: 595bfac9]
  CppAD 20180000.0     Algorithmic Differentiation of C++ algorithms developed by B. Bell (github.com/coin-or/CppAD)
  SoPlex 7.1.0         exact Linear Programming Solver developed at Zuse Institute Berlin (soplex.zib.de) [GitHash: 595bfac9]
  ZLIB 1.2.11          General purpose compression library by J. Gailly and M. Adler (zlib.net)
  MPFR 4.1.0           GNU Multiple Precision Floating-Point Reliable Library (mpfr.org)
  GMP 6.3.0            GNU Multiple Precision Arithmetic Library developed by T. Granlund (gmplib.org)
  AMPL/MP 690e9e7      AMPL .nl file reader library (github.com/ampl/mp)
  PaPILO 2.2.1         parallel presolve for integer and linear optimization (github.com/scipopt/papilo) (built with TBB)
  Nauty 2.8.8          Computing Graph Automorphism Groups by Brendan D. McKay (users.cecs.anu.edu.au/~bdm/nauty)
  sassy 1.1            Symmetry preprocessor by Markus Anders (github.com/markusa4/sassy)

user parameter file <scip.set> not found - using default parameters


The formulation in question

formulation.lp (Uploaded as TXT because GitHub complains)

The formulation solves fine when not using exact fractional, but seg-faults when using the exact fractional solver.

@ambros-gleixner
Copy link
Member

Can you build in debug mode to see if an assert comes up? (And post the log file.)

@Andful
Copy link
Author

Andful commented Sep 17, 2024

I assume by log you mean the stdout and stderr

I got the logs with the commands:

bin/scip -c "read formulation.lp" -c "optimize" -c "quit" &> out_standard.log
bin/scip -c "set exact enabled TRUE" -c "read formulation.lp" -c "optimize" -c "quit" &> out_exact.log

out_standard.log
out_exact.log

The assertion error is:

scip: /home/andful/projects/scip/src/scip/tree.c:1953: SCIPnodeAddBoundinfer: Assertion `(boundtype == SCIP_BOUNDTYPE_LOWER && SCIPsetIsGT(set, newbound, oldlb)) || (boundtype == SCIP_BOUNDTYPE_LOWER && newbound > oldlb && newbound * oldlb <= 0.0) || (boundtype == SCIP_BOUNDTYPE_UPPER && SCIPsetIsLT(set, newbound, oldub)) || (boundtype == SCIP_BOUNDTYPE_UPPER && newbound < oldub && newbound * oldub <= 0.0)' failed.

@ambros-gleixner
Copy link
Member

Great, do you have experience to run this in a debugger and print the backtrace and the values in the assert (boundtype, newbound, oldlb)?

@Andful
Copy link
Author

Andful commented Sep 25, 2024

I get the following backtrace:

#0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>)
    at ./nptl/pthread_kill.c:44
#1  __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
#2  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6)
    at ./nptl/pthread_kill.c:89
#3  0x00007ffff764526e in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#4  0x00007ffff76288ff in __GI_abort () at ./stdlib/abort.c:79
#5  0x00007ffff762881b in __assert_fail_base (
    fmt=0x7ffff77d01e8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", 
    assertion=assertion@entry=0x5555567de140 "(boundtype == SCIP_BOUNDTYPE_LOWER && SCIPsetIsGT(set, newbound, oldlb)) || (boundtype == SCIP_BOUNDTYPE_LOWER && newbound > oldlb && newbound * oldlb <= 0.0) || (boundtype == SCIP_BOUNDTYPE_UPPER && "..., 
    file=file@entry=0x5555567dc660 "/home/andful/projects/scip/src/scip/tree.c", 
    line=line@entry=1917, 
    function=function@entry=0x5555567e31f0 <__PRETTY_FUNCTION__.113> "SCIPnodeAddBoundinfer")
    at ./assert/assert.c:94
#6  0x00007ffff763b507 in __assert_fail (
    assertion=0x5555567de140 "(boundtype == SCIP_BOUNDTYPE_LOWER && SCIPsetIsGT(set, newbound, oldlb)) || (boundtype == SCIP_BOUNDTYPE_LOWER && newbound > oldlb && newbound * oldlb <= 0.0) || (boundtype == SCIP_BOUNDTYPE_UPPER && "..., 
    file=0x5555567dc660 "/home/andful/projects/scip/src/scip/tree.c", line=1917, 
    function=0x5555567e31f0 <__PRETTY_FUNCTION__.113> "SCIPnodeAddBoundinfer")
    at ./assert/assert.c:103
#7  0x00005555561cd108 in SCIPnodeAddBoundinfer (node=0x55555a0a8078, blkmem=0x555556f5d7f0, 
    set=0x555556f5f8d0, stat=0x5555571c2c70, transprob=0x55555724ef10, 
    origprob=0x555556f6df30, tree=0x55555724ead0, reopt=0x0, lp=0x5555571cd500, 
    branchcand=0x5555571eb880, eventqueue=0x5555572ab0c0, cliquetable=0x0, 
    var=0x5555572be0d8, newbound=0, boundtype=SCIP_BOUNDTYPE_UPPER, infercons=0x0, 
    inferprop=0x0, inferinfo=0, probingchange=0)
    at /home/andful/projects/scip/src/scip/tree.c:1917
#8  0x00005555561cfc79 in SCIPnodeAddBoundchg (node=0x55555a0a8078, blkmem=0x555556f5d7f0, 
    set=0x555556f5f8d0, stat=0x5555571c2c70, transprob=0x55555724ef10, 
    origprob=0x555556f6df30, tree=0x55555724ead0, reopt=0x0, lp=0x5555571cd500, 
    branchcand=0x5555571eb880, eventqueue=0x5555572ab0c0, cliquetable=0x0, 
    var=0x5555572be0d8, newbound=0, boundtype=SCIP_BOUNDTYPE_UPPER, probingchange=0)
    at /home/andful/projects/scip/src/scip/tree.c:2488
#9  0x00005555561e0159 in SCIPtreeBranchVar (tree=0x55555724ead0, reopt=0x0, 
    blkmem=0x555556f5d7f0, set=0x555556f5f8d0, stat=0x5555571c2c70, 
    transprob=0x55555724ef10, origprob=0x555556f6df30, lp=0x5555571cd500, 
    branchcand=0x5555571eb880, eventqueue=0x5555572ab0c0, var=0x5555572be0d8, val=0, 
    downchild=0x0, eqchild=0x0, upchild=0x0)
    at /home/andful/projects/scip/src/scip/tree.c:6266
#10 0x0000555555d29201 in SCIPbranchExecPseudo (blkmem=0x555556f5d7f0, set=0x555556f5f8d0, 
    stat=0x5555571c2c70, transprob=0x55555724ef10, origprob=0x555556f6df30, 
    tree=0x55555724ead0, reopt=0x0, lp=0x5555571cd500, branchcand=0x5555571eb880, 
--Type <RET> for more, q to quit, c to continue without paging--c
    eventqueue=0x5555572ab0c0, cutoffbound=0, allowaddcons=1, result=0x7fffffffcc60)
    at /home/andful/projects/scip/src/scip/branch.c:2854
#11 0x000055555618e232 in solveNode (blkmem=0x555556f5d7f0, set=0x555556f5f8d0, 
    messagehdlr=0x555556f5aae0, stat=0x5555571c2c70, mem=0x555556f5b780, 
    origprob=0x555556f6df30, transprob=0x55555724ef10, primal=0x5555571ce630, 
    tree=0x55555724ead0, reopt=0x0, lp=0x5555571cd500, relaxation=0x55555723e9a0, 
    pricestore=0x55555726b1e0, sepastore=0x55555725b310, branchcand=0x5555571eb880, 
    cutpool=0x5555572770d0, delayedcutpool=0x555557277160, conflict=0x555556f6e7f0, 
    conflictstore=0x5555571cd2b0, eventfilter=0x555556fca780, eventqueue=0x5555572ab0c0, 
    cliquetable=0x55555724eeb0, cutoff=0x7fffffffcef4, postpone=0x7fffffffcef8, 
    unbounded=0x7fffffffcefc, infeasible=0x7fffffffcf00, restart=0x7fffffffd144, 
    afternodeheur=0x7fffffffcf08, stopped=0x7fffffffcf0c)
    at /home/andful/projects/scip/src/scip/solve.c:4748
#12 0x0000555556191122 in SCIPsolveCIP (blkmem=0x555556f5d7f0, set=0x555556f5f8d0, 
    messagehdlr=0x555556f5aae0, stat=0x5555571c2c70, mem=0x555556f5b780, 
    origprob=0x555556f6df30, transprob=0x55555724ef10, primal=0x5555571ce630, 
    tree=0x55555724ead0, reopt=0x0, lp=0x5555571cd500, relaxation=0x55555723e9a0, 
    pricestore=0x55555726b1e0, sepastore=0x55555725b310, cutpool=0x5555572770d0, 
    delayedcutpool=0x555557277160, branchcand=0x5555571eb880, conflict=0x555556f6e7f0, 
    conflictstore=0x5555571cd2b0, eventfilter=0x555556fca780, eventqueue=0x5555572ab0c0, 
    cliquetable=0x55555724eeb0, restart=0x7fffffffd144)
    at /home/andful/projects/scip/src/scip/solve.c:5316
#13 0x00005555560f5859 in SCIPsolve (scip=0x555556f5a9d0)
    at /home/andful/projects/scip/src/scip/scip_solve.c:2714
#14 0x00005555558bca7a in SCIPdialogExecOptimize (scip=0x555556f5a9d0, 
    dialog=0x555556f81ee0, dialoghdlr=0x555556f7ef90, nextdialog=0x7fffffffd300)
    at /home/andful/projects/scip/src/scip/dialog_default.c:2194
#15 0x0000555555dd1da7 in SCIPdialogExec (dialog=0x555556f81ee0, set=0x555556f5f8d0, 
    dialoghdlr=0x555556f7ef90, nextdialog=0x7fffffffd300)
    at /home/andful/projects/scip/src/scip/dialog.c:951
#16 0x0000555555dcff35 in SCIPdialoghdlrExec (dialoghdlr=0x555556f7ef90, set=0x555556f5f8d0)
    at /home/andful/projects/scip/src/scip/dialog.c:402
#17 0x0000555556099d55 in SCIPstartInteraction (scip=0x555556f5a9d0)
    at /home/andful/projects/scip/src/scip/scip_dialog.c:252
#18 0x0000555556141f6a in SCIPprocessShellArguments (scip=0x555556f5a9d0, argc=9, 
    argv=0x7fffffffd9d8, defaultsetname=0x55555664e004 "scip.set")
    at /home/andful/projects/scip/src/scip/scipshell.c:577
#19 0x0000555556142101 in SCIPrunShell (argc=9, argv=0x7fffffffd9d8, 
    defaultsetname=0x55555664e004 "scip.set")
    at /home/andful/projects/scip/src/scip/scipshell.c:633
#20 0x00005555555793cf in main (argc=9, argv=0x7fffffffd9d8)
    at /home/andful/projects/scip/src/main.c:71

and when using select-frame 7 and then info locals I get:

infervar = 0x5555ffffffff
inferboundtype = (SCIP_BOUNDTYPE_UPPER | unknown: 0x5554)
oldlb = -1e+20
oldub = 0
oldbound = 4.6355720136372173e-310
useglobal = 0
__PRETTY_FUNCTION__ = "SCIPnodeAddBoundinfer"
_restat_ = <optimized out>
_restat_ = <optimized out>
_restat_ = <optimized out>
_restat_ = <optimized out>
_restat_ = <optimized out>
_restat_ = <optimized out>
_restat_ = <optimized out>

I assume the values are:

  • boundtype = SCIP_BOUNDTYPE_UPPER
  • newbound = 0
  • oldlb = -1e+20

@Andful
Copy link
Author

Andful commented Sep 25, 2024

I guess it is failing because oldub is 0 and newbound is 0

And it is asserted that newbound < oldub

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants