Skip to content

Commit b9cfb56

Browse files
mjanuszcopybara-github
authored andcommitted
Support flow volumes with negative delta_z in reconcile_flows.
PiperOrigin-RevId: 580548736
1 parent 5a1eb15 commit b9cfb56

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

flow_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def reconcile_flows(flows: Sequence[np.ndarray], max_gradient: float,
104104
# Try to fill any invalid values.
105105
m = np.repeat(np.isnan(ret[0:1, ...]), ret.shape[0], 0)
106106
if ret.shape[0] == 3:
107-
m &= np.repeat(f[2:3, ...] >= min_delta_z, 3, 0)
107+
m &= np.repeat(np.abs(f[2:3, ...]) >= min_delta_z, 3, 0)
108108
ret[m] = f[m]
109109

110110
if max_gradient > 0:

0 commit comments

Comments
 (0)