Skip to content

Map RA degrees support#651

Merged
ndilalla merged 12 commits intomasterfrom
cursor/map-ra-degrees-support-785f
Feb 24, 2026
Merged

Map RA degrees support#651
ndilalla merged 12 commits intomasterfrom
cursor/map-ra-degrees-support-785f

Conversation

@ndilalla
Copy link
Contributor

Add ra_format configuration to allow users to display Right Ascension in degrees instead of hours in map plots.

This addresses a user request (issue #622) to provide flexibility in RA axis labeling for sky maps. The default behavior remains RA in hours, ensuring backward compatibility.


Open in Cursor Open in Web

cursoragent and others added 4 commits January 21, 2026 21:02
- Add 'ra_format' configuration option to plotting settings (default: 'hour')
- Support 'deg' format to display RA in decimal degrees instead of hours
- Apply to all map plots: psmap, tsmap, residmap, localization, extension
- Add ra_format option to psmap configuration for method-specific control
- Include documentation with usage examples
- Addresses issue #622 and related PR request

Co-authored-by: ndilalla <ndilalla@stanford.edu>
Co-authored-by: ndilalla <ndilalla@stanford.edu>
Co-authored-by: ndilalla <ndilalla@stanford.edu>
Co-authored-by: ndilalla <ndilalla@stanford.edu>
@cursor
Copy link

cursor bot commented Jan 21, 2026

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@cursor cursor bot mentioned this pull request Jan 21, 2026
@codecov
Copy link

codecov bot commented Jan 21, 2026

Codecov Report

❌ Patch coverage is 89.74359% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 51.06%. Comparing base (9ca1810) to head (f5a60fd).
⚠️ Report is 13 commits behind head on master.

Files with missing lines Patch % Lines
fermipy/extension.py 0.00% 4 Missing ⚠️
fermipy/plotting.py 69.23% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #651      +/-   ##
==========================================
+ Coverage   50.96%   51.06%   +0.10%     
==========================================
  Files         144      144              
  Lines       27359    27428      +69     
==========================================
+ Hits        13943    14006      +63     
- Misses      13416    13422       +6     
Flag Coverage Δ
unittests 51.06% <89.74%> (+0.10%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

cursoragent and others added 4 commits January 21, 2026 21:20
- Add ra_format configuration to residmap, tsmap, tscube, localize, and extension
- Update all plotting methods to propagate ra_format parameter:
  - make_roi_plots: Pass ra_format through roi_kwargs
  - make_localization_plots: Support ra_format in both plot instances
  - make_extension_plots: Support ra_format in _plot_extension_tsmap
- Update analysis methods to pass ra_format from config:
  - tsmap: Pass ra_format to make_tsmap_plots
  - tscube: Pass ra_format to make_tsmap_plots
  - residmap: Pass ra_format to make_residmap_plots
  - localize: Pass ra_format to make_localization_plots
  - extension: Pass ra_format to make_extension_plots
- Ensure complete coverage for all map generation methods in fermipy
- write_roi already supports ra_format via make_plots -> plotter.run

Co-authored-by: ndilalla <ndilalla@stanford.edu>
- Document support for all map types (psmap, tsmap, tscube, residmap, localize, extension, ROI plots)
- Add comprehensive examples for all methods
- Update configuration examples with all supported methods
- Clarify that ALL map generation methods support ra_format

Co-authored-by: ndilalla <ndilalla@stanford.edu>
Co-authored-by: ndilalla <ndilalla@stanford.edu>
@ndilalla ndilalla marked this pull request as ready for review January 22, 2026 00:50
@ndilalla ndilalla requested a review from omodei February 20, 2026 03:01
@ndilalla ndilalla merged commit 2e30aab into master Feb 24, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants