Template Class BatchTransform

Inheritance Relationships

Derived Types

Class Documentation

template<typename InputBatch, typename OutputBatch>
class torch::data::transforms::BatchTransform

A transformation of a batch to a new batch.

Subclassed by torch::data::transforms::Stack< Example<> >, torch::data::transforms::Stack< TensorExample >

Public Types

using InputBatchType = InputBatch
using OutputBatchType = OutputBatch

Public Functions

~BatchTransform() = default
OutputBatch apply_batch(InputBatch input_batch) = 0

Applies the transformation to the given input_batch.


Access comprehensive developer documentation for PyTorch

View Docs


Get in-depth tutorials for beginners and advanced developers

View Tutorials


Find development resources and get your questions answered

View Resources