Skip to content

Int ids - #2188

Open
profxj wants to merge 11 commits into
developfrom
int_ids
Open

Int ids#2188
profxj wants to merge 11 commits into
developfrom
int_ids

Conversation

@profxj

@profxj profxj commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

Adding the IDS spectrograph on the INT

A Dev-Suite PR will soon follow


Note

Low Risk
Additive new-instrument code with no changes to existing spectrograph reduction paths; risk is mainly incorrect metadata or parameters for unverified RED+2 data until dev-suite validation.

Overview
Adds PypeIt support for the INT Intermediate Dispersion Spectrograph (IDS) on the 2.54m Isaac Newton Telescope, including a new INT telescope entry and a full int_ids spectrograph module.

The shared INTIDSSpectrograph base handles IDS-specific FITS metadata (RA/DEC conversion, binning from CCDSUM, arc lamp state from AGARCLMP), reads gain, read noise, and trim/overscan regions from headers with FITS-to-numpy axis swapping for TRIMSEC/BIASSEC, and wires frame typing off IMAGETYP plus lamp/exposure rules. Default and grating-specific parameters target CuAr/CuNe wavelength calibration (holy-grail by default; R1200B uses full_template with int_ids_R1200B.fits). Two concrete spectrograph classes are registered: int_ids_eev10 (verified against test data) and int_ids_redplus2 (documented placeholder). Both are marked supported = False until broader validation lands via the planned dev-suite work.

Reviewed by Cursor Bugbot for commit 6770151. Bugbot is set up for automated code reviews on this repo. Configure here.

@profxj

profxj commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator Author

@cursor review

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 6770151. Configure here.

# unbinned spatial plate scale [arcsec/pixel]
detector_platescale = None
# is the raw spectral axis reversed (wavelength decreasing)?
detector_specflip = None

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Missing UltraDAS file extension allow-list

High Severity

INTIDSSpectrograph and its children never set allowed_extensions, so they inherit the base default of .fits / .fits.gz. INT/IDS raw frames come from UltraDAS and use the .fit extension (same as WHT/ISIS). _check_extensions therefore rejects valid IDS files before they can be read, so setup and reductions fail on real data.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 6770151. Configure here.

@tbowers7 tbowers7 added the New Spectrograph Adds a new spectrograph and/or modes of an existing to PypeIt label Aug 25, 2026

@rcooke-ast rcooke-ast left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This looks good to me. Approving, but please confirm tests pass, and it would be good to post an image of the wavelength QA if you have it. I will try to source some data to double check this works, as well.

platescale = self.detector_platescale,
darkcurr = 0.0, # e-/pixel/hour; TODO: look up
saturation = 65535.,
nonlinear = 0.99, # TODO: look up and update

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

ygap = 0.,
ysize = 1.,
platescale = self.detector_platescale,
darkcurr = 0.0, # e-/pixel/hour; TODO: look up

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

darkcurr is 4/e-/pixel/hour for EEV10A

https://www.ing.iac.es/Engineering/detectors/ultra_eev10a.htm

@kbwestfall kbwestfall left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

A couple of minor comments from me.

:class:`INTIDSEEV10Spectrograph` (``int_ids_eev10``) and
:class:`INTIDSREDPLUS2Spectrograph` (``int_ids_redplus2``).

Generated by JXP and Claude.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Can we remove this from every docstring?

``'[1:4099,1:366]'``.
"""
xsec, ysec = section.strip().strip('[]').split(',')
return f'[{ysec.strip()},{xsec.strip()}]'

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This is a very general function. Can it be moved to the base class?

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

Labels

New Spectrograph Adds a new spectrograph and/or modes of an existing to PypeIt

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants