Open jerabekjak opened 5 months ago
In general, I agree with this fix. I have also found mat_aa == 0
in some cases and it clearly should not happen. However, I do not understand how can be mat_aa == 0
at this point. I do not see a way 0
would be saved into the matrix with the code above the added line (unless nodata == 0
):
mat_aa = ma.where(
ma.logical_or(
mat_nsheet == no_data, mat_y == no_data, mat_slope == no_data
),
no_data,
ma.where(
mat_slope == 0,
0.0001, # comment OP: where did we get this value from?
1 / mat_nsheet * ma.power(mat_slope, mat_y)
)
)
Next steps in this branch are described in commit 3098be1.
in some cases, there was a problem that mat_aa was returned zero. This is a draft of simple yet not elegant solution. Feel free to modify....