Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

Does OMCSessionZMQ connect to new OMC each time?

Does OMCSessionZMQ connect to new OMC each time?

When multiple OMCSessionZMQ objects are created on a single machine, do these session instances all communicate to the same modelica compiler; or is each instance communicating with its own compiler?

I ask because I am wanting to run in parallel many tasks:

1. Create OMCSessionZMQ instance and load a model
2. Manipulate the model: change component names, alter connections
3. Dump model to XML
4. Perform analysis on XML with another tool

The question is if I have multiple Python interpreters working through those steps in parallel, do we get a fresh unaltered model each time we load it? Or do we get a model that has been manipulated by another session?

Re: Does OMCSessionZMQ connect to new OMC each time?

You always get a new session (you can see each omc process in your OS process list). This is the case also if you use the same Python session for OMCSessionZMQ.

Re: Does OMCSessionZMQ connect to new OMC each time?

Thank-you!

There are 0 guests and 0 other users also viewing this topic
You are here: