SIAQuery¶
-
class
pyvo.dal.sia.SIAQuery(baseurl, pos=None, size=None, format=None, intersect=None, verbosity=None, **keywords)[source]¶ Bases:
pyvo.dal.query.DALQuerya class for preparing an query to an SIA service. Query constraints are added via its service type-specific methods. The various execute() functions will submit the query and return the results.
The base URL for the query, which controls where the query will be sent when one of the execute functions is called, is typically set at construction time; however, it can be updated later via the
baseurlto send a configured query to another service.In addition to the search constraint attributes described below, search parameters can be set generically by name via dict semantics.
The typical function for submitting the query is
execute(); however, alternate execute functions provide the response in different forms, allowing the caller to take greater control of the result processing.initialize the query object with a baseurl and the given parameters
Parameters: baseurl : str
the base URL for the SIA service
pos :
SkyCoordclass or sequence of two floatsthe position of the center of the rectangular search region. assuming icrs decimal degrees if unit is not specified.
size :
Quantityclass or 2 element sequence of floatthe full rectangular size of the search region along the RA and Dec directions. converted if it’s a iterable containing scalars, assuming decimal degrees.
size :
Quantityclass or scalar floatthe size of the rectangular region around pos. assuming icrs decimal degrees if unit is not specified.
format : str
the image format(s) of interest. “all” (default) indicates all available formats; “graphic” indicates graphical images (e.g. jpeg, png, gif; not FITS); “metadata” indicates that no images should be returned–only an empty table with complete metadata; “image/*” indicates a particular image format where * can have values like “fits”, “jpeg”, “png”, etc.
intersect : str
a token indicating how the returned images should intersect with the search region; recognized values include:
COVERS select images that completely cover the search region ENCLOSED select images that are complete enclosed by the region OVERLAPS select any image that overlaps with the search region CENTER select images whose center is within the search region verbosity : int
an integer value that indicates the volume of columns to return in the result table. 0 means the minimum set of columsn, 3 means as many columns as are available.
**keywords :
additional parameters can be given via arbitrary case insensitive keyword arguments. Where there is overlap with the parameters set by the other arguments to this function, these keywords will override.
Attributes Summary
formatthe image format(s) of interest. “all” (default) intersecta token indicating how the returned images should posthe position of the center of the rectangular search region as a sizethe size of the rectangular region around pos as a verbosityan integer value that indicates the volume of columns Methods Summary
execute()submit the query and return the results as a SIAResults instance Attributes Documentation
-
format¶ the image format(s) of interest. “all” (default) indicates all available formats; “graphic” indicates graphical images (e.g. jpeg, png, gif; not FITS); “metadata” indicates that no images should be returned–only an empty table with complete metadata; “image/*” indicates a particular image format where * can have values like “fits”, “jpeg”, “png”, etc.
-
intersect¶ a token indicating how the returned images should intersect with the search region; recognized values include:
COVERS select images that completely cover the search region ENCLOSED select images that are complete enclosed by the region OVERLAPS select any image that overlaps with the search region CENTER select images whose center is within the search region
-
pos¶ the position of the center of the rectangular search region as a
SkyCoordinstance.
-
size¶ the size of the rectangular region around pos as a
Quantityinstance.
-
verbosity¶ an integer value that indicates the volume of columns to return in the result table. 0 means the minimum set of columsn, 3 means as many columns as are available.
Methods Documentation
-
execute()[source]¶ submit the query and return the results as a SIAResults instance
Raises: DALServiceError
for errors connecting to or communicating with the service
DALQueryError
for errors either in the input query syntax or other user errors detected by the service
DALFormatError
for errors parsing the VOTable response
-