astro query:docs

- Index
- Modules

### Navigation

- next »
- « previous |
- astroquery v0.4.11 »
- MAST Queries (`astroquery.mast`) »
- TesscutClass

# TesscutClass

class astroquery.mast.TesscutClass

  Bases: `MastQueryWithLogin`

  MAST TESS FFI cutout query class.

  Class for accessing TESS full-frame image cutouts.

  Attributes Summary

  `cache_location` |

  Methods Summary

  `__call__`(*args, **kwargs) | init a fresh copy of self
  `authenticated`() |
  `clear_cache`() | Removes all cache files.
  `disable_cloud_dataset`() |
  `download_cutouts`(*[, coordinates, size, ...]) | Download cutout target pixel file(s) around the given coordinates with indicated size.
  `enable_cloud_dataset`([provider, profile, ...]) |
  `get_cutouts`(*[, coordinates, size, product, ...]) | Get cutout target pixel file(s) around the given coordinates with indicated size, and return them as a list of `HDUList` objects.
  `get_sectors`(*[, coordinates, radius, ...]) | Get a list of the TESS data sectors whose footprints intersect with the given search area.
  `login`([token, store_token, reenter_token]) | Log into the MAST portal.
  `logout`() | Log out of current MAST session.
  `reset_cache_location`() | Resets the cache location to the default astropy cache
  `resolve_object`(objectname, *[, resolver, ...]) | Resolves an object name to a position on the sky.
  `session_info`([verbose]) | Displays information about current MAST user, and returns user info dictionary.

  Attributes Documentation

  cache_location

  Methods Documentation

  __call__(*args, **kwargs)

    init a fresh copy of self

  authenticated()
  clear_cache()

    Removes all cache files.

  disable_cloud_dataset()

    Deprecated since version v0.4.8: This function is non-operational and will be removed in a future release.

    Disables downloading public files from S3 instead of MAST.

  download_cutouts(*, coordinates=None, size=5, sector=None, product='SPOC', path='.', inflate=True, objectname=None, moving_target=False, mt_type=None, resolver=None, verbose=False)

    Download cutout target pixel file(s) around the given coordinates with indicated size.

    Parameters:
      coordinates str or `astropy.coordinates` object, optional

        The target around which to search. It may be specified as a string or as the appropriate `astropy.coordinates` object.

        NOTE: If moving_target or objectname is supplied, this argument cannot be used.

      size int, array-like, `Quantity`

        Optional, default 5 pixels. The size of the cutout array. If `size` is a scalar number or a scalar `Quantity`, then a square cutout of `size` will be created. If `size` has two elements, they should be in `(ny, nx)` order. Scalar numbers in `size` are assumed to be in units of pixels. `Quantity` objects must be in pixel or angular units.

      sector int

        Optional. The TESS sector to return the cutout from. If not supplied, cutouts from all available sectors on which the coordinate appears will be returned.

      product str

        Deprecated. Default is ‘SPOC’. The product that the cutouts will be made out of. The only valid value for this parameter is ‘SPOC’, for the Science Processing Operations Center (SPOC) products.

      path str

        Optional. The directory in which the cutouts will be saved. Defaults to current directory.

      inflate bool

        Optional, default True. Cutout target pixel files are returned from the server in a zip file, by default they will be inflated and the zip will be removed. Set inflate to false to stop before the inflate step.

      objectname str, optional

        The target around which to search, by name (objectname=”M104”) or TIC ID (objectname=”TIC 141914082”). If moving_target is True, input must be the name or ID (as understood by the JPL ephemerides service) of a moving target such as an asteroid or comet.

        NOTE: If coordinates is supplied, this argument cannot be used.

      moving_target str, optional

        Indicate whether the object is a moving target or not. Default is set to False, in other words, not a moving target.

        NOTE: If coordinates is supplied, this argument cannot be used.

      mt_type str, optional

        The moving target type, valid inputs are majorbody and smallbody. If not supplied first majorbody is tried and then smallbody if a matching majorbody is not found.

        NOTE: If moving_target is supplied, this argument is ignored.

      resolver str, optional

        The resolver to use when resolving a named target into coordinates. Valid options are “SIMBAD” and “NED”. If not specified, the default resolver order will be used. Please see the STScI Archive Name Translation Application (SANTA) for more information. Default is None.

    Returns:
      response `Table`
  enable_cloud_dataset(provider='AWS', profile=None, verbose=True)

    Deprecated since version v0.4.8: This function is non-operational and will be removed in a future release.

    Enable downloading public files from S3 instead of MAST. Requires the boto3 library to function.

    Parameters:
      provider str

        Which cloud data provider to use. We may in the future support multiple providers, though at the moment this argument is ignored.

      profile str

        Profile to use to identify yourself to the cloud provider (usually in ~/.aws/config).

      verbose bool

        Default True. Logger to display extra info and warning.

  get_cutouts(*, coordinates=None, size=5, product='SPOC', sector=None, objectname=None, moving_target=False, mt_type=None, resolver=None)

    Get cutout target pixel file(s) around the given coordinates with indicated size, and return them as a list of `HDUList` objects.

    Parameters:
      coordinates str or `astropy.coordinates` object, optional

        The target around which to search. It may be specified as a string or as the appropriate `astropy.coordinates` object.

        NOTE: If moving_target or objectname is supplied, this argument cannot be used.

      size int, array-like, `Quantity`

        Optional, default 5 pixels. The size of the cutout array. If `size` is a scalar number or a scalar `Quantity`, then a square cutout of `size` will be created. If `size` has two elements, they should be in `(ny, nx)` order. Scalar numbers in `size` are assumed to be in units of pixels. `Quantity` objects must be in pixel or angular units.

      product str

        Deprecated. Default is ‘SPOC’. The product that the cutouts will be made out of. The only valid value for this parameter is ‘SPOC’, for the Science Processing Operations Center (SPOC) products.

      sector int

        Optional. The TESS sector to return the cutout from. If not supplied, cutouts from all available sectors on which the coordinate appears will be returned.

      objectname str, optional

        The target around which to search, by name (objectname=”M104”) or TIC ID (objectname=”TIC 141914082”). If moving_target is True, input must be the name or ID (as understood by the JPL ephemerides service) of a moving target such as an asteroid or comet.

        NOTE: If coordinates is supplied, this argument cannot be used.

      moving_target str, optional

        Indicate whether the object is a moving target or not. Default is set to False, in other words, not a moving target.

        NOTE: If coordinates is supplied, this argument cannot be used.

      mt_type str, optional

        The moving target type, valid inputs are majorbody and smallbody. If not supplied first majorbody is tried and then smallbody if a matching majorbody is not found.

        NOTE: If moving_target is supplied, this argument is ignored.

      resolver str, optional

        The resolver to use when resolving a named target into coordinates. Valid options are “SIMBAD” and “NED”. If not specified, the default resolver order will be used. Please see the STScI Archive Name Translation Application (SANTA) for more information. Default is None.

    Returns:
      response A list of `HDUList` objects.
  get_sectors(*, coordinates=None, radius=<Quantity 0. deg>, product='SPOC', objectname=None, moving_target=False, mt_type=None, resolver=None)

    Get a list of the TESS data sectors whose footprints intersect with the given search area.

    Parameters:
      coordinates str or `astropy.coordinates` object, optional

        The target around which to search. It may be specified as a string or as the appropriate `astropy.coordinates` object.

        NOTE: If moving_target or objectname is supplied, this argument cannot be used.

      radius str, float, or `Quantity` object, optional

        Default 0 degrees. If supplied as a float degrees is the assumed unit. The string must be parsable by `Angle`. The appropriate `Quantity` object from `astropy.units` may also be used.

        NOTE: If moving_target is supplied, this argument is ignored.

      product str

        Deprecated. Default is ‘SPOC’. The product that the cutouts will be made out of. The only valid value for this parameter is ‘SPOC’, for the Science Processing Operations Center (SPOC) products.

      objectname str, optional

        The target around which to search, by name (objectname=”M104”) or TIC ID (objectname=”TIC 141914082”). If moving_target is True, input must be the name or ID (as understood by the JPL ephemerides service) of a moving target such as an asteroid or comet.

        NOTE: If coordinates is supplied, this argument cannot be used.

      moving_target bool, optional

        Indicate whether the object is a moving target or not. Default is set to False, in other words, not a moving target.

        NOTE: If coordinates is supplied, this argument cannot be used.

      mt_type str, optional

        The moving target type, valid inputs are majorbody and smallbody. If not supplied first majorbody is tried and then smallbody if a matching majorbody is not found.

        NOTE: If moving_target is supplied, this argument is ignored.

      resolver str, optional

        The resolver to use when resolving a named target into coordinates. Valid options are “SIMBAD” and “NED”. If not specified, the default resolver order will be used. Please see the STScI Archive Name Translation Application (SANTA) for more information. Default is None.

    Returns:
      response `Table`

        Sector/camera/chip information for given coordinates/objectname/moving_target.

  login(token=None, store_token=False, reenter_token=False)

    Log into the MAST portal.

    Parameters:
      token string, optional

        Default is None. The token to authenticate the user. This can be generated at https://ssoportal.stsci.edu/idp/profile/SAML2/Redirect/SSO?execution=e1s1 If not supplied, it will be prompted for if not in the keyring or set via $MAST_API_TOKEN

      store_token bool, optional

        Default False. If true, MAST token will be stored securely in your keyring.

      reenter_token bool, optional

        Default False. Asks for the token even if it is already stored in the keyring or $MAST_API_TOKEN environment variable. This is the way to overwrite an already stored password on the keyring.

  logout()

    Log out of current MAST session.

  reset_cache_location()

    Resets the cache location to the default astropy cache

  resolve_object(objectname, *, resolver=None, resolve_all=False)

    Resolves an object name to a position on the sky.

    Parameters:
      objectname str

        Name of astronomical object to resolve.

      resolver str, optional

        The resolver to use when resolving a named target into coordinates. Valid options are “SIMBAD” and “NED”. If not specified, the default resolver order will be used. Please see the STScI Archive Name Translation Application (SANTA) for more information. If `resolve_all` is True, this parameter will be ignored. Default is None.

      resolve_all bool, optional

        If True, will try to resolve the object name using all available resolvers (“NED”, “SIMBAD”). Function will return a dictionary where the keys are the resolver names and the values are the resolved coordinates. Default is False.

    Returns:
      response `SkyCoord`, dict

        If `resolve_all` is False, returns a `SkyCoord` object with the resolved coordinates. If `resolve_all` is True, returns a dictionary where the keys are the resolver names and the values are `SkyCoord` objects with the resolved coordinates.

  session_info(verbose=True)

    Displays information about current MAST user, and returns user info dictionary.

    Parameters:
      verbose bool, optional

        Default True. Set to False to suppress output to stdout.

    Returns:
      response dict