-
Notifications
You must be signed in to change notification settings - Fork 9
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
Issue with Offgridders Setup: Solver (cbc) Returned Non-Zero Return Code (1) #175
Comments
Hi @IlariaDelF! Thank you for the error messages, now I know what your problem is. It is a dependency-Problem, but luckily only with the cbc solver. Meaning at one part of the code. Two ways to go about it:
And remove following lines (I hope this will activate the default settings of the cbc solver): offgridders/src/G1_oemof_create_model.py Lines 543 to 545 in 9095014
|
Hi @smartie2076 ! Error: cbc 2.10.10: invalid option '-printingOptions' |
|
Hi, Despite I did set to "True" one of the cases. I then went back to my project's input excels and tried to set to True also a second case (even if I'm only interested in the pv-diesel-storage-mg case. Here I got back the same cbc error of -ratioGap. |
Hi @IlariaDelF ! I just did a clean reinstall with Offgridders, using the `requirements.txt` of the current release. I had to fix `numpy==1.19.5` to avoid an error, and used pandas==0.25.3. With the `cbc.exe` I still have on my computer, the simulation runs through without a problem using the test data (`python Offgridders.py ./inputs/test_input_template.xlsx`).
Maybe the CBC version really is the problem here. Can you check your CBC version? I did so by double clicking on my cbc file in the file explorer. This opens a terminal with:
```
Welcome to the CBC MILP Solver
Version: 2.10.5
Build Date: Nov 24 2021
```
Or did you install cbc with this?
```
python -m pip install amplpy –upgrade
python -m amplpy.modules install cbc
```
I was able to recreate your issue regarding `-ratioGap` by downloading the cbc executable from https://ampl.com/products/solvers/open-source-solvers/#cbc (version “20240724”). I also have the problem of `-printingOptions` now. I tried for a couple of hours now but could not figure out how to fix this.
Maybe you can find the old cbc solver version that I use?
|
Hi @smartie2076! Thank you so much for the help! I managed to make it run with my site data :) |
Dear all, I have been trying to run Offgridders with the following setup: Windows 10 64bit ...and also encountered problems with the cbc solver most likely related to its version: The oldest version of a directly usable cbc.exe I found was 2.10.6 available here: There are other versions available here: It did not manage to find a working cbc solver, but an older version (2.10.3) I had on my computer works perfectly fine for the test_input_template.xlsx Would it be possible to simply add a compatible cbc.exe to this repository? All the best! |
Hello Offgridders Team,
I'm currently setting up and running simulations with Offgridders, but I've encountered an issue related to the CBC solver. The solver returns a non-zero return code (1) with the error message:
ERROR: Solver (cbc) returned non-zero return code (1)
ERROR: Solver log:
Error: cbc 2.10.10: invalid option '-ratioGap'
The simulation initiates but fails when the CBC solver is called, with the error message mentioned above.
System Details:
Operating System: Windows 10
Offgridders Version: I'm not able to see it from the Offgridders.py or setup.py
Python Version: 3.6 (via Miniconda) (But I also tried with Python 3.7 and got the same error)
Environment: Created using pip in a Conda virtual environment
Installed Packages:
ampl-module-base==20240606
ampl-module-cbc==20240529
amplpy==0.14.0
ampltools==0.7.5
appdirs==1.4.4
blinker==1.5
certifi==2021.5.30
charset-normalizer==2.0.12
cycler==0.11.0
decorator==4.4.2
dill==0.3.4
future @ file:///D:/bld/future_1610147365175/work
idna==3.7
kiwisolver==1.3.1
matplotlib==3.0.0
networkx==2.5.1
nose==1.3.7
numpy==1.19.5
oemof.network==0.4.0rc0
oemof.solph==0.4.1
oemof.tools==0.4.0
Offgridders @ file:///C:/Users/Ilaria/offgridders
pandas==0.23.4
ply==3.11
Pyomo==5.7
pyparsing==3.1.2
python-dateutil==2.9.0.post0
pytz==2024.1
PyUtilib==6.0.0
requests==2.27.1
scipy==1.4.1
six==1.16.0
urllib3==1.26.19
wincertstore==0.2
xlrd==1.2.0
XlsxWriter==1.2.7
I noticed that the issue arises from an invalid option -ratioGap being passed to the CBC solver. I'm not sure where this option is being set within the code.
I would appreciate any guidance on how to resolve this issue. Also, if there's any additional information you need, please let me know.
Thank you in advance for your help!
The text was updated successfully, but these errors were encountered: