Dataset

class itergp.datasets.Dataset(X, y, train_idcs)

Bases: object

Classification / Regression dataset.

Parameters
  • X (backend.Array) – Inputs / features.

  • y (backend.Array) – Outputs / labels.

  • train_idcs (backend.Array) – Indices of the training data.

Attributes Summary

input_shape

Input shape of the data.

output_shape

Output shape of the data.

test

Test data.

train

Training data.

Methods Summary

from_disk(dir)

resample(rng_state)

Resample the training and test set from the entire data set.

save([dir, overwrite])

Save dataset to disk.

Attributes Documentation

input_shape

Input shape of the data.

output_shape

Output shape of the data.

test

Test data.

train

Training data.

Methods Documentation

classmethod from_disk(dir)[source]
Parameters

dir (str) –

Return type

Dataset

resample(rng_state)[source]

Resample the training and test set from the entire data set.

Randomly selects new datapoints for the training and test set of the same sizes as the original dataset.

Parameters

rng_state (SeedSequence) – Random number generator state.

Return type

Dataset

save(dir='data', overwrite=False)[source]

Save dataset to disk.

Parameters
  • dir (str) – Directory to save data to.

  • overwrite – Whether to overwrite existing data.

Return type

None