Shortcuts

Program Listing for File collate.h

Return to documentation for file (torch/csrc/api/include/torch/data/transforms/collate.h)

#pragma once

#include <torch/data/example.h>
#include <torch/data/transforms/lambda.h>

#include <vector>

namespace torch {
namespace data {
namespace transforms {

template <typename T, typename BatchType = std::vector<T>>
using Collation = BatchTransform<BatchType, T>;

template <typename T, typename BatchType = std::vector<T>>
using Collate = BatchLambda<BatchType, T>;
} // namespace transforms
} // namespace data
} // namespace torch

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources