summaryrefslogtreecommitdiff
path: root/runtimes/neurun/src/graph/operation/Permute.cc
blob: 2688e5e5fffe016e00e466d0818e69bad2440aea (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#include "Permute.h"

#include <cassert>

#include "NodeVisitor.h"

namespace neurun
{
namespace graph
{
namespace operation
{
namespace Permute
{

void Node::accept(NodeVisitor &&v) const { v.visit(*this); }

Node::Node(const operand::Index &input, const operand::Index &output)
{
  setInputs({input});
  setOutputs({output});
}

void Node::setInputs(const operand::IndexSet &indexes)
{
  assert(indexes.size() == 1);

  graph::operation::Node::setInputs(indexes);
}

void Node::setOutputs(const operand::IndexSet &indexes)
{
  assert(indexes.size() == 1);

  graph::operation::Node::setOutputs(indexes);
}

} // namespace Permute
} // namespace operation
} // namespace graph
} // namespace neurun