dss-extensions / dss_matlab

MATLAB interface to our alternative implementation of OpenDSS, based on the DSS C-API library aiming for full COM compatibility on Windows, Linux and MacOS.
BSD 3-Clause "New" or "Revised" License
10 stars 2 forks source link

Allow `parfor` with the OpenDSS engine #15

Open PMeira opened 2 years ago

PMeira commented 2 years ago

Allowing parfor with OpenDSS is something that has been asked several times in the official forum and through personal requests.

DSS C-API v0.12 allows creating multiple independent DSS instances. We should try to add an example with parfor if everything works as expected.

PMeira commented 2 years ago

This probably also depends on #13. For thread pools, calllib is not supported.

Looks like MATLAB is still very primitive with threads. Using parfor with pool('local') works within its limitations, but the overhead is probably a lot.