I have been trying to call an AIMMS (academic license) procedure from python although this doesn't seem to work. I got the following code from another thread, which seems to work with a paid license. I also saw on another post that the academic licence might have some limitations in this regard.
Is there an API in another language, were I can make Python wrapper around this other language?
Is it possible that AIMMS internally allows to run scripts in some language, in which case a script can be built in such a way that they exchange model parameters/inputs/results with the outside world?
Best answer by MarcelRoelofs
We've released version 1.2 of the Data Exchange library which offers the capability to expose your model via a REST API, you can find the documentation on https://documentation.aimms.com/dataexchange/rest.html.
To call your model from within your Python code, you can use the Python requests module.
Prior to making the request, you can call the AIMMS launcher with your project from within Python to get the model ready to accept requests if need be (notice that you will have to accept the use conditions once every day, preventing completely automated continuous runs). You can skip this step if you already have opened your AIMMS project manually.
When calling the REST API, you can either use query parameters in the POST URL to pass e.g. the location of a data file to use or other parameters to configure the optimization, or you can pass the data as the request body and use the Data Exchange library to read it into identifiers in your model, and similarly for the model output.