scopesim.source.source_utils.validate_source_input

scopesim.source.source_utils.validate_source_input#

scopesim.source.source_utils.validate_source_input(**kwargs) None#

Check validity of kwargs passed to Source object.

Currently checks for “filename”, “image” and “table”, raising the exceptions listed below. Additionally logs a warning if no WCS is found in an image, or if a given filename cannot be found.

Parameters:

**kwargs (TYPE) – DESCRIPTION.

Raises:
  • TypeError – Raised if an image isn’t a FITS HDU or a table isn’t an astropy Table.

  • ValueError – Raised if a table does not contain the minimum required columns.

Return type:

None