Skip to content

Commit 8c56ac2

Browse files
authored
Merge pull request #311 from sot/remove-mask
Unmask aca image data columns (from get_aca_images) except for IMG
2 parents fd55941 + 5cf7011 commit 8c56ac2

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

mica/archive/aca_l0.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,14 @@ def get_aca_images(
225225
ok = slot_data_raw["QUALITY"] == 0
226226
slot_data = Table(slot_data_raw[ok])
227227

228+
# Unmask everything that can be unmasked
229+
# Remove mask from columns where no values are masked. IMGRAW is excepted because
230+
# the mask reflects the presence of 4x4 or 6x6 images, not entirely missing data
231+
# per row.
232+
for col in slot_data.itercols():
233+
if not np.any(col.mask) and col.name != "IMGRAW":
234+
slot_data[col.name] = col.data.data
235+
228236
# Add slot number if there are any rows (if statement not needed after
229237
# https://github.com/astropy/astropy/pull/17102).
230238
# if len(slot_data) > 0:

0 commit comments

Comments
 (0)