Poplar and PopLibs
Sort.hpp
Go to the documentation of this file.
1// Copyright (c) 2018 Graphcore Ltd. All rights reserved.
8#ifndef popops_Sort_hpp
9#define popops_Sort_hpp
10
11#include <poplar/Graph.hpp>
12#include <poplar/Program.hpp>
13#include <string>
14
15namespace popops {
16
39poplar::Tensor sort(poplar::Graph &graph, const poplar::Tensor &t, unsigned dim,
41 const poplar::DebugContext &debugContext = {});
42
59void sortInPlace(poplar::Graph &graph, const poplar::Tensor &t, unsigned dim,
61 const poplar::DebugContext &debugContext = {});
62
91 const poplar::Tensor &v, unsigned dim,
93 const poplar::DebugContext &debugContext = {});
94
118 const poplar::Tensor &v, unsigned dim,
120 const poplar::DebugContext &debugContext = {});
121
122} // namespace popops
123
124#endif
DebugContext gathers the common external parameters of the context of an operation.
Definition: DebugContext.hpp:221
This class represents a graph program to be executed on the IPU.
Definition: Graph.hpp:52
A reference to a subset of tensor elements.
Definition: Tensor.hpp:38
Program that executes a sequence of programs.
Definition: Program.hpp:77
Common functions, such as elementwise and reductions.
Definition: AllTrue.hpp:15
void sortInPlace(poplar::Graph &graph, const poplar::Tensor &t, unsigned dim, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={})
poplar::Tensor sort(poplar::Graph &graph, const poplar::Tensor &t, unsigned dim, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={})
poplar::Tensor sortKeyValue(poplar::Graph &graph, const poplar::Tensor &k, const poplar::Tensor &v, unsigned dim, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={})
void sortKeyValueInPlace(poplar::Graph &graph, const poplar::Tensor &k, const poplar::Tensor &v, unsigned dim, poplar::program::Sequence &prog, const poplar::DebugContext &debugContext={})