Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove Spectrograph idname() method #1889

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 0 additions & 28 deletions pypeit/spectrographs/keck_deimos.py
Original file line number Diff line number Diff line change
Expand Up @@ -681,34 +681,6 @@ def check_frame_type(self, ftype, fitstbl, exprng=None):
msgs.warn('Cannot determine if frames are of type {0}.'.format(ftype))
return np.zeros(len(fitstbl), dtype=bool)

# TODO: We should aim to get rid of this... I'm not sure it's ever used...
def idname(self, ftype):
"""
Return the ``idname`` for the selected frame type for this
instrument.

Args:
ftype (:obj:`str`):
Frame type, which should be one of the keys in
:class:`~pypeit.core.framematch.FrameTypeBitMask`.

Returns:
:obj:`str`: The value of ``idname`` that should be available in
the :class:`~pypeit.metadata.PypeItMetaData` instance that
identifies frames of this type.
"""
# TODO: Fill in the rest of these.
name = { 'arc': 'Line',
'tilt': None,
'bias': None,
'dark': None,
'pinhole': None,
'pixelflat': 'IntFlat',
'science': 'Object',
'standard': None,
'trace': 'IntFlat' }
return name[ftype]

def get_rawimage(self, raw_file, det):
"""
Read raw images and generate a few other bits and pieces
Expand Down
22 changes: 0 additions & 22 deletions pypeit/spectrographs/spectrograph.py
Original file line number Diff line number Diff line change
Expand Up @@ -1735,28 +1735,6 @@ def vet_assigned_ftypes(self, type_bits, fitstbl):

return type_bits

def idname(self, ftype):
"""
Return the ``idname`` for the selected frame type for this
instrument.

Args:
ftype (:obj:`str`):
Frame type, which should be one of the keys in
:class:`~pypeit.core.framematch.FrameTypeBitMask`.

Returns:
:obj:`str`: The value of ``idname`` that should be available in
the :class:`~pypeit.metadata.PypeItMetaData` instance that
identifies frames of this type.

Raises:
NotImplementedError:
Raised by the base class to denote that any derived class has
not been properly defined.
"""
raise NotImplementedError('Header keyword with frame type not defined for {0}.'.format(
self.name))

# JXP says -- LEAVE THIS HERE FOR NOW. WE MAY NEED IT
# def mm_per_pix(self, det=1):
Expand Down
Loading