OMPython
OMPython copied to clipboard
A Python interface to OpenModelica communicating via CORBA or ZeroMQ
This needs to be fixed. https://github.com/OpenModelica/OMPython/blob/master/OMPython/__init__.py#L80-L83
Because of the shared variables `result`, `inner_sets`, `next_set_list`, `next_set` in OMParser, the routines are non-[reentrant](https://en.wikipedia.org/wiki/Reentrancy_%28computing%29). This may cause problems when trying to use the routines concurrently or in other code.
When I run the command: ``` python omc.sendExpression("getComponentModifierValue(iPSL.Examples.DevelopmentExamples.Electrical.Machines.PSSE.GENROE,pwLine.X)") ``` I get a parse exception but when I run ``` python omc.execute("getComponentModifierValue(iPSL.Examples.DevelopmentExamples.Electrical.Machines.PSSE.GENROE,pwLine.X)") ``` I get the desired output.
### Description When calling `OMPython.simulaute(resultfile='/home/user/modelica/testfile0.mat')` with a result file (and most likely also with other flags, the following log message is shown > Failed to simulate simulation: [Errno 2] No...
Hi, I have an issue that has me absolutely stumped, any help is appreciated. I have a model, which simulates perfectly in OMEdit, using the default simulation setup (no overrides!),...
Hello, I'm using OMPython to export an FMU via `buildModelFMU` function. In the current version the attribute `displayUnit` is not exported for any variable. Is there any possibility to export...
I'm currently using ModelicaSystem via OMPython to optimize my modelica model using "Built-in Dynamic Optimization using Annotations". After calling the simulate function I get the simulation results correctly (via mat.file)....
### Description When using `ModelicaSystem.convertMo2Fmu` many times does not succeed without throwing any log or error prompt. This makes it very difficult to debug where the issue may be coming...
### Description OMPython is not compatible with python 3.12 because distutils is deprecated. See [1](https://peps.python.org/pep-0632/#:~:text=In%20Python%203.12%2C%20distutils%20will,process%20that%20currently%20use%20distutils.) for details. OMPython imports spawn from distutils and uses the `find_executable()` function for the class...