parse_data#
- jdaviz.configs.cubeviz.plugins.parsers.parse_data(app, file_obj, data_type=None, data_label=None, parent=None, cache=None, local_path=None, timeout=None, specutils_format=None, spectral_axis_index=None)[source]#
Attempts to parse a data file and auto-populate available viewers in cubeviz.
- Parameters:
- app
Application The application-level object used to reference the viewers.
- file_objstr
The path to a cube-like data file.
- data_typestr, {‘flux’, ‘mask’, ‘uncert’}
The data type used to explicitly differentiate parsed data.
- data_labelstr, optional
The label to be applied to the Glue data component.
- parentstr, optional
Data label for “parent” data to associate with the loaded data as “child”.
- cacheNone, bool, or str
Cache the downloaded file if the data are retrieved by a query to a URL or URI.
- local_pathstr, optional
Cache remote files to this path. This is only used if data is requested from
astroquery.mast.- timeoutfloat, optional
If downloading from a remote URI, set the timeout limit for remote requests in seconds (passed to
download_fileortimeout).- specutils_formatstr, optional
Optional format string to pass to Spectrum.read(), see https://specutils.readthedocs.io/en/stable/spectrum1d.html#list-of-loaders for valid format strings. Useful for processed files that may not include the original headers with information used to auto-identify.
- app