Dataset.union(*other: List[ray.data.dataset.Dataset]) ray.data.dataset.Dataset[source]#

Materialize and combine this dataset with others of the same type.

The order of the blocks in the datasets is preserved, as is the relative ordering between the datasets passed in the argument list.


Unioned datasets are not lineage-serializable, i.e. they can not be used as a tunable hyperparameter in Ray Tune.


This operation will trigger execution of the lazy transformations performed on this dataset.


other – List of datasets to combine with this one. The datasets must have the same schema as this dataset, otherwise the behavior is undefined.


A new dataset holding the union of their data.