SSAService¶
-
class
pyvo.dal.ssa.
SSAService
(baseurl, resmeta=None, version='1.0')[source]¶ Bases:
pyvo.dal.query.DALService
a representation of an SSA service
instantiate an SSA service
Parameters: baseurl : str
the base URL for submitting search queries to the service.
resmeta : dict
an optional dictionary of properties about the service
Methods Summary
create_query
([pos, size, format])create a query object that constraints can be added to and then search
(pos, size[, format])submit a simple SSA query to this service with the given constraints. Methods Documentation
-
create_query
(pos=None, size=None, format=None, **keywords)[source]¶ create a query object that constraints can be added to and then executed. The input arguments will initialize the query with the given values.
Parameters: pos : 2-element tuple of floats
a 2-element tuple giving the ICRS RA and Dec of the center of the search region in decimal degrees
size : float
a floating point number giving the diameter of the circular region in decimal degrees around pos in which to search for spectra.
format : str
the image format(s) of interest. “all” 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.
**keywords :
additional parameters can be given via arbitrary keyword arguments. These can be either standard parameters (with names drown from the
SSAQuery.std_parameters
list) or paramters custom to the service. Where there is overlap with the parameters set by the other arguments to this function, these keywords will override.Returns: SSAQuery
the query instance
See also
-
search
(pos, size, format='all', **keywords)[source]¶ submit a simple SSA query to this service with the given constraints.
This method is provided for a simple but typical SSA queries. For more complex queries, one should create an SSAQuery object via create_query()
Parameters: pos : 2-element tuple of floats
a 2-element tuple giving the ICRS RA and Dec of the center of the search region in decimal degrees
size : float
a floating point number giving the diameter of the circular region in decimal degrees around pos in which to search for spectra.
format : str
the spectral format(s) of interest. “all” (default) indicates all available formats; “graphic” indicates graphical spectra (e.g. jpeg, png, gif; not FITS); “metadata” indicates that no spectra should be returned–only an empty table with complete metadata.
**keywords :
additional parameters can be given via arbitrary keyword arguments. These can be either standard parameters (with names drown from the
SSAQuery.std_parameters
list) or paramters custom to the service. Where there is overlap with the parameters set by the other arguments to this function, these keywords will override.Returns: SSAResults
a container holding a table of matching catalog records
Raises: DALServiceError
for errors connecting to or communicating with the service
DALQueryError
if the service responds with an error, including a query syntax error
-