Reading model coefficients -- C++ API
I am trying to implement a custom heuristic and cut callback. I need to test multiple instances, and the cuts would be dependent on some characteristics of each instance, retrieved from a data file.
My question is: is there a way to read problem data (like a .dat file in ampl) using the Gurobi C++ API? And if so, is there any specif format that must be used? I could not find any information on the website.
I know there is the option of reading .mps files, and I also know that the python API can be set up to read excel files (e.g, the diet4.py example). However, I am using the c++ api and to adequately customize my model, I need to read the coefficients from a data file and then use it to build the model.
Any help would be greatly appreciated.
-
正式なコメント
This post is more than three years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum. Or why not try our AI Gurobot?.
投稿コメントは受け付けていません。
コメント
1件のコメント