Coverage for python/lsst/meas/extensions/astrometryNet/loadAstrometryNetObjects.py : 99%

Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
# The following block adds links to this task from the Task Documentation page. ## \addtogroup LSST_task_documentation ## \{ ## \page measAstrom_loadAstrometryNetObjectsTask ## \ref LoadAstrometryNetObjectsTask "LoadAstrometryNetObjectsTask" ## Load reference objects from astrometry.net index files ## \}
"""!Load reference objects from astrometry.net index files
@anchor LoadAstrometryNetObjectsTask_
@section meas_astrom_loadAstrometryNetObjects_Contents Contents
- @ref meas_astrom_loadAstrometryNetObjects_Purpose - @ref meas_astrom_loadAstrometryNetObjects_Initialize - @ref meas_astrom_loadAstrometryNetObjects_IO - @ref meas_algorithms_loadReferenceObjects_Schema - @ref meas_astrom_loadAstrometryNetObjects_Config - @ref meas_astrom_loadAstrometryNetObjects_Example - @ref meas_astrom_loadAstrometryNetObjects_Debug
@section meas_astrom_loadAstrometryNetObjects_Purpose Description
Load reference objects from astrometry.net index files.
@section meas_astrom_loadAstrometryNetObjects_Initialize Task initialisation
@copydoc \_\_init\_\_
@section meas_astrom_loadAstrometryNetObjects_IO Invoking the Task
@copydoc loadObjectsInBBox
@section meas_astrom_loadAstrometryNetObjects_Config Configuration parameters
See @ref LoadAstrometryNetObjectsConfig
@section meas_astrom_loadAstrometryNetObjects_Example A complete example of using LoadAstrometryNetObjectsTask
LoadAstrometryNetObjectsTask is a subtask of AstrometryTask, which is called by PhotoCalTask. See \ref pipe_tasks_photocal_Example.
@section meas_astrom_loadAstrometryNetObjects_Debug Debug variables
LoadAstrometryNetObjectsTask does not support any debug variables. """
"""!Create a LoadAstrometryNetObjectsTask
@param[in] config configuration (an instance of self.ConfigClass); if None use self.ConfigClass() @param[in] andConfig astrometry.net data config (an instance of AstromNetDataConfig, or None); if None then use andConfig.py in the astrometry_net_data product (which must be setup) @param[in] kwargs additional keyword arguments for pipe_base Task.\_\_init\_\_
@throw RuntimeError if andConfig is None and the configuration cannot be found, either because astrometry_net_data is not setup in eups or because the setup version does not include the file "andConfig.py" """ # because astrometry may not be used, in which case it may not be properly configured
"""!Load reference objects that overlap a circular sky region
@param[in] ctrCoord center of search region (an afwGeom.Coord) @param[in] radius radius of search region (an afwGeom.Angle) @param[in] filterName name of filter, or None for the default filter; used for flux values in case we have flux limits (which are not yet implemented)
@return an lsst.pipe.base.Struct containing: - refCat a catalog of reference objects with the \link meas_algorithms_loadReferenceObjects_Schema standard schema \endlink as documented in LoadReferenceObjects, including photometric, resolved and variable; hasCentroid is False for all objects. - fluxField = name of flux field for specified filterName """
# Find multi-index files within range
# compute solver.getCatalog arguments that follow the list of star kd-trees: # - center equatorial angle (e.g. RA) in deg # - center polar angle (e.g. Dec) in deg # - radius, in deg # - idColumn # - (margs) # - star-galaxy column # - variability column ctrCoord, radius, self.andConfig.idColumn, ) + margs + ( self.andConfig.starGalaxyColumn, self.andConfig.variableColumn, True, # eliminate duplicate IDs )
# We just want to pass the star kd-trees, so just pass the # first element of each multi-index.
# NOTE: sourceSelectors require contiguous catalogs, so ensure # contiguity now, so views are preserved from here on.
refCat=refCat, fluxField=fluxField, )
def _readIndexFiles(self): """!Read all astrometry.net index files, if not already read """
"""!Get list of muti-index objects within range
@param[in] ctrCoord center of search region (an afwGeom.Coord) @param[in] radius radius of search region (an afwGeom.Angle)
@return list of multiindex objects """
# HACK, set huge default pixel scale range.
"""Context manager for loading and unloading astrometry.net multi-index files """
|