Skip to main content

Store scientific data in HDF5 files, but with pleasant Python bindings!

A general data handling toolkit with a powerful class for abstracting away work with multidimensional set.

Parts of this code were created as part of PhD work supported by the EU ITN EID project CORAL (GA no. 859841).

Installation

You can install this package from pip:

pip install dataset-suite

Once installed, all useful functions are in the top-level module:

import dataset_suite as ds

Basic usage

A short introduction to using the library:

import dataset_suite as ds

# Create a dataset out of a set of spectra
data = ds.dataset(
    array,
    index=np.arange(array.shape[0]) # A basic numerical index
    wavelength=spectrometer.wavelength # You can store a numpy array as an axis descriptor
    # alongside your data. This way you know that the second axis of this dataset is a
    # "wavelength", and what wavelength corresponds to each datapoint
)
data.metadata["comment"] = "afternoon spectra"
# Save the dataset to a HDF5 file
data.save_h5("file.h5")
# Load a dataset from a file
data = ds.load_h5('file.h5')
# inspect the dataset - what axes does it have?
print(data)
# dataset(index[10], wavelength[100])

data.raw # access the underlying numpy array
data.wl # use axis names as attributes to get the values for a given axis,
#         like wavelength here
data.wl[10] # this is the wavelength corresponding to the 10th column of the array
data.take(index=5) # slice along the index axis: dataset(wavelength[100])
data.take_sum("wavelength") # sum along the wavelength axis: dataset(index[10])
data.metadata # dictionary of measurement metadata

The library also includes some convenient helpers like a function mapping values to colours using matplotlib colormaps, and a number of filename search/analysis tools. Have a look at https://dataset-suite.readthedocs.io/en/latest/api.html

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dataset_suite-0.3.2.tar.gz (126.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dataset_suite-0.3.2-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file dataset_suite-0.3.2.tar.gz.

File metadata

  • Download URL: dataset_suite-0.3.2.tar.gz
  • Upload date:
  • Size: 126.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for dataset_suite-0.3.2.tar.gz
Algorithm Hash digest
SHA256 ad262fe21551af5f581058b90bcea72393b6f5adc9535ee1462eeb8f04c1235d
MD5 a7417aaedfc0f3abceeeb82be860d2d9
BLAKE2b-256 6baf83ccf2ed09e73fce8d75f978c97fe8b0241c92aa0a019c0f971bccc131e9

See more details on using hashes here.

Provenance

The following attestation bundles were made for dataset_suite-0.3.2.tar.gz:

Publisher: python-publish.yml on jdranczewski/dataset-suite-pip

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dataset_suite-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: dataset_suite-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 10.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for dataset_suite-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3a445ff8b8dc349a2759bcee9d094e3d56d0dd90082372cacb1094e557b30671
MD5 9bd0ffb9752da9fb57a16cc3b3fc255c
BLAKE2b-256 f7f1b5db21929c297067fb21b1102b4d2e76ac50459bc4cfa20972fd2db03d99

See more details on using hashes here.

Provenance

The following attestation bundles were made for dataset_suite-0.3.2-py3-none-any.whl:

Publisher: python-publish.yml on jdranczewski/dataset-suite-pip

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.4.0

2 files

This release

0.3.2 This release

2 files

0.3.1

2 files

0.3.0

2 files

0.2.0

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page