Skip to content

Conversation

rileythai
Copy link
Contributor

This PR addresses #1183 , and adds a default loader for the model spectra from SDSS-V's astra with relevant tests.

Copy link

codecov bot commented Feb 11, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.06%. Comparing base (dd1d60b) to head (21a5baa).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1203      +/-   ##
==========================================
+ Coverage   86.90%   87.06%   +0.15%     
==========================================
  Files          63       63              
  Lines        4576     4645      +69     
==========================================
+ Hits         3977     4044      +67     
- Misses        599      601       +2     

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

@rileythai rileythai marked this pull request as ready for review February 11, 2025 02:29
@rileythai
Copy link
Contributor Author

i forgot to mark this as ready 2 months ago, should be good now

rileythai and others added 13 commits August 26, 2025 13:48
- adds astraMODELStar and astraMODELVisit spectrum loaders
- no longer checks for "date_obs"; calculate that yourself
- also adds "sdss_id" to metadata now
…ases

- added new test cases for BOSS-only mwmVisit and mwmStar files
- added new checks to SpectrumList mwmVisit/mwmStar test to check verified filetype is correct
- forced override on default SpectrumList loaders -- now SpectrumList is no longer ambiguous and doesn't require a format specification
  - relevant areas in tests are updated accordingly
- added print warnings to when HDU is not specified on Spectrum1D loaders for files with multiple spectra.
- ensured tests now remove tempfiles with os.remove
  - arguably, this could work better with tmpfile, but i don't know how tests are deployed on the server-side
- three points outlining changes listed in PR as per astropy#1185
- all loaders now only load for a single datatype, avoiding prior knowledge of SDSS datatypes
- updated to only load as SpectrumList
- updated to load all visits in mwmVisit files as individual Spectrum1D objects in the SpectrumList
- relevant tests removed
- relevant import __all__ adjusted
- describes changes shown previously
- readded print -> warnings conversion
- can specify the visit to load on mwmVisit load.
- added relevant tests for the new mwmVisit case
NOTE: this requires the mwmvisit boss fix pr as well
- clear on what it does
@rosteen rosteen added the io label Aug 26, 2025
@rosteen rosteen added this to the 2.2 milestone Aug 26, 2025
@rosteen
Copy link
Contributor

rosteen commented Aug 26, 2025

@rileythai I rebased this and am seeing test failures - would you double check against your local branch and make sure I didn't botch something in the rebase? This was originally from before the 2.0 release, so there certainly could be changes needed to get it up to date beyond what I did to resolve the conflicts. Apologies for missing this when you initially marked it ready for review!

@rosteen rosteen modified the milestones: 2.2, 2.3 Oct 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants