Skip to content

MAG - Metadata updates (SPDF feedback, CAVA plotting) - #3540

Merged
lacoak21 merged 2 commits into
IMAP-Science-Operations-Center:devfrom
jtniehof:mag_istp_updates
Oct 5, 2026
Merged

lacoak21 merged 2 commits into
IMAP-Science-Operations-Center:devfrom
jtniehof:mag_istp_updates

Conversation

@jtniehof

@jtniehof jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator

Change Summary

Overview

Metadata and typing update for MAG L2 (and L1d).

  • Change quality_flags to UINT1 (8 bits) since it's a single bit; this better matches VALIDMAX
  • Add SCALEMIN/SCALEMAX to the field vectors

Closes #3513, #3539. These issues provide more background.

Because #3534 appears to be an issue with old code being deployed, after merge/deploy/reprocess of this, that can probably be closed.

Testing

Unit tests added that directly mirror tests of similar functionality.

@jtniehof jtniehof added Ins: MAG Related to the MAG instrument Data Release 2 Deadline: September 1, 2026 labels Oct 5, 2026
@jtniehof

jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator Author

Rebased to current dev and force-pushed to see if that dealt with the bizarre reduction in coverage of untouched files

@jtniehof

jtniehof commented Oct 5, 2026 •

Copy link
Copy Markdown
Collaborator Author

Incidentally both changes affect burst and norm (or at least should, going to verify on output). EDIT: yep, confirmed, burst is also updated.

@jtniehof

jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator Author

@alastairtree quick check that -100 to 100 nT is a reasonable default scaling?

@alastairtree

Copy link
Copy Markdown
Collaborator

@alastairtree quick check that -100 to 100 nT is a reasonable default scaling?

+- 100 is probably fine but will make the lines look very flat. When we do field plots we typically adjust the scales based on the data.

@jtniehof

jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator Author

+- 100 is probably fine but will make the lines look very flat. When we do field plots we typically adjust the scales based on the data.

We always have the possibility to zoom after the fact...this is just a reasonable default for bringing up a large scale plot. Tradeoff between not going off-scale and showing something not-ridiculous. 20 also seems to make sense to me if it's better for you, will just have a little clipping.

@jtniehof

jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator Author

@bryan-harter : now that all the Tests have completed, the codecov/project has jumped back up to 98+%. ubuntu-latest 3.10 took forever to run and I'm guessing codecov is somehow using that information for its coverage.

@jtniehof

jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator Author

If someone can poke me once merged/deployed/reprocessed, I need to pull updated samples for SPDF. Thanks!

@lacoak21 lacoak21 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Is l1d the earliest product that needs reprocessing?

@jtniehof

jtniehof commented Oct 5, 2026

Copy link
Copy Markdown
Collaborator Author

LGTM! Is l1d the earliest product that needs reprocessing?

Should be. I didn't explicitly check that l1c doesn't get affected somehow, but we don't try to plot it in CAVA and we're explicitly casting the flag type here, so don't need to do any changes in earlier levels.

@lacoak21
lacoak21 merged commit 1397b3f into IMAP-Science-Operations-Center:dev Oct 5, 2026
22 checks passed
@jtniehof

jtniehof commented Oct 6, 2026

Copy link
Copy Markdown
Collaborator Author

l1d is complete; I am reprocessing l2 (norm-srf and burst-srf, then will verify this makes all outputs)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Data Release 2 Deadline: September 1, 2026 Ins: MAG Related to the MAG instrument

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update MAG L2 so that quality_flags is INT2

3 participants