precice / micro-manager

A manager tool to facilitate two-scale coupling in multi-physics simulations using preCICE.
GNU Lesser General Public License v3.0
15 stars 10 forks source link

Handle crashing micro simulations #85

Closed tjwsch closed 5 months ago

tjwsch commented 6 months ago

This is an attempt to solve issue #74. This cannot be a permanent solution to the handling of crashing simulation. If a simulation crashes during the first time step, it is replaced with data from another random simulation. In the long run, I don't see any other solution than an interpolation (in cases where only one simulation is given and it cannot be replaced by one of different complexity). Moreover, it has not been tested with real simulations, in parallel, or using spack.

tjwsch commented 5 months ago

The latest commit adds interpolation. Besides lacking extrapolation, scipy's griddata module also cannot interpolate on linearly dependent data, thus data on the dummy problems cannot be interpolated. more thought must be put into the issue, to interpolate and extrapolate all cases of simulation crashes, and implementing a custom solution for interpolation is most likely required.

IshaanDesai commented 5 months ago

Further discussions led to the idea that implementing an inverse distance weighing would make sense for the interpolation. This would be done with a k-nearest-neighbor method, where the user can set k.