Skip to content

Commit 6822430

Browse files
ojustinokecnry
andcommitted
Removed more old weighting logic
Co-authored-by: Kyle Conroy <kyleconroy@gmail.com>
1 parent 28e0c0e commit 6822430

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

specreduce/extract.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,9 @@ def _get_boxcar_weights(center, hwidth, npix):
5656

5757
# pixels at the edges of the boxcar with partial weight, if any
5858
if fullpixels[0] > 0:
59-
w0 = hwidth - (center - fullpixels[0])
60-
if w0 >= 0:
61-
weights[fullpixels[0] - 1] = w0
59+
weights[fullpixels[0] - 1] = hwidth - (center - fullpixels[0])
6260
if fullpixels[1] < npix:
63-
w1 = hwidth - (fullpixels[1] - center)
64-
if w1 >= 0:
65-
weights[fullpixels[1]] = w1
61+
weights[fullpixels[1]] = hwidth - (fullpixels[1] - center)
6662

6763
return weights
6864

0 commit comments

Comments
 (0)