Skip to content

Use pset midpoint in map projection at l2#2862

Merged
lacoak21 merged 3 commits intoIMAP-Science-Operations-Center:devfrom
lacoak21:use_pset_midpoint_when_projecting_to_map
Mar 24, 2026
Merged

Use pset midpoint in map projection at l2#2862
lacoak21 merged 3 commits intoIMAP-Science-Operations-Center:devfrom
lacoak21:use_pset_midpoint_when_projecting_to_map

Conversation

@lacoak21
Copy link
Contributor

Change Summary

closes #2582

Overview

Menlo found a bug in which some pset epoch times did not have pointing attitude coverage. This was due to a small conversion error. See #2582 for more info.

Tim/ menlo suggested using the midpoint ET of the pointing instead of the start.

File changes

imap_processing/ena_maps/ena_maps.py

  • Use the midpoint time instead of the start of the pointing (epoch)

Testing

Add a small test to make sure epoch_delta returns the correct value

@lacoak21 lacoak21 added this to the March 2026 milestone Mar 24, 2026
@lacoak21 lacoak21 self-assigned this Mar 24, 2026
@lacoak21 lacoak21 added this to IMAP Mar 24, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates ENA map pointing-set frame transformations to use the pointing-set midpoint ET (instead of start epoch) to avoid SPICE attitude coverage gaps during L2 map projection (fix for #2582).

Changes:

  • Use epoch + epoch_delta/2 (midpoint TTJ2000) when deriving event_et for PSET↔Map coordinate transformations.
  • Add PointingSet.epoch_delta convenience property.
  • Extend ULTRA PSET test fixtures and add a basic assertion for epoch_delta.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
imap_processing/ena_maps/ena_maps.py Switches default transform time to PSET midpoint and introduces epoch_delta property.
imap_processing/tests/ultra/mock_data.py Mocks epoch_delta in ULTRA L1C healpix PSET test dataset.
imap_processing/tests/ena_maps/test_ena_maps.py Adds an assertion that UltraPointingSet.epoch_delta is present and returns the mocked value.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

@subagonsouth subagonsouth left a comment

Choose a reason for hiding this comment

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

LGTM

@lacoak21 lacoak21 merged commit 408591a into IMAP-Science-Operations-Center:dev Mar 24, 2026
14 checks passed
@github-project-automation github-project-automation bot moved this to Done in IMAP Mar 24, 2026
@lacoak21 lacoak21 deleted the use_pset_midpoint_when_projecting_to_map branch March 24, 2026 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

BUG - Failure to produce maps due to Pointing Sets epoch misaligning with SPICE data

3 participants