astro query:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- astroquery v0.4.11 »
- ESA Integral Science Legacy Archive (ISLA) (`astroquery.esa.integral`) »
- IntegralClass

# IntegralClass

class astroquery.esa.integral.IntegralClass(auth_session=None)

  Bases: `BaseVOQuery`, `BaseQuery`

  Class to init ESA Integral Module and communicate with isla

  Attributes Summary

  `tap` |

  Methods Summary

  `download_science_windows`(*[, ...]) | Method to download science windows associated to one of these parameters: science_windows, observation_id, revolution or proposal
  `get_bands`() | Get the bands available in ISLA
  `get_epochs`(*[, target_name, instrument, band]) | Retrieve the INTEGRAL epochs associated to a target and an instrument or a band
  `get_instrument_band_map`() | Maps the bands and instruments included in ISLA
  `get_instruments`() | Get the instruments available in ISLA
  `get_job`(jobid) | Returns the job corresponding to an ID.
  `get_job_list`(*[, phases, after, last, ...]) | Returns all the asynchronous jobs
  `get_long_term_timeseries`(target_name, *[, ...]) | Method to download long term timeseries associated to an epoch and instrument or band
  `get_mosaic`(epoch[, instrument, band, path, ...]) | Method to download mosaics associated to an epoch and instrument or band
  `get_observations`(*[, target_name, ...]) | Retrieve the INTEGRAL observations associated to target name, time range and/or revolution
  `get_short_term_timeseries`(target_name, epoch) | Method to download short term timeseries associated to an epoch and instrument or band
  `get_source_metadata`(target_name) | Retrieve the metadata associated to an INTEGRAL target
  `get_sources`(target_name, *[, async_job, ...]) | Retrieve the coordinates of an INTEGRAL source
  `get_spectra`(target_name, epoch[, ...]) | Method to download mosaics associated to an epoch and instrument or band
  `get_table`(table) | Gets the specified table from ISLA TAP
  `get_tables`(*[, only_names]) | Gets all public tables within ISLA TAP
  `get_timeline`(coordinates, *[, radius]) | Retrieve the INTEGRAL timeline associated to coordinates and radius
  `login`(*[, user, password]) | Performs a login.
  `logout`() | Performs a logout.
  `query_tap`(query, *[, async_job, ...]) | Launches a synchronous or asynchronous job to query the ISLA tap

  Attributes Documentation

  tap

  Methods Documentation

  download_science_windows(*, science_windows=None, observation_id=None, revolution=None, proposal=None, output_file=None, cache=False, read_fits=True)

    Method to download science windows associated to one of these parameters: science_windows, observation_id, revolution or proposal

    Parameters:
      science_windows list of str, optional

        Science Windows to download

      observation_id: str, optional

        Observation ID associated to science windows

      revolution: str, optional

        Revolution associated to science windows

      proposal: str, optional

        Proposal ID associated to science windows

      output_file: str, optional

        File name and path for the downloaded file

      cache: bool, optional, default False

        Flag to determine if the file is stored in the cache or not

      read_fits: bool, optional, default True

        Open the downloaded file and parse the existing FITS files

    Returns:
      If read_fits=True, a list with objects containing filename, path and FITS file opened with the
      science windows. If read_fits=False, the path of the downloaded file
  get_bands()

    Get the bands available in ISLA

  get_epochs(*, target_name=None, instrument=None, band=None)

    Retrieve the INTEGRAL epochs associated to a target and an instrument or a band

    Parameters:
      target_name str, optional

        target name to be requested, mandatory

      instrument str, optional

        Possible values are in isla.instruments object

      band str, optional

        Possible values are in isla.bandsobject

    Returns:
      An astropy.table object containing the available epochs
  get_instrument_band_map()

    Maps the bands and instruments included in ISLA

  get_instruments()

    Get the instruments available in ISLA

  get_job(jobid)

    Returns the job corresponding to an ID. Note that the caller must be able to see the job in the current security context.

    Parameters:
      jobid str, mandatory

        ID of the job to view

    Returns:
      JobSummary corresponding to the job ID
  get_job_list(*, phases=None, after=None, last=None, short_description=True)

    Returns all the asynchronous jobs

    Parameters:
      phases list of str

        Union of job phases to filter the results by.

      after datetime

        Return only jobs created after this datetime

      last int

        Return only the most recent number of jobs

      short_description flag - True or False

        If True, the jobs in the list will contain only the information corresponding to the TAP ShortJobDescription object (job ID, phase, run ID, owner ID and creation ID) whereas if False, a separate GET call to each job is performed for the complete job description

    Returns:
      A list of Job objects
  get_long_term_timeseries(target_name, *, instrument=None, band=None, path='', filename=None, cache=False, read_fits=True)

    Method to download long term timeseries associated to an epoch and instrument or band

    Parameters:
      target_name str, mandatory

        target name to be requested, mandatory

      instrument str

        Possible values are in isla.instruments object

      band str

        Possible values are in isla.bandsobject

      path: str, optional

        Path for the downloaded file

      filename: str, optional

        Filename for the downloaded file

      cache: bool, optional, default False

        Flag to determine if the file is stored in the cache or not

      read_fits: bool, optional, default True

        Open the downloaded file and parse the existing FITS files

    Returns:
      If read_fits=True, a list with objects containing filename, path and FITS file opened with long
      term timeseries. If read_fits=False, the path of the downloaded file
  get_mosaic(epoch, instrument=None, band=None, *, path='', filename=None, cache=False, read_fits=True)

    Method to download mosaics associated to an epoch and instrument or band

    Parameters:
      epoch str, mandatory

        reference epoch for the short term timeseries

      instrument str

        Possible values are in isla.instruments object

      band str

        Possible values are in isla.bandsobject

      cache: bool, optional, default False

        Flag to determine if the file is stored in the cache or not

      path: str, optional

        Path for the downloaded file

      filename: str, optional

        Filename for the downloaded file

      read_fits: bool, optional, default True

        Open the downloaded file and parse the existing FITS files

    Returns:
      If read_fits=True, a list with objects containing filename, path and FITS file opened with mosaics.
      If read_fits=False, a list of paths of the downloaded files
  get_observations(*, target_name=None, coordinates=None, radius=14.0, start_time=None, end_time=None, start_revno=None, end_revno=None, async_job=False, output_file=None, output_format=None, verbose=False)

    Retrieve the INTEGRAL observations associated to target name, time range and/or revolution

    Parameters:
      target_name: str, optional

        target name to be requested

      coordinates: str or SkyCoord, optional

        coordinates of the center in the cone search

      radius: float or quantity, optional, default value 14 degrees

        radius in degrees (int, float) or quantity of the cone_search

      start_time: str in UTC or datetime, optional

        start time of the observation

      end_time: str in UTC or datetime, optional

        end time of the observation

      start_revno: string, optional

        start revolution number, as a four-digit string with leading zeros e.g. 0352

      end_revno: string, optional

        end revolution number, as a four-digit string with leading zeros e.g. 0353

      async_job bool, optional, default ‘False’

        executes the query (job) in asynchronous/synchronous mode (default synchronous)

      output_file str, optional, default None

        file name where the results are saved if dumpToFile is True. If this parameter is not provided, the jobid is used instead

      output_format str, optional, default ‘votable’

        results format

      verbose bool, optional, default ‘False’

        flag to display information about the process

    Returns:
      An astropy.table object containing the results
  get_short_term_timeseries(target_name, epoch, instrument=None, band=None, path='', filename=None, cache=False, read_fits=True)

    Method to download short term timeseries associated to an epoch and instrument or band

    Parameters:
      target_name str, mandatory

        target name to be requested, mandatory

      epoch str, mandatory

        reference epoch for the short term timeseries

      instrument str, optional

        Possible values are in isla.instruments object

      band str, optional

        Possible values are in isla.bandsobject

      path: str, optional

        Path for the downloaded file

      filename: str, optional

        Filename for the downloaded file

      cache: bool, optional, default False

        Flag to determine if the file is stored in the cache or not

      read_fits: bool, optional, default True

        Open the downloaded file and parse the existing FITS files

    Returns:
      If read_fits=True, a list with objects containing filename, path and FITS file opened with short
      term timeseries. If read_fits=False, the path of the downloaded file
  get_source_metadata(target_name)

    Retrieve the metadata associated to an INTEGRAL target

    Parameters:
      target_name str, mandatory

        target name to be requested, mandatory

    Returns:
      An object containing te metadata from the target
  get_sources(target_name, *, async_job=False, output_file=None, output_format=None)

    Retrieve the coordinates of an INTEGRAL source

    Parameters:
      target_name str, mandatory

        target name to be requested, mandatory

      async_job bool, optional, default ‘False’

        executes the query (job) in asynchronous/synchronous mode (default synchronous)

      output_file str, optional, default None

        file name where the results are saved if dumpToFile is True. If this parameter is not provided, the jobid is used instead

      output_format str, optional, default ‘votable’

        results format

    Returns:
      An astropy.table object containing the results
  get_spectra(target_name, epoch, instrument=None, band=None, *, path='', filename=None, cache=False, read_fits=True)

    Method to download mosaics associated to an epoch and instrument or band

    Parameters:
      target_name str, mandatory

        target name to be requested, mandatory

      epoch str, mandatory

        reference epoch for the short term timeseries

      instrument str

        Possible values are in isla.instruments object

      band str

        Possible values are in isla.bandsobject

      path: str, optional

        Path for the downloaded file

      filename: str, optional

        Filename for the downloaded file

      cache: bool, optional, default False

        Flag to determine if the file is stored in the cache or not

      read_fits: bool, optional, default True

        Open the downloaded file and parse the existing FITS files

    Returns:
      If read_fits=True, a list with objects containing filename, path and FITS file opened with spectra.
      If read_fits=False, a list of paths of the downloaded files
  get_table(table)

    Gets the specified table from ISLA TAP

    Parameters:
      table str, mandatory

        full qualified table name (i.e. schema name + table name)

    Returns:
      A table object
  get_tables(*, only_names=False)

    Gets all public tables within ISLA TAP

    Parameters:
      only_names bool, optional, default False

        True to load table names only

    Returns:
      A list of table objects
  get_timeline(coordinates, *, radius=14)

    Retrieve the INTEGRAL timeline associated to coordinates and radius

    Parameters:
      coordinates: str or SkyCoord, mandatory

        RA and Dec of the source

      radius: float or quantity, optional, default value 14 degrees

        radius in degrees (int, float) or quantity of the cone_search

    Returns:
      An object containing:

        totalItems: a counter for the number of items retrieved fraFC: totEffExpo: timeline: An astropy.table object containing the results for scwExpo, scwRevs, scwTimes and scwOffAxis

  login(*, user=None, password=None)

    Performs a login. TAP+ only User and password shall be used

    Parameters:
      user str, mandatory, default None

        Username. If no value is provided, a prompt to type it will appear

      password str, mandatory, default None

        User password. If no value is provided, a prompt to type it will appear

  logout()

    Performs a logout. TAP+ only

  query_tap(query, *, async_job=False, output_file=None, output_format='votable')

    Launches a synchronous or asynchronous job to query the ISLA tap

    Parameters:
      query str, mandatory

        query (adql) to be executed

      async_job bool, optional, default ‘False’

        executes the query (job) in asynchronous/synchronous mode (default synchronous)

      output_file str, optional, default None

        file name where the results are saved if dumpToFile is True. If this parameter is not provided, the jobid is used instead

      output_format str, optional, default ‘votable’

        results format

    Returns:
      An astropy.table object containing the results