Skip to content

Commit f6985d7

Browse files
committed
Don't use i and j for polar distortion
We were accidentally re-assigning `i` and `j` within that loop. Use a different variable name instead. Signed-off-by: Patrick Avery <patrick.avery@kitware.com>
1 parent a1eec8f commit f6985d7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

hexrdgui/overlays/powder_overlay.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -507,9 +507,9 @@ def generate_ring_points(self, instr, tths, etas, panel, display_mode):
507507

508508
# Compute and apply offset
509509
for ic, ang_crd in enumerate(raw_ang_crds):
510-
i = np.argmin(np.abs(ang_crd[0] - first_tth_row))
511-
j = np.argmin(np.abs(ang_crd[1] - first_eta_col))
512-
ang_crds[ic, 0] += polar_field[j, i]
510+
ii = np.argmin(np.abs(ang_crd[0] - first_tth_row))
511+
jj = np.argmin(np.abs(ang_crd[1] - first_eta_col))
512+
ang_crds[ic, 0] += polar_field[jj, ii]
513513

514514
if apply_distortion or offset_distortion:
515515
if display_mode in (ViewType.raw, ViewType.cartesian):

0 commit comments

Comments
 (0)