From 2112773e603fac985c28f603eb6cc1bdd168adf3 Mon Sep 17 00:00:00 2001 From: Brett Date: Fri, 26 Jul 2024 09:12:44 -0400 Subject: [PATCH] update docstrings --- src/stcal/outlier_detection/utils.py | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/stcal/outlier_detection/utils.py b/src/stcal/outlier_detection/utils.py index 85bd89ce..964de5fe 100644 --- a/src/stcal/outlier_detection/utils.py +++ b/src/stcal/outlier_detection/utils.py @@ -85,7 +85,15 @@ def compute_weight_threshold(weight, maskpt): def _abs_deriv(array): - """Take the absolute derivate of a numpy array.""" + """ + Do not use this function. + + Take the absolute derivative of a numpy array. + + This function assumes off-edge pixel values are 0 + and leads to erroneous derivative values and should + likely not be used. + """ tmp = np.zeros(array.shape, dtype=np.float64) out = np.zeros(array.shape, dtype=np.float64) @@ -103,6 +111,11 @@ def _abs_deriv(array): def _absolute_subtract(array, tmp, out): + """ + Do not use this function. + + A helper function for _abs_deriv. + """ tmp = np.abs(array - tmp) out = np.maximum(tmp, out) tmp = tmp * 0.