Skip to content

Commit 5bc07dd

Browse files
committed
make a better argmin call
1 parent d9ff82a commit 5bc07dd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/py21cmwedge/uvgridder.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -354,8 +354,8 @@ def uv_weights(
354354
_x = _u - x
355355
_y = _v - y
356356

357-
u_index = np.argmin(np.abs(_x))
358-
v_index = np.argmin(np.abs(_y))
357+
u_index = np.abs(_x).argmin()
358+
v_index = np.abs(_y).argmin()
359359

360360
# v,u indexing because y is the outer dimension in memory
361361
uvf_cube[freq_cnt, v_index, u_index] += 1.0 * nbls

0 commit comments

Comments
 (0)