get_extname_labels

ndmapper.iraf_task.get_extname_labels(datafiles)[source] [edit on github]

Ensure that all DataFile instances in datafiles use the same convention for labelling NDData component arrays (eg. ‘SCI’, ‘VAR’, ‘DQ’) and return the corresponding labels dictionary. The dictionary values can then be used to specify the EXTNAME conventions for IRAF tasks that operate on multi-extension FITS files (which is unnecessary in Python, where NDData defines which array is which). An empty dictionary is returned if the input list is empty.

Raises ValueError if the constituent label dictionaries differ.