lephare.filterSvc

Classes

FilterSvc

Filter service for retrieving filters from various sources.

Module Contents

class FilterSvc[source]

Filter service for retrieving filters from various sources.

This class defines a number of methods for loading and manipulating filters.

classmethod from_yaml(yaml_file)[source]

Load filter from a yaml file

Parameters:

yaml_file (str) – Path to yaml file

Returns:

flt_array – Array of wavelengths in Angstrom and filter transmissivity.

Return type:

list of lephare.flt

classmethod from_config(config_file)[source]

Load filter from a .para config file

Parameters:

config_file (str) – Path to config file

Returns:

flt_array – List of filters.

Return type:

list of lephare.flt

classmethod from_svo(counter, filter_id, system='AB', calib=0)[source]

Return filter from SVO

Parameters:
  • counter (int) – Filter number

  • filter_id (str) – Id of filter in SVO format.

  • system (str, optional) – Photometric system

  • calib (float, optional) – Calibration value. Not currently used.

Returns:

res – Filter in native lephare format.

Return type:

lephare.flt

classmethod from_file(filename, counter=-1, trans=0, calib=0)[source]

Return filter from SVO

Parameters:
  • filename (str) – Path to filter file.

  • counter (int) – Filter number

  • trans (int, optional) – Photometric system.

  • calib (int, optional) – Calibration value.

Returns:

f – Filter in native lephare format.

Return type:

lephare.flt

classmethod svo_request(counter, filter_id, system)[source]

Retrieve a filter from the SVO

Parameters:
  • counter (int) – Filter number

  • filter_id (str) – Id of filter in SVO format.

  • system (str, optional) – Photometric system

Returns:

res – Filter in native lephare format.

Return type:

lephare.flt

classmethod from_keymap(keymap)[source]

Load filter from a config keymap.

Parameters:

keymap (dict of lephare.keyword) – The config keymap

Returns:

flt_array – List of filters.

Return type:

list of lephare.flt