how to provide an initial solution in SCIP?

1,852 views
Skip to first unread message

dopejams chan

unread,
May 11, 2021, 6:25:21 AM5/11/21
to or-tools-discuss
Hi,I have met a problem about SCIP recently.
In cp-sat,i provide an initial solution by 'hint'.
How can I add in SCIP?

Xiang Chen

unread,
May 11, 2021, 8:58:14 AM5/11/21
to or-tools...@googlegroups.com
Use the solver.SetHint(variables, values) method

--
You received this message because you are subscribed to the Google Groups "or-tools-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to or-tools-discu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/or-tools-discuss/37d2077d-da30-4b11-ae10-7de37bc2c354n%40googlegroups.com.

dopejams chan

unread,
May 11, 2021, 10:33:04 PM5/11/21
to or-tools-discuss
hi, I have used the function SetHint in CP-SAT  .
But it doesn't seem to be available in SCIP.  

Mizux Seiha

unread,
May 12, 2021, 4:00:39 AM5/12/21
to or-tools-discuss

dopejams chan

unread,
May 12, 2021, 5:05:29 AM5/12/21
to or-tools-discuss
Hi, Mizux:
I have used SetHint() to provide a feasible solution,.However ,the  SCIP returns that can't find a solution.And this is a model that I can solve using CP-SAT.
https://groups.google.com/g/or-tools-discuss/c/-PYyjmyrNIk/m/rTttASSFAgAJ
I think I have the same problem as him. How to solve it?

dopejams chan

unread,
May 12, 2021, 6:01:26 AM5/12/21
to or-tools-discuss
I have checked the SCIP's logs.
It said that 'WARNING: ignore partial solution (0) because unknown rate is too large (0.997967 > 0.85)',but the values i gave is Int.
What is unknown rate?

Laurent Perron

unread,
May 12, 2021, 7:00:56 AM5/12/21
to or-tools-discuss
Dunno. This is a SCIP warning :-)
Laurent Perron | Operations Research | lpe...@google.com | (33) 1 42 68 53 00



Mizux Seiha

unread,
May 12, 2021, 7:33:51 AM5/12/21
to or-tools-discuss

dopejams chan

unread,
May 12, 2021, 12:06:01 PM5/12/21
to or-tools-discuss
Thanks Mizux. 
However, it still can't give a feasible solution when I used SetHint().
The log is 'all 5 solutions given by solution candidate storage are infeasible
WARNING: LP solver reached time limit, but SCIP time limit is not exceeded yet; you might consider switching the clock type of SCIP
completion of a partial solution failed (time limit exceeded)'.Why?

dopejams chan

unread,
May 13, 2021, 1:41:53 AM5/13/21
to or-tools-discuss

dopejams chan

unread,
May 13, 2021, 2:18:05 AM5/13/21
to or-tools-discuss
I have solved the problem.

And the reason why it's wrong is that my decision variable is two dimensional.I didn't turn it into a one-dimensional array and put it in SetHint.

Thank you very much for your valuable suggestions!!!


Reply all
Reply to author
Forward
0 new messages