Can't specify node snapping distance from min_energy_nodes
cossatot opened this issue · 2 comments
In rbf.nodes.min_energy_nodes
, the keyword delta
is passed to rbf.nodes._disperse_within_boundary
; it is also the name of the snapping distance parameter in rbf.nodes._snap_to_boundary
even though the parameters aren't the same thing--as a consequence, a default value of 0.5 is hardcoded as the delta for the snapping function. However, I've needed to modify this parameter from a script so hardcoding it doesn't work for me.
I'm jointly submitting a pull request that uses a keyword snap_delta
in min_energy_nodes
to allow the user to specify this value and avoid a name collision with the delta
function used to disperse the nodes.
Sounds good. I will merge it. What issues were you noticing that made you want to change the snapping delta?
Accurately representing a highly irregular topographic surface, and then still having a high concentration of points just below the surface, to get the most accurate stress calculations. IIRC (I made this change to my scripts last spring) if the snapping delta was too large, the points would all stick to the surface and then there would be a gap of a few units (km) below the topo. It wasn't all the time, but it would happen with certain combinations of domain size/shape and number of nodes.