BILP to BQM

Hello,

I'm trying to convert a BILP to a BQM.

I generate my BILP using c, S, b values, I can solve the BILP using solve_bruteforce and it works fine. Now, I want to tranform it as a BQM to solve larger problems, so I translate it to QUBO using Q=my_bilp.to_qubo(), then I translate it to BQM using BinaryQuadraticModel.from_qubo(Q), but an exception is raised because some of the Q dict keys are 0 or 1 tuple length (but it expects tuples of length 2).

 

What is the best way to solve large BILP problems ?

 

Thank you very much.

0

Comments

3 comments
  • Hello,

    Are you able to provide a QUBO or minimal code example that reproduces the issue?

    The complete error message or stack trace is also an important tool to understand what is happening.

    It's not clear what the outcome will be at this point, but it will at least help to understand the error you are seeing.

    Thanks for reaching out and for working with us to look into this issue further.

    0
    Comment actions Permalink
  • Hi David,

    Thank you for your repply.

    Of course, here is a notebook showing the error:

    https://github.com/JulienMellaerts/bilptobqm/blob/main/BILP%20to%20BQM.ipynb

    0
    Comment actions Permalink
  • Hello,

    Taking a quick look at the QUBO formulation, the linear term keys are of the form (0,) or (4,) when they should be of the form (0,0) or (4,4). 
    It's a small detail, but they would not be read in properly.

    Please let us know if this resolves your issue and if you have any further questions.

    0
    Comment actions Permalink

Please sign in to leave a comment.

Didn't find what you were looking for?

New post