avocado.Dataset.load

classmethod Dataset.load(name, metadata_only=False, chunk=None, num_chunks=None, object_class=<class 'avocado.astronomical_object.AstronomicalObject'>, **kwargs)

Load a dataset that has been saved in HDF5 format in the data directory.

For an example of how to create such a dataset, see scripts/download_plasticc.py.

The dataset can optionally be loaded in chunks. To do this, pass chunk and num_chunks to this method. See read_dataframes for details.

Parameters:
  • name (str) – The name of the dataset to load
  • metadata_only (bool (optional)) – If False (default), the observations are loaded. Otherwise, only the metadata is loaded. This is useful for very large datasets.
  • chunk (int (optional)) – If set, load the dataset in chunks. chunk specifies the chunk number to load. This is a zero-based index.
  • num_chunks (int (optional)) – The total number of chunks to use.
  • **kwargs – Additional arguments to read_dataframes
Returns:

dataset – The loaded dataset.

Return type:

Dataset