data_loader

specviz.interfaces.data_loader(label, identifier, priority=-1, extensions=None, writer=None, **kwargs)[source]

A decorator that registers a function and identifies with an Astropy io registry object.

Priority will be assigned as an attribute to the wrapped function for use in the auto loader. Loaders with high numerical value will be tried first, followed by low numerical value in order.

Parameters:
  • label (str) – user-fiendly name for the data loader
  • identifier (function) – function used to determine if the loader should be used on the Input
  • priority (int) – absolute priority to determine which loader to attempt first