Berkeley Supernova Ia Program (BSNIP)

The bsnip module provides access to data from the Berkeley Supernova Ia Program (BSNIP). For the photometric compliment to this survey, see the loss module.

Data Release Class name Data Type Publication
Data Release 2 Stahl20 Spectroscopic Stahl et al. 2020

Stahl et al. 2020 (Spectroscopic)

class sndata.bsnip.Stahl20[source]

The second data release of the the Berkeley Supernova Ia Program (BSNIP), including 637 low-redshift optical spectra collected between 2009 and 2018. Targets include 626 spectra (of 242 objects) that are unambiguously classified as belonging to Type Ia supernovae (SNe Ia). Of these, 70 spectra of 30 objects are classified as spectroscopically peculiar and 79 SNe Ia (covered by 328 spectra) have complementary photometric coverage. The median SN in the data set has one epoch of spectroscopy, a redshift of 0.0208 (with a low of 0.0007 and high of 0.1921), and is first observed spectroscopically 1.1 days after maximum light. (Source: Stahl et al. 2020)

Deviations from the standard UI:
  • Meta data such as object Ra, DEC, and redshifts ar not included in the official data release files.
Cuts on returned data:
  • None

Delete any data for the current survey / data release

download_module_data(force: bool = False, timeout: float = 15)

Download data for the current survey / data release

  • force – Re-Download locally available data
  • timeout – Seconds before timeout for individual files/archives
get_available_ids() → List[str]

Return a list of target object IDs for the current survey

Returns:A list of object IDs as strings
get_available_tables() → List[Union[int, str]]

Get Ids for available vizier tables published by this data release

get_data_for_id(obj_id: str, format_table: bool = True) → astropy.table.table.Table

Returns data for a given object ID

See get_available_ids() for a list of available ID values.

  • obj_id – The ID of the desired object
  • format_table – Format data into the sndata standard format

An astropy table of data for the given ID

iter_data(verbose: bool = False, format_table: bool = True, filter_func: bool = None) → astropy.table.table.Table

Iterate through all available targets and yield data tables

An optional progress bar can be formatted by passing a dictionary of tqdm arguments. Outputs can be optionally filtered by passing a function filter_func that accepts a data table and returns a boolean.

  • verbose – Optionally display progress bar while iterating
  • format_table – Format data for SNCosmo (Default: True)
  • filter_func – An optional function to filter outputs by

Astropy tables

load_table(table_id: Union[int, str]) → astropy.table.table.Table

Return a Vizier table published by this data release

Parameters:table_id – The published table number or table name