StructJuMP / StructJuMP.jl

A block-structured optimization framework for JuMP
Other
54 stars 19 forks source link

Segmentation fault with PIPS-NLP #26

Closed adowling2 closed 4 years ago

adowling2 commented 8 years ago

I put together a simple energy system operation optimization problem example that uses StructJuMP (both DSP and PIPS-NLP): https://github.com/zavalab/JuliaBox/tree/master/StructJuMP_examples

Unfortunately, I get the following error with PIPS-NLP:

signal (11): Segmentation fault
str_prob_info_wrapper at /opt/julia-0.4.5/share/julia/site/v0.4/StructJuMPSolverInterface/src/pips_parallel_cfunc.jl:221
jlcapi_str_prob_info_wrapper_22314 at  (unknown line)
_ZN15StructJuMPInput13get_prob_infoEi at /opt/PIPS/build_pips/PIPS-NLP/libparpipsnlp.so (unknown line)
unknown function (ip: 0x7fffefef7100)
unknown function (ip: (nil))
Segmentation fault

Usage:

include("energy_system_setup.jl")
include("energy_system_pips.jl")
adowling2 commented 8 years ago

I get a slight different error message with PIPS-NLP serial:

signal (11): Segmentation fault
_ZN15NlpInfoCallBack17_get_matrices_mapEiiiiiiPiS0_PdS0_S0_S1_S0_S0_S1_ at /opt/PIPS/build_pips/PIPS-NLP/libpipsnlp.so (unknown line)
PipsNlpSolve at /opt/PIPS/build_pips/PIPS-NLP/libpipsnlp.so (unknown line)
solveProblem at /opt/julia-0.4.5/share/julia/site/v0.4/StructJuMPSolverInterface/src/pips_serial_cfunc.jl:205
structJuMPSolve at /opt/julia-0.4.5/share/julia/site/v0.4/StructJuMPSolverInterface/src/pips_serial.jl:368
jlcall___structJuMPSolve#3___22145 at  (unknown line)
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
julia_structJuMPSolve_22144 at  (unknown line)
jlcall_structJuMPSolve_22144 at  (unknown line)
sj_solve at /opt/julia-0.4.5/share/julia/site/v0.4/StructJuMPSolverInterface/src/StructJuMPSolverInterface.jl:52
jlcall___sj_solve#0___22141 at  (unknown line)
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
julia_sj_solve_22140 at  (unknown line)
solve at /opt/julia-0.4.5/share/julia/site/v0.4/JuMP/src/solvers.jl:114
jlcall___solve#2___22130 at  (unknown line)
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
julia_solve_22129 at  (unknown line)
solve_with_PIPS at /home/adowling2/git/zavalab/JuliaDemos/StructJuMP/energy_system_pips.jl:9
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
unknown function (ip: 0x7f7428358663)
unknown function (ip: 0x7f74283579f9)
unknown function (ip: 0x7f742835775c)
unknown function (ip: 0x7f7428358cf1)
unknown function (ip: 0x7f742835912d)
unknown function (ip: 0x7f742836d2c7)
unknown function (ip: 0x7f742836db8c)
jl_load at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
include at ./boot.jl:261
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
include_from_node1 at ./loading.jl:320
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
unknown function (ip: 0x7f7428358663)
unknown function (ip: 0x7f74283579f9)
unknown function (ip: 0x7f742836cebc)
unknown function (ip: 0x7f742836cf33)
jl_toplevel_eval_in at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
eval_user_input at REPL.jl:62
jlcall_eval_user_input_21142 at  (unknown line)
jl_apply_generic at /opt/julia-0.4.5/bin/../lib/julia/libjulia.so (unknown line)
anonymous at REPL.jl:92
unknown function (ip: 0x7f742835e8f4)
unknown function (ip: (nil))
Segmentation fault

This example runs fine with Ipopt via StructJuMP. I also have a flattened version of the model, which when solved with Gurobi, confirms the solution from IPOPT.

joehuchette commented 8 years ago

cc @fqiang, this looks like an issue in StructJuMPSolverInterface

fqiang commented 8 years ago

@adowling2 Thanks for letting us know the issue. @joehuchette It is a bug in the PIPS-NLP interface code. The upcoming PR#31 should be able fix the parallel PIPS-NLP solver problem. I will look more for the serial PIPS-NLP issue.

github-actions[bot] commented 4 years ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days