proteus
proteus copied to clipboard
Generalize hack in SpatialTools for the SWFlow reflecting boundary conditions
We should generalize the hack introduced in https://github.com/erdc/proteus/pull/1223 for the SWFlow reflecting boundary conditions. Currently, to use partial reflecting boundary conditions, the user sets the boundary flag to 99
and this requires a hack in proteus/SpatialTools.py
.
@zhang-alvin @cekees
An example of how large boundary tags might affect memory usage in RANS2P:
https://github.com/erdc/proteus/blob/master/proteus/mprans/RANS2P.py#L663-L667
Oops! I will try to fix this ASAP.
@ejtovar, you should check if something similar is being done with SWFlow, but I don't think you need to rush to fix this as this is likely a very involved fix. But this is something that we have to keep in mind in terms of system design.
One way to resolve this would be to use a dictionary of numpy arrays with the key as the boundary tag and the value as the corresponding numpy array. @cekees mentioned that there used to be a difficulty in passing such a structure to the C++ backend, but it might be easier now since @JohanMabille's argdict-based refactoring for the backend function calls.
@ejtovar do you recall if this was ever addressed? Might be something one of my students could work on.
@cekees No, I believe this hack is still there.