coin-or / CyLP

A Python interface to CLP, CBC, and CGL to solve LPs and MIPs.
Other
182 stars 69 forks source link

test_MIP.py Error #168

Open xueno6 opened 2 years ago

xueno6 commented 2 years ago

New to cylp, I install cylp by pip and run the file CyLP/cylp/tests/test_MIP.py

But python returns with error: " cbcModel.branchAndBound() AttributeError: 'cylp.cy.CyCbcModel.CyCbcModel' object has no attribute 'branchAndBound' " I hope to find a solution for this, thanks so much!

tkralphs commented 2 years ago

Could you say how you installed Cbc and what version you installed?

As for the failure, it's possible that some of the tests are broken. Can you successfully run the example code in the README? I have seen that error before, but I cannot recall exactly what caused it at the moment.

xueno6 commented 2 years ago

Could you say how you installed Cbc and what version you installed?

As for the failure, it's possible that some of the tests are broken. Can you successfully run the example code in the README? I have seen that error before, but I cannot recall exactly what caused it at the moment.

The code in the README can be conducted without error. My system is Win10, so as I see the README says "On Windows, a binary wheel is available and it is not necessary to install Cbc. Just do: pip install cylp" I did not install Cbc yet.

tkralphs commented 2 years ago

Ah, I see. So then what is the Python version so I can try to replicate?