[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[TRNSYS-users] How to speed-up my co-simulation?



Hello,

I need to run my TRNSYS simulation from a Python script to give some inputs and then read back some outputs. At the moment I am using I write values to the .back  and .b18 files, then the subprocess function in Python runs the simulation for one timestep, and then I read the outputs from the outputs of printer component. The co-simulation with this method is very time-consuming. So I am searching for easier methods. I also tried the following:

Implementing my Python script in Type 3157: This component has a nested dictionary to receive inputs and give back outputs. But my Python script includes a Neural Network that should be trained, and it is not clear how this component can save the neural network. Saving it externally is not feasible due to some other details. 

Using FMU: I heard about TRNSYS FMU for co-simulation but it does not work with my 64-bit system.

Simplifying the simulation: I removed all the output types and other unnecessary types. 

Any feedback on how to speed up my co-simulation is appreciated.

Thanks