create_astrometric_catalog

stcal.tweakreg.astrometric_utils.create_astrometric_catalog(wcs, epoch, catalog='GAIADR3', output='ref_cat.ecsv', table_format='ascii.ecsv', num_sources=None, timeout=30.0)[source]

Create an astrometric catalog that covers the inputs’ field-of-view.

Parameters:
  • wcs (~astropy.wcs.WCS) – WCS object specified by the user as generated by resample.resample_utils.make_output_wcs. This will typically have the same plate-scale and orientation as the first member in the list of input images to make_output_wcs. Fortunately, for alignment, this doesn’t matter since no resampling of data will be performed.

  • epoch (float) – Reference epoch used to update the coordinates for proper motion (in decimal year).

  • catalog (str, optional) – Name of catalog to extract astrometric positions for sources in the input images’ field-of-view. Default: GAIADR3. Options available are documented on the catalog web page.

  • output (str, optional) – Filename to give to the astrometric catalog read in from the master catalog web service. If None, no file will be written out.

  • num_sources (int) – Maximum number of brightest/faintest sources to return in catalog. If num_sources is negative, return that number of the faintest sources. By default, all sources are returned.

  • timeout (float) – Maximum time to wait (in seconds) for the catalog service to respond.

Notes

This function will point to astrometric catalog web service defined through the use of the ASTROMETRIC_CATALOG_URL environment variable.

Returns:

ref_table – Astropy Table object of the catalog

Return type:

~astropy.table.Table